-
-
Notifications
You must be signed in to change notification settings - Fork 126
LayerBookmarks Plugin: Save and restore layer bookmarks without changing map position #526
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
…hout changing map position Adds new LayerBookmarks Plugin + Quick Select Menu in Bottom Bar --------- Co-authored-by: Benedikt Seidl <[email protected]>
|
Great Idea! Just a few thoughts on this. As the functionality is very close to the existing bookmarks, I would prefer to extent the functionality of the bookmarks plugin instead of creating a new on with similar usability. There is already an option to set a default map theme per user within the theme selection panel by clicking the star symbol at a specific map theme. How is this considered here? So which default configuration "wins" when opening the map viewer, the map theme or the bookmark? So if there is a solition for this, I would recommend to set the default bookmark like the map theme with introducing the possibility to click a similar star symbol within the list entry of a bookmark (for instance on the right side). |
|
Interesting functionality! As @danceb wrote, it would be interesting to integrate this into the existing bookmarks plugin. As far as I can see the core feature here is the quick switcher from the bottombar. What about the following behavior:
|
|
@danceb Regarding the selection of default themes/bookmarks: This PR does not change how the defaults are managed. There can only be one default per user (regardless if it is a theme, bookmark or layerbookmark). Choosing a new default will override the old one. A star icon for setting defaults directly in the bookmark list would be a nice addition. We have dicussed the same idea here previously. We might implement this at some point in the future, but it is not within the scope of this PR. @manisandro @danceb
So yes, we are confident that keeping the two plugins seperate is the preferable solution (at the very least for our instance and our users). |
|
The issue I see is that the distinction between "layer visibility bookmarks" and "regular bookmarks" relies solely on the the query keys of the bookmark, say This is fragile, for one a viewer can also be configured to store the extent in the url instead of center and scale. Furthermore, the query can also contain the 3D state, and the bookmark state can also contain redlining drawings etc. So it is misleading to call this a "layer visibility bookmark". A functionality which has recently been added to QWC is support for the QGIS layer visibility presets (in QGIS they are called "themes"). These presets just store which layers are checked in the layertree, and which style is selected. I think this is actually much closer to what you are trying to store, see also Line 1130 in d281f0d
If layer visibilities are what is meant to be stored and restored, I would recommend introducing a dedicated table in the config_db (say |
|
I would like to support this suggestion. Predefined layer visibility sets are also something that our customer base uses. In fact, it would be desirable to take this a step further and offer predefined selections that users can then expand themselves. |
|
Good points @manisandro. We'll try do rewrite this pull request based on the presets in LayerUtils. May take a little until we have time to do it. |

User Story
Our users want the ability to save custom layer presets and quickly switch between them, without losing the current map position.
Relevant scenarios include:
Implementation
Quick Select
Settings
Looking forward to feedback!