From 6ae405a073b15389b7926ef8aa91c3b228a7889e Mon Sep 17 00:00:00 2001 From: Matthias Metelka <62722460+kleinerpirat@users.noreply.github.com> Date: Mon, 10 Oct 2022 00:05:02 +0200 Subject: [PATCH] Add QMenuBar styles with increased height for touchscreen users and more visible highlight color. --- qt/aqt/stylesheets.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/qt/aqt/stylesheets.py b/qt/aqt/stylesheets.py index 69260f20f..e2a371039 100644 --- a/qt/aqt/stylesheets.py +++ b/qt/aqt/stylesheets.py @@ -64,6 +64,19 @@ QToolTip {{ def menu_styles(tm: ThemeManager()) -> str: return f""" +QMenuBar {{ + background-color: {tm.var(colors.CANVAS)}; + border-bottom: 1px solid {tm.var(colors.BORDER)}; +}} +QMenuBar::item {{ + background-color: transparent; + padding: 6px; + margin: 2px; +}} +QMenuBar::item:selected {{ + background-color: {tm.var(colors.HIGHLIGHT_BG)}; + border-radius: {tm.var(props.BORDER_RADIUS)}; +}} QMenu {{ background-color: {tm.var(colors.CANVAS_OVERLAY)}; border: 1px solid {tm.var(colors.BORDER)};