LIM: Respect Menu Font Settings
Current behaviour:
Currently LIM uses the Window title font settings
Expected behaviour:
LIM should use the Menu font settings
Steps to Reproduce:
Open KDE “System Settings”
Under Appearance click on Fonts
Change the font settings for Menu and Window title
Click Apply

Additional Information: System OS: Solus Plasma material-decoration: 65fe6f577a978a9e601241d29bea35185eb7f69c built & packaged solbuild package-material-decoration.yml
The actual (dropdown section) menu follows menu font. Menu items in the titlebar use titlebar font - actually this looks good to me.
@ben2talk thanks for pointing that out, don't know how I missed that. I mainly opened the bug report since the menu was not following the expected behaviour (to me anyways).
It could be argued that:
- since the LIM is integrated with titlebar it should; all elements in inside titlebar itself should use the
Window titlesettings - since changing the
Menusettings effects the entire menu in KDE by default; LIM should respect that
If the current behaviour is preferred/expected; I would like to know how feasible would it be to add a toggle between the two settings (Window title & Menu)?
I won't be adding an option, but you can modify it to do so.
- Here's where material draws the menu in the titlebar:
- https://github.com/Zren/material-decoration/blob/master/src/TextButton.cc#L59
- Here's how the KDecoration API calculates the titlebar
QFont:- https://github.com/KDE/kdecoration/blob/master/src/private/decorationsettingsprivate.cpp#L46-L49
- https://doc.qt.io/qt-5/qfontdatabase.html#SystemFont-enum
- No idea how to get the font for the menu.
- https://github.com/KDE/breeze/blob/master/kstyle/breezestyle.cpp#L4796
- https://doc.qt.io/qt-5/qfont.html
It's probably easier to hardcode a QFont with the desired size + family.
Hello, just to mention that I've implemented the option in my fork: https://github.com/hexclover/material-decoration. Feel free to test it out.
With the option ON:

With the option OFF:

@hexclover I just built and tested your Material-Decorations fork.
After some quick testing it I noticed that the Use menu font when drawing menu items option uses the general font not the menu font. (I use the same font for both so I'm happy with it as is.)
System Information:
| Operating System: | Solus 4.3 |
| Kernel Version: | 5.15.50-216-zfs |
| KDE Plasma Version: | 5.25.3 |
| KDE Frameworks Version: | 5.96.0 |
| QT Version: | 5.15.5 |
| Graphics Platform: | X11 |
commit c089983 | hexclover fork
@QORTEC Hello, what was your testing procedure? Can you try the following steps:
- In system settings, set General and Menu fonts to different fonts.
- Logout and login again. Or, at least restart KWin.
- Try toggling the option. Did it work?
@hexclover, it works! Kinda?
There seems to be a bug, when you change a font the menu uses the general font.
Restarting kwin resets the menu to use the menu font.
Steps to Reproduce:
- change any font whatsoever
- apply said change
Result:
The menu uses the general font.
Expected Behaviour:
The menu uses the menu font.
Workaround:
Restart kwin, the menu will use the menu font.
@QORTEC Yes, there seems to be a long-standing bug in KDE (?): If you change any (?) of the font settings and apply them, applications will start to use the General font for menus until restart. I don't think this is related/specific to material-decoration.