Skip to content

Commit

Permalink
Add QCalendarWidget selection color only Qt5 (#209)
Browse files Browse the repository at this point in the history
  • Loading branch information
5yutan5 authored Dec 12, 2022
1 parent 30de3a7 commit 2674848
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion qdarktheme/_resources/_template_stylesheet.py
Original file line number Diff line number Diff line change
Expand Up @@ -999,7 +999,9 @@
border-radius: {{ corner-shape|corner(size=4) }}px;
border-top-left-radius: {{ corner-shape|corner(size=0) }};
border-top-right-radius: {{ corner-shape|corner(size=0) }};
alternate-background-color: {{ table.alternateBackground|color }}
alternate-background-color: {{ table.alternateBackground|color }};
{{ corner-shape|corner(size=4)|env(value="border-radius: ${}px;", version="<6.0.0", os="Darwin") }}
{{ primary|color(state="table.selectionBackground")|env(value="selection-background-color: ${};", version="<6.0.0") }}
}
QCalendarWidget > .QWidget > QToolButton#qt_calendar_prevmonth {
qproperty-icon: {{ foreground|color(state="icon")|url(id="arrow_upward", rotate=270) }};
Expand Down
5 changes: 4 additions & 1 deletion style/base.qss
Original file line number Diff line number Diff line change
Expand Up @@ -1235,7 +1235,10 @@ QCalendarWidget > QTableView {
border-radius: {{ corner-shape|corner(size=4) }}px;
border-top-left-radius: {{ corner-shape|corner(size=0) }};
border-top-right-radius: {{ corner-shape|corner(size=0) }};
alternate-background-color: {{ table.alternateBackground|color }}
alternate-background-color: {{ table.alternateBackground|color }};
{{ corner-shape|corner(size=4)|env(value="border-radius: ${}px;", version="<6.0.0", os="Darwin") }}
/* Fix 207 */
{{ primary|color(state="table.selectionBackground")|env(value="selection-background-color: ${};", version="<6.0.0") }}
}

/*
Expand Down

0 comments on commit 2674848

Please sign in to comment.