Skip to content

Commit

Permalink
Bump LightOSM compat version (#36)
Browse files Browse the repository at this point in the history
* Bump LightOSM version

* Change mentions of highway/s to way/s
  • Loading branch information
fbanning authored Jun 13, 2022
1 parent 0506264 commit 65e0d61
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a"
julia = "1.6, 1.7"
GraphMakie = "0.3"
Graphs = "1.5"
LightOSM = "0.1"
LightOSM = "0.2"
Makie = "0.16, 0.17"
2 changes: 1 addition & 1 deletion src/defaults/defaults.jl
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ function set_edge_defaults(osmplot)
i2w = osmplot.index_to_way[]
sorted_edges = osmplot.sorted_edges[]
n2i = osm.node_to_index
ways = osm.highways
ways = osm.ways

edge_color = color_streets(gpk, i2w)
edge_width = width_streets(gpk, i2w)
Expand Down
2 changes: 1 addition & 1 deletion src/inspection.jl
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ function Makie.show_data(inspector::DataInspector,
# Without plot.index_to_way:
# i1, i2 = plot.sorted_edges[][idx÷2]
# n1, n2 = osm.index_to_node[i1], osm.index_to_node[i2]
# way = osm.edge_to_highway[[n1, n2]]
# way = osm.edge_to_way[[n1, n2]]

# With plot.index_to_way:
way = plot.index_to_way[][idx÷2]
Expand Down
4 changes: 2 additions & 2 deletions src/recipe.jl
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ function Makie.plot!(osmplot::OSMPlot{<:Tuple{<:OSMGraph}})
osmplot.sorted_edges = collect([e.src, e.dst] for e in edges(osm.graph))
osmplot.index_to_way = Dict(
zip(1:Graphs.ne(osm.graph),
(osm.highways[way] for way in
(osm.edge_to_highway[edge] for edge in
(osm.ways[way] for way in
(osm.edge_to_way[edge] for edge in
([osm.index_to_node[s], osm.index_to_node[d]] for (s, d) in osmplot.sorted_edges[])))
)
)
Expand Down

2 comments on commit 65e0d61

@fbanning
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/62286

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.0.5 -m "<description of version>" 65e0d619fb4c63e3faee5affc3b0cc8dbcfc7795
git push origin v0.0.5

Please sign in to comment.