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

Fix issue with actions on empty space of menu items #10093

Merged
merged 1 commit into from
Jul 18, 2023
Merged

Fix issue with actions on empty space of menu items #10093

merged 1 commit into from
Jul 18, 2023

Conversation

Clunphumb
Copy link
Contributor

This change fixes #8388 by removing CustomMenuItem from several context menus. This also removes the corresponding tool tips.

The issue is illustrated in the following image:
grafik

For "Normalize to BibTeX name format" and every entry of the "Change case" menu you have to click inside the smaller red box to actually fire the event while you can click on the bigger red box for every other entry. This is caused by the usage of CustomMenuItem which shrinks the clickable box to the actual content. It is possible to add padding to the labels to enlarge the clickable area. However, given the dynamic nature of spacing in those menus I wasn't able to get acceptable results. This would increase future maintenance efforts as well because changes would always have to address CustomMenuItems and "normal" MenuItems.
Removing CustomMenuItems on the other hand would come at the price of removing tool tips as well. Given that almost all context menu entries aren't using tool tips, I would think that this wouldn't be a big problem.

This PR doesn't cause any visual changes as far as I can tell.

Please let me know what you think about this PR and thank you very much in advance!

Mandatory checks

  • Change in CHANGELOG.md described in a way that is understandable for the average user (if applicable)
  • Tests created for changes (if applicable)
  • Manually tested changed features in running JabRef (always required)
  • Screenshots added in PR description (for UI changes)
  • Checked developer's documentation: Is the information available and up to date? If not, I outlined it in this pull request.
  • Checked documentation: Is the information available and up to date? If not, I created an issue at https://github.com/JabRef/user-documentation/issues or, even better, I submitted a pull request to the documentation repository.

@Siedlerchr
Copy link
Member

Thank you very much for the investigation! Sounds reaonsable to me to replace them with the normal entriex

@calixtus
Copy link
Member

DevCall decision:

We think that this is a reasonable tradeoff, since we don't really know any other application which uses tooltips for context menu entries beside pure symbols.
E.g. in firefox:
grafik grafik
Therefor we will merge this.

@calixtus
Copy link
Member

Please fix the localization test, then we will merge.
Thank you for your efforts investigating and fixing this issue.

This change fixes #8388 by removing CustomMenuItem from several context menus. This also removes the corresponding tooltips.
@Clunphumb
Copy link
Contributor Author

Thank you for your feedback. I removed the unused key and squashed my commits.

Copy link
Member

@Siedlerchr Siedlerchr left a comment

Choose a reason for hiding this comment

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

LGTM

@Siedlerchr
Copy link
Member

You don't need to squash your commits, this is done when we merge

@calixtus
Copy link
Member

Please avoid force-pushing on GitHub, since comments on commits will loose it's link.

Copy link
Member

@calixtus calixtus left a comment

Choose a reason for hiding this comment

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

Lgtm

@calixtus calixtus merged commit 34ac6d1 into JabRef:main Jul 18, 2023
11 of 12 checks passed
@calixtus
Copy link
Member

Can you please check the documentation, if the removed tooltips should or need to be somehow replaced by some note?

@Clunphumb
Copy link
Contributor Author

An explanation of the entries is found under Save Actions.
Personally, I wouldn't look in this subsection for the information, but with the search this can be found easily. I think there are no changes necessary in the documentation.

@koppor koppor added the ui label Sep 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

remove 2nd click on entry type for changing entry type?
4 participants