Bug 445809 - Menu styling: right-aligned shortcut text has unnecessary spacing
Summary: Menu styling: right-aligned shortcut text has unnecessary spacing
Status: RESOLVED FIXED
Alias: None
Product: Breeze
Classification: Plasma
Component: QStyle (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR minor
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-20 13:28 UTC by Philip Murray
Modified: 2023-06-24 10:17 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Dolphin top menu, no icons. Note more space at right side than left. (15.06 KB, image/png)
2021-11-20 13:39 UTC, Philip Murray
Details
Dolphin right-click menu, no icons. Note more space at right of the arrows than left of the text. (28.79 KB, image/png)
2021-11-20 13:40 UTC, Philip Murray
Details
Dolphin - Edit View Go menus (121.84 KB, image/png)
2021-11-24 19:41 UTC, Philip Murray
Details
Debian 11 (left half) v Fedora 35 (right) (138.54 KB, image/png)
2022-02-23 20:19 UTC, Philip Murray
Details
Double Commander file manager with menu icons off/on, as an example of where the text doesn't change position when icons are off. I think this is the ideal method. (39.08 KB, image/png)
2022-04-29 19:58 UTC, Philip Murray
Details
5.25.7 (57.75 KB, image/png)
2023-06-24 10:17 UTC, Philip Murray
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Philip Murray 2021-11-20 13:28:00 UTC
SUMMARY

Dolphin & other applications, when icons are disabled in the menus, the position of the text is not consistently spaced from the left. Radio buttons still exist when icons are disabled & hence any menu with these are aligned further to the right than menus where there are no radio buttons (these are aligned very tightly to the left).

STEPS TO REPRODUCE
1. System Settings > Application Style > Configure Icons and Toolbars > Show icons:L In menus (disable).
2. In Dolphin, view the left spacing of different menus.
3. Any menus that have a radio checkbox in them the menu options text is aligned to the right of them & any options with no radio buttons are aligned to the same point.
4. Any menus that do not have a radio checkbox the menu options text is aligned further to the left.
5. It would be nicer if the menus were consistently spaced from the left, i.e. provide an equal left margin on all menus.

Operating System: Debian GNU/Linux 11
KDE Plasma Version: 5.20.5
KDE Frameworks Version: 5.78.0
Qt Version: 5.15.2
Kernel Version: 5.10.0-9-amd64
OS Type: 64-bit
Processors: 4 × Intel® Core™ i5-4570 CPU @ 3.20GHz
Memory: 7.7 GiB of RAM
Graphics Processor: GeForce GTX 750 Ti/PCIe/SSE2
Comment 1 Philip Murray 2021-11-20 13:38:16 UTC
Also, right-click context menus have the same issue; the text is aligned too tightly to the left. It may be sufficient to just increase the left margin a bit, not necessarily equal to menus that have radio buttons.
Comment 2 Philip Murray 2021-11-20 13:39:47 UTC
Created attachment 143765 [details]
Dolphin top menu, no icons. Note more space at right side than left.
Comment 3 Philip Murray 2021-11-20 13:40:47 UTC
Created attachment 143766 [details]
Dolphin right-click menu, no icons. Note more space at right of the arrows than left of the text.
Comment 4 Nate Graham 2021-11-24 03:59:09 UTC
The issue here, really, is that the shortcut text leaves room on the right for the submenu arrow--which is unnecessary because no menu item with a shortcut can have a submenu, and no submenu has a shortcut.
Comment 5 Jonathan Marten 2021-11-24 18:43:35 UTC
> because no menu item with a shortcut can have a submenu

Is this true?  Konqueror's "Go" menu has Up = Alt+Up, Back = Alt+Left and Forward = Alt+Right all with submenus.
Comment 6 Philip Murray 2021-11-24 19:41:33 UTC
Created attachment 143914 [details]
Dolphin - Edit View Go menus

The Dolphin Go menu also has both shortcuts + submenus.
Screenshot attached showing Dolphin's View, Edit & Go menus. My initial issue was the left side spacing, it seems lot less than that given elsewhere & note the closeness of the View menu's items to the favourites list beneath it. The Go menu looks similarly too close to the left side of the menu, but doesn't isn't quite as bad as there's not a favourites list under it.
Comment 7 Nate Graham 2021-11-24 21:21:51 UTC
OMG LOL

Maybe we can do it for all other cases at least, since that is quite a rare use case.
Comment 8 Janet Blackquill 2022-02-23 18:20:31 UTC
FWIW, we added extra left spacing in the case of no icons/check/radiobuttons in menus some time ago, as to not have this "kissing the left edge" affair going on. Do you think the current look fixes the issue for you?
Comment 9 Philip Murray 2022-02-23 20:19:07 UTC
I've just loaded Fedora35 in a VM & the left gap pixel width has increased from 5 to 8, so that's 3 pixels in the right direction. :) It doesn't look much different though & could do with some more I think. Screenshot attached shortly (left: Debian 11 Plasma 5.20.5, right: Fedora 25 Plasma 5.22.5). Moving them a bit further to the right would be OK. Two more pixels beyond what's in Plasma 5.22.5 would bring it in line with the menu word, e.g. Go & Up to be aligned-left to the same imaginary line, which might be OK-ish. Ideally the menu-items would be indented to the right slightly like they are when icons are enabled (and like you would have for a bullet-pointed list in a word document under a heading). 

The way the text alignment jumps around in 5.22.5 as I move through the File>Edit>View is still quite unpleasant though. This jumping alignment is caused by the square radio buttons being on the left of the text though because if a menu includes a radio button it will push all the entries to the right significantly - it might be better to put radio buttons on the right side?
Comment 10 Philip Murray 2022-02-23 20:19:56 UTC
Created attachment 147079 [details]
Debian 11 (left half) v Fedora 35 (right)
Comment 11 Philip Murray 2022-04-29 19:58:01 UTC
Created attachment 148464 [details]
Double Commander file manager with menu icons off/on, as an example of where the text doesn't change position when icons are off. I think this is the ideal method.
Comment 12 Philip Murray 2022-06-07 11:41:58 UTC
General note: the menu's list of text should always be aligned more to the right than the text at the top, e.g. File, Edit, View etc.
Comment 13 Philip Murray 2023-06-24 10:17:10 UTC
Created attachment 159878 [details]
5.25.7

The spacing in v5.27.5 in Debian 12 looks much nicer now, thanks.
Pic attached shows:
1. Dolphin right-click menu with a more pleasant left margin than before.
2. Dolphin pull-down menu text is now aligned 1 or 2 pixels to the right of the 'Tools' word, and there's a decent margin.
When checkboxes exist in the menu the text all aligns to a larger margin (compared to Double Commander, which leaves a big margin in the fist place, see pics above), but that's basically fine.
Hence, I'll close this bug now.
Comment 14 Philip Murray 2023-06-24 10:17:31 UTC
Closing.