#21148 closed defect (fixed)
[Patch] Context specific help (F1) not properly working in menus
Reported by: | skyper | Owned by: | Don-vip |
---|---|---|---|
Priority: | normal | Milestone: | 21.07 |
Component: | Core | Version: | latest |
Keywords: | template_report context sensitive help menu item | Cc: | DevCharly |
Description (last modified by )
What steps will reproduce the problem?
- Select a way
- Hoover the mouse over File menu -> Download data
- Press
F1
What is the expected result?
The existing wiki page for the action is opened in help browser
What happens instead?
I land at the main help page.
Please provide any additional information below. Attach a screenshot if possible.
Hoovering over the button in Main Toolbar, the proper path is used but all menu items are affected.
Both Dark modes suffer the same issue.
Does not happen when using metal
Relative:URL: ^/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2021-07-20 19:23:32 +0200 (Tue, 20 Jul 2021) Revision:18078 Build-Date:2021-07-20 17:59:14 Look and Feel: com.formdev.flatlaf.FlatIntelliJLaf Plugins: + flatlaf (35734)
Attachments (1)
Change History (14)
comment:1 by , 4 years ago
Keywords: | sensitive added |
---|
comment:2 by , 4 years ago
Cc: | added |
---|---|
Component: | Plugin utilsplugin2 → Plugin flatlaf |
Description: | modified (diff) |
Keywords: | menu item added |
Owner: | changed from | to
Summary: | Context specific help (F1) not properly working for many actions → Context specific help (F1) not properly working for in menu |
comment:3 by , 4 years ago
Summary: | Context specific help (F1) not properly working for in menu → Context specific help (F1) not properly working in menus |
---|
comment:4 by , 4 years ago
This also depends on the used Java version.
In Java 11 and FlatLaf it works.
In Java 8 and FlatLaf it does not...
follow-up: 7 comment:5 by , 4 years ago
Ok, forget my previous comment. It has nothing to do with used Java version.
It depends on whether the menu fits into the main window or not.
If it fits, then a light-weight popup is used and F1 works as expected.
If the menu is large and does not fit into the main window, then a heavy-weight popup is used to display the menu (because it is partly outside of the main frame). Then the implementation in JOSM's HelpAction class does not find the menu item and F1 does not work correctly.
This is not related to FlatLaf.
It occurs in all L&Fs.
by , 4 years ago
Attachment: | JOSM-context-help.diff added |
---|
comment:6 by , 4 years ago
I've attached a patch that first looks into MenuSelectionManager for selected menu item.
comment:7 by , 4 years ago
Replying to DevCharly:
It depends on whether the menu fits into the main window or not.
No, it happens in all cases with the flatlaf plugin. I first noticed this with utilsplugin2 items like "More Tools -> Split Object" or "Selection -> Undo Selection" which work fine with "Metal".
comment:8 by , 4 years ago
No, it happens in all cases with the flatlaf plugin.
Aha, yes, then you're on Linux or macOS, right?
On these two platforms, FlatLaf always uses heavy-weight popups because then the OS adds drop shadows to the popup.
I've tested only on Windows. Sorry.
Anyway, the patch should work on all platforms :)
comment:9 by , 4 years ago
Component: | Plugin flatlaf → Core |
---|---|
Owner: | changed from | to
Version: | → latest |
Arrg, sorry I forgot:
Identification: JOSM/1.5 (18097 en) Linux Debian GNU/Linux 10 (buster) Java version: 11.0.12+7-post-Debian-2deb10u1, Debian, OpenJDK 64-Bit Server VM
comment:10 by , 4 years ago
Summary: | Context specific help (F1) not properly working in menus → [Patch] Context specific help (F1) not properly working in menus |
---|
comment:11 by , 4 years ago
Milestone: | → 21.07 |
---|---|
Owner: | changed from | to
Status: | new → assigned |
Oh no, again the flatlaf plugin and all menu items suffer the same issue. I changed the description.