Commit Graph

426 Commits

Author SHA1 Message Date
James Nebeker
ee7f843ff6
Fixes issue #173 Part B (#917)
* Fixes issue #173 Part B

This commit changes the color of road labels to white, and adds a black
stroke. It also removes center line dashes from the beginning of the
road label to the end.

* cargo fmt and fix syntax warnings

* Adds changes from PR #917 Review

This commit adds the changes requested in PR #917.

* Rebase and cargo fmt

* A few cleanups:

- make render_center_line private
- make usage of the 0.1 factor more clear
- work in Distance::meters

* Disable the curvey label experiment before merging, but now we don't
need to draw the background for non-curvey labels either!

* Draw the full center-line when appropriate

* Screenshot diff

Co-authored-by: Dustin Carlino <dabreegster@gmail.com>
2022-05-24 14:55:23 +01:00
Dustin Carlino
b236c23112 Update to Rust 1.61 2022-05-21 17:17:02 +01:00
Dustin Carlino
7bb426f804 Create a new widgetry transition to simplify state preservation in the LTN tool. It's maybe a bit specialized, but hopefully this kind of pattern could come in handy elsewhere, or a slightly more general pattern could emerge. 2022-05-19 14:21:44 +01:00
Dustin Carlino
078265718a Start a simplified consultation mode for the LTN tool
- starts in a fixed neighborhood
- hides many controls
- lets users jump to route planning from the per-neighborhood screens
2022-05-17 16:14:14 +01:00
Dustin Carlino
213df7fa82 Some slight widgetry API changes in support of another project, which is -- I am only mildly ashamed to say -- is depending on it 2022-05-13 16:47:58 +01:00
Dustin Carlino
4ca0c24a60 Add tooltips to the pedestrian crowding layer 2022-05-12 14:10:49 +01:00
Dustin Carlino
fd2bf7e2fc Show an alert message when WASM crashes. This is way better than silently locking up and people knowing they have to open the dev console to see the panic. 2022-04-30 14:01:33 +01:00
Dustin Carlino
19447b5a26 Create a layer to show where problems are occurring more or less. #859 2022-04-29 14:08:52 +01:00
Dustin Carlino
832f02cad9 Always draw unzoomed LTN filters as a red circle with a white line, even
when very unzoomed
2022-04-17 17:19:34 +01:00
Dustin Carlino
cf3773eda8 Draw unzoomed lines and circles in the zorder they're added, instead of
one shape after another
2022-04-12 16:15:38 +01:00
Dustin Carlino
6aa71539a5 Start mocking out a UI to sketch bus routes, showing people and places
nearby. Shove it in the 15m tool momentarily.

Also make the thresholds/colors for isochrones more configurable.
2022-03-30 15:56:37 +01:00
Dustin Carlino
1126972fdd For roads we predict to get more/less traffic from LTN interventions,
click them and explore specific routes.

UI needs plenty of work.

And the results show plenty of spurious changes not explained by new
filters.
2022-03-25 12:07:23 +00:00
Dustin Carlino
c88f7bbc53 Display info about the 4 routes more consistently [rebuild] [release] 2022-03-23 10:47:01 +00:00
Dustin Carlino
477783e430 Simplify the combinatorial explosion of Panel sizing APIs 2022-03-08 09:33:49 +00:00
Dustin Carlino
04f00b4c8a Move the LTN app header to a separate top panel. 2022-03-08 09:33:49 +00:00
Dustin Carlino
cec9b785dd Quickly sketch desired LTN cells freehand! 2022-02-24 10:36:47 +00:00
Dustin Carlino
b07177c21a Fix crash in the LTN and Ungap pathfinding tool, introduced in
2bf7ce232a
2022-02-24 09:47:10 +00:00
Dustin Carlino
bf6c5a75e9 Make the lasso tool show the polygon as it's being drawn, so it's way more clear what's going to happen 2022-02-24 09:33:12 +00:00
Dustin Carlino
78e4fc3f80 Make the lasso tool (buried in an old experiment in story mapping) a bit more usable, and lift it to widgetry 2022-02-24 09:33:12 +00:00
Dustin Carlino
7bb6132726 Open OSM from map_editor
(Move open_browser to widgetry)
2022-02-23 14:43:58 +00:00
Dustin Carlino
6ddc35f5a8 Upgrade usvg and friends 2022-02-22 17:24:03 +00:00
Dustin Carlino
bf6ed53ec3 Upgrade winit and co. This appears to remove a bunch of duplicate old
versions of various transitive dependencies, so it should help compile
times a bit!

No behavioral diff that I can see, but the winit CHANGELOG is
formidable. I suspect there are platform-specific differences with
scroll speed/direction, initial window size behavior, etc that people
will slowly start reporting after the next weekly release.
2022-02-22 16:50:53 +00:00
Dustin Carlino
d141a2a810 Upgrade all geo dependencies! No behavioral difference 2022-02-22 16:45:49 +00:00
Dustin Carlino
2bf7ce232a Port map_editor to the shared map-space World abstraction. #763
There may be small UX bugs, but the code is vastly simpler now, and all
main functionality works fine.
2022-02-20 11:01:57 +00:00
Dustin Carlino
f14554f6b7 Lift URLManager from map_gui to widgetry 2022-02-19 15:14:53 +00:00
Dustin Carlino
aa48def2ba Lift FileLoader and friends from map_gui to widgetry
(Very tricky dependency shuffling...)
2022-02-19 15:07:07 +00:00
Dustin Carlino
3b21bf6e87 Lift PopupMsg to widgetry 2022-02-19 14:38:26 +00:00
Dustin Carlino
c1a58e683b Use a 'back button' style a few places in the LTN tool, from UX session with Robin 2022-02-08 09:17:28 +00:00
Dustin Carlino
e542011614 More fluid UI for comparing traffic counts -- hotkeys
Had to change the API of on_click...
2022-01-27 15:13:24 +00:00
Dustin Carlino
5dfb8f26f0 Refactor ColorNetwork to use ToggleZoomed 2022-01-26 11:31:33 +00:00
Dustin Carlino
ec0fd1b94d Stop running out of video memory in the LTN impact prediction tool.
- One batch for all neighborhoods
- One batch for all roads/intersections
- No pre-built tooltips

This all comes at more repetitive code. Need to make World generate some
stuff dynamically (#763)
2022-01-26 11:26:03 +00:00
Dustin Carlino
a14d6b3810 Better errors when core Line stuff breaks.
... and plumbing it everywhere
2022-01-18 10:26:33 +00:00
Dustin Carlino
bd340a1970 Switch from std::fs to fs_err. When files aren't found, the error message actually includes the path! 2022-01-17 17:30:51 +00:00
Dustin Carlino
7d6f133f1c Make the LTN tool handle roads that already ban cars.
- Don't allow filtering them
- Don't cross them when calculating cell connectivity
- Create special green cells for them, and don't count towards the
  disconnected warning
2021-12-31 16:28:51 +00:00
Dustin Carlino
bffa469396 Print LTN pathfinding info in the panel, not a tooltip. The tooltips
clash with clicking on roads to filter them, and probably weren't
terribly discoverable anyway.
2021-12-29 18:23:33 +00:00
Dustin Carlino
f7f23465c1 Edit modal filters from within the pathfinding view too.
Slow implementation, but at least it works
2021-12-29 13:14:44 +00:00
Dustin Carlino
fbc847f48c Share modal filter management between connectivity and rat run states 2021-12-29 12:38:11 +00:00
Dustin Carlino
1e414d0f31 Share the panel style too for pathfinding. (It was a bigger change, easier to separate) 2021-12-29 11:54:12 +00:00
Dustin Carlino
83bf6953d1 Rank each street inside a neighborhood as quiet/busy, based on the number of rat-runs through it.
Show this through a heatmap and tooltips
2021-12-19 12:06:42 +00:00
Dustin Carlino
eb4060b071 Improve LTN tool rendering when zoomed in. Outlines around selected
objects are less thick and opaque, to cover up less of the road.
2021-12-17 11:37:54 +00:00
Dustin Carlino
e77ce12537 Draw custom LTN boundaries, by painting blocks. #794
Still need to think through the UX of how to manage custom boundaries
and incorporate them in the "browse neighborhoods" screen.
2021-12-14 10:33:42 -08:00
Dustin Carlino
331a3674b1 Restore spinner values in replacement panels.
First use case is in the LTN route tool. I audited other UIs using
spinners and panel restore -- there are none.
2021-11-21 11:58:37 -08:00
Dustin Carlino
2f18e4badc Remove broken code for Leaflet-named screenshots. #440
Gave up on Leaflet in favor of Mapbox GL, and the math was always wrong
here anyway.
2021-11-11 09:02:29 -08:00
Dustin Carlino
f751b7d54b Removing the pregame color scheme 2021-11-06 10:33:11 -07:00
Dustin Carlino
401d5fe297 Make it even easier to debug block order 2021-11-02 16:31:29 -07:00
Dustin Carlino
00df96f173
Render A/B Street's lanes and traffic simulation on top of Mapbox GL (#788)
[rebuild] [release]
2021-10-31 13:52:58 -07:00
Dustin Carlino
5e5e411de8
Detect neighborhoods with the new block abstraction (#793) 2021-10-28 10:11:57 -07:00
Dustin Carlino
9f86365cf6 Upgrade to rust 1.56 and cutover to rust edition 2021 2021-10-21 09:38:06 -07:00
Dustin Carlino
48ed3683e5 Fix the thickness math 2021-10-18 17:54:58 -07:00
Dustin Carlino
002b41816d Actually, generalize UnzoomedLines to handle circles too. Make the route sketcher nicer to use at all zoom levels! 2021-10-18 17:54:58 -07:00