Skip to content
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

Add clear recently used crs button #52321

Merged
merged 7 commits into from Apr 26, 2023
Merged

Conversation

YoannQDQ
Copy link
Contributor

@YoannQDQ YoannQDQ commented Mar 20, 2023

Fixes #21473

Description

  • Adds a column in the recent crs table with a button to clear individual CRS
  • Adds a context menu (right click) with two actions:
    • Clear selected (Same as button)
    • Clear all recent CRS (prompt user for confirmation)
  • Pressing the Del key while the list of recently used crs has focus remove the selected CRS

clear_crs

@github-actions github-actions bot added this to the 3.32.0 milestone Mar 20, 2023
@YoannQDQ YoannQDQ added Feature GUI/UX Related to QGIS application GUI or User Experience Projections/Transformations Related to coordinate reference systems or coordinate transformation labels Mar 20, 2023
@nicogodet
Copy link
Member

May be you could re-use "clear" icon from elevation widget ?
image

@uclaros
Copy link
Contributor

uclaros commented Mar 21, 2023

I'd be more in favor of some way to remove items one by one than a clear button (right click -> remove?).
Most users commonly use a set of CRSs and, as mentioned in the request ticket, they sometimes get an extra CRS polluting their list. While the clear button will remove the unwanted CRS, the user will still have to rebuild his commonly used set.

@YoannQDQ
Copy link
Contributor Author

YoannQDQ commented Mar 21, 2023

Ok, I added a way to remove CRS individually.
Now I was wondering:

  • Should I keep the "Clear all recent crs" option?
  • Would a context menu be better than the small button in the last column?

Any thoughts @uclaros?

@alexandreparente
Copy link

Maybe you can just use the right click.

@YoannQDQ
Copy link
Contributor Author

What I find annoying with the context-menu-only solution, is that it can easily never be found by the user. If we move forward with this, there's nothing to indicate that the CRS list now has a context menu...

@YoannQDQ YoannQDQ force-pushed the clear-recent-crs branch 2 times, most recently from e7bb5e9 to b2ea9cf Compare March 21, 2023 22:36
@uclaros
Copy link
Contributor

uclaros commented Mar 22, 2023

What I find annoying with the context-menu-only solution, is that it can easily never be found by the user. If we move forward with this, there's nothing to indicate that the CRS list now has a context menu...

That's a valid point. However, I'm afraid the clear buttons (especially the clear all) might be too easy to click, removing more than needed. Also, the clear buttons, while really pleasing visually, are kind of unusual in qgis (usually lists have + and - buttons next to the list, not inside the rows)
This is just my personal preference though.

On a side note, Remove selected instead of clear selected would probably be more appropriate wording.

@github-actions github-actions bot added the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Apr 16, 2023
@YoannQDQ YoannQDQ removed the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Apr 16, 2023
@m-kuhn
Copy link
Member

m-kuhn commented Apr 24, 2023

Nice functionality. I would prefer to remove the "clear all" button on top of the list and only leave it in the context menu. This will keep the user interface a bit cleaner.

@qgis qgis deleted a comment from github-actions bot Apr 24, 2023
@YoannQDQ
Copy link
Contributor Author

Done

@YoannQDQ YoannQDQ added the Needs Documentation When merging a labeled PR, an issue will be created in the Doc repo. label Apr 24, 2023
@github-actions
Copy link

@YoannQDQ
This pull request has been tagged as requiring documentation.

A documentation ticket will be opened at https://github.com/qgis/QGIS-Documentation when this PR is merged.

Please update the description (not the comments) with helpful description and screenshot to help the work from documentors.
Also, any commit having [needs-doc] or [Needs Documentation] in will see its message pushed to the issue, so please be as verbose as you can.

Thank you!

@YoannQDQ
Copy link
Contributor Author

@m-kuhn Could you merge this now? Thanks :)

@m-kuhn m-kuhn merged commit 69a2bb8 into qgis:master Apr 26, 2023
31 checks passed
@m-kuhn
Copy link
Member

m-kuhn commented Apr 26, 2023

With pleasure

@github-actions
Copy link

@YoannQDQ
A documentation ticket has been opened at qgis/QGIS-Documentation#8216
It is your responsibility to visit this ticket and add as much detail as possible for the documentation team to correctly document this change.
Thank you!

@YoannQDQ YoannQDQ deleted the clear-recent-crs branch April 26, 2023 08:36
@YoannQDQ YoannQDQ added the Changelog Items that are queued to appear in the visual changelog - remove after harvesting label Apr 28, 2023
@zacharlie zacharlie added ChangelogHarvested This PR description has been harvested in the Changelog already. and removed Changelog Items that are queued to appear in the visual changelog - remove after harvesting labels Jun 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ChangelogHarvested This PR description has been harvested in the Changelog already. Feature GUI/UX Related to QGIS application GUI or User Experience Needs Documentation When merging a labeled PR, an issue will be created in the Doc repo. Projections/Transformations Related to coordinate reference systems or coordinate transformation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

UI option for clear "Recently used coordinate reference systems" list
6 participants