From 7611d7a350005c42f252b3a427424d80cdb95c9f Mon Sep 17 00:00:00 2001 From: Le Tan Date: Wed, 6 Dec 2017 22:13:40 +0800 Subject: [PATCH] refine v_white theme --- src/resources/themes/v_white/v_white.palette | 13 ++++-- src/resources/themes/v_white/v_white.qss | 48 ++++++++++++++++++-- 2 files changed, 54 insertions(+), 7 deletions(-) diff --git a/src/resources/themes/v_white/v_white.palette b/src/resources/themes/v_white/v_white.palette index 04df7827..ed2e1f43 100644 --- a/src/resources/themes/v_white/v_white.palette +++ b/src/resources/themes/v_white/v_white.palette @@ -16,19 +16,19 @@ title_fg=#000000 title_bg=#DADBDB hover_fg=#000000 -hover_bg=#BCBCBC +hover_bg=#C0C0C0 selected_fg=#000000 -selected_bg=#D3D3D3 +selected_bg=#BCBCBC active_fg=#000000 active_bg=#C0C0C0 inactive_fg=#000000 -inactive_bg=#D0D0D0 +inactive_bg=#D3D3D3 focus_fg=#000000 -focus_bg=#C0C0C0 +focus_bg=#A9A9A9 pressed_fg=#000000 pressed_bg=#808080 @@ -121,19 +121,24 @@ pushbutton_default_border=#424242 pushbutton_cornerbtn_hover_bg=@hover_bg pushbutton_cornerbtn_focus_bg=@focus_bg +pushbutton_cornerbtn_pressed_bg=@pressed_bg pushbutton_statusbtn_hover_bg=@hover_bg pushbutton_statusbtn_focus_bg=@focus_bg +pushbutton_statusbtn_pressed_bg=@pressed_bg pushbutton_flatbtn_hover_bg=@hover_bg pushbutton_flatbtn_focus_bg=@focus_bg +pushbutton_flatbtn_pressed_bg=@pressed_bg pushbutton_selectionbtn_hover_bg=@hover_bg pushbutton_selectionbtn_focus_bg=@focus_bg +pushbutton_selectionbtn_pressed_bg=@pressed_bg pushbutton_titlebtn_bg=@title_bg pushbutton_titlebtn_hover_bg=@hover_bg pushbutton_titlebtn_focus_bg=@focus_bg +pushbutton_titlebtn_pressed_bg=@pressed_bg pushbutton_dangerbtn_fg=#FFF pushbutton_dangerbtn_border=#D43F3A diff --git a/src/resources/themes/v_white/v_white.qss b/src/resources/themes/v_white/v_white.qss index 2436f25e..e24ebd45 100644 --- a/src/resources/themes/v_white/v_white.qss +++ b/src/resources/themes/v_white/v_white.qss @@ -64,7 +64,7 @@ QMenu::item:selected { } QMenu::icon:checked { /* appearance of a 'checked' icon */ - border: 2px solid @menu_item_selected_bg; + border: 2px solid @menu_fg; } QMenu::separator { @@ -84,6 +84,7 @@ QToolBar { background: @toolbar_bg; } +/* QToolButton */ QToolButton { border: none; background: transparent; @@ -104,20 +105,31 @@ QToolButton:hover { background: @toolbutton_hover_bg; } -QToolButton::pressed { +QToolButton:pressed { background: @toolbutton_pressed_bg; } -QToolButton::checked { +QToolButton:checked { background: @toolbutton_checked_bg; } +QToolButton:checked:hover { + background: @toolbutton_hover_bg; +} + /* the subcontrols below are used only in the MenuButtonPopup mode */ QToolButton::menu-button { border: none; width: 16px; } +QToolButton::menu-arrow { + image: url(arrow_dropdown.svg); + width: 16px; + height: 16px; +} +/* End QToolButton*/ + /* DockWidget */ QDockWidget { titlebar-close-icon: url(close.svg); @@ -155,6 +167,10 @@ QPushButton:checked { background-color: @pushbutton_checked_bg; } +QPushButton:checked:hover { + background-color: @pushbutton_hover_bg; +} + QPushButton:hover { background-color: @pushbutton_hover_bg; } @@ -167,6 +183,12 @@ QPushButton::default { border-color: @pushbutton_default_border; } +QPushButton::menu-indicator { + image: url(arrow_dropdown.svg); + width: 16px; + height: 16px; +} + QPushButton[CornerBtn="true"] { padding: 4px -2px 4px -2px; margin: 0px; @@ -187,6 +209,10 @@ QPushButton[CornerBtn="true"]:focus { background-color: @pushbutton_cornerbtn_focus_bg; } +QPushButton[CornerBtn="true"]:pressed { + background-color: @pushbutton_cornerbtn_pressed_bg; +} + QPushButton[StatusBtn="true"] { font: bold; padding: 0px 2px 0px 2px; @@ -204,6 +230,10 @@ QPushButton[StatusBtn="true"]:focus { background-color: @pushbutton_statusbtn_focus_bg;; } +QPushButton[StatusBtn="true"]:pressed { + background-color: @pushbutton_statusbtn_pressed_bg; +} + QPushButton[FlatBtn="true"] { padding: 4px; margin: 0px; @@ -220,6 +250,10 @@ QPushButton[FlatBtn="true"]:focus { background-color: @pushbutton_flatbtn_focus_bg; } +QPushButton[FlatBtn="true"]:focus { + background-color: @pushbutton_flatbtn_pressed_bg; +} + QPushButton[SelectionBtn="true"] { padding: 4px 10px 4px 10px; border: none; @@ -237,6 +271,10 @@ QPushButton[SelectionBtn="true"]:focus { background-color: @pushbutton_selectionbtn_focus_bg; } +QPushButton[SelectionBtn="true"]:focus { + background-color: @pushbutton_selectionbtn_pressed_bg; +} + QPushButton[TitleBtn="true"] { padding: 4px; margin: 0px; @@ -253,6 +291,10 @@ QPushButton[TitleBtn="true"]:focus { background-color: @pushbutton_titlebtn_focus_bg; } +QPushButton[TitleBtn="true"]:focus { + background-color: @pushbutton_titlebtn_pressed_bg; +} + QPushButton[DangerBtn="true"] { color: @pushbutton_dangerbtn_fg; border-color: @pushbutton_dangerbtn_border;