mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
Colors: 2 news colors, mHover+mOnHover - autocomputed. Using them for all hovers instead of mTertiary.
This commit is contained in:
+1
-1
@@ -13,7 +13,7 @@ Rectangle {
|
||||
property string tooltipText
|
||||
property color backgroundColor: Color.mPrimary
|
||||
property color textColor: Color.mOnPrimary
|
||||
property color hoverColor: Color.mTertiary
|
||||
property color hoverColor: Color.mHover
|
||||
property bool enabled: true
|
||||
property real fontSize: Style.fontSizeM
|
||||
property int fontWeight: Style.fontWeightBold
|
||||
|
||||
@@ -147,7 +147,7 @@ RowLayout {
|
||||
|
||||
background: Rectangle {
|
||||
width: parentComboBox ? parentComboBox.width - Style.marginM * 3 : 0
|
||||
color: highlighted ? Color.mTertiary : Color.transparent
|
||||
color: highlighted ? Color.mHover : Color.transparent
|
||||
radius: Style.radiusS
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
@@ -162,7 +162,7 @@ RowLayout {
|
||||
return item && item.name ? item.name : ""
|
||||
}
|
||||
pointSize: Style.fontSizeM
|
||||
color: highlighted ? Color.mOnTertiary : Color.mOnSurface
|
||||
color: highlighted ? Color.mOnHover : Color.mOnSurface
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
elide: Text.ElideRight
|
||||
Behavior on color {
|
||||
|
||||
@@ -44,7 +44,7 @@ Popup {
|
||||
property var popup: root
|
||||
|
||||
background: Rectangle {
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mTertiary : Color.transparent
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mHover : Color.transparent
|
||||
radius: Style.radiusS
|
||||
|
||||
Behavior on color {
|
||||
@@ -62,7 +62,7 @@ Popup {
|
||||
visible: modelData.icon !== undefined
|
||||
icon: modelData.icon || ""
|
||||
pointSize: Style.fontSizeM
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mOnTertiary : Color.mOnSurface
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mOnHover : Color.mOnSurface
|
||||
Layout.leftMargin: root.itemPadding
|
||||
|
||||
Behavior on color {
|
||||
@@ -75,7 +75,7 @@ Popup {
|
||||
NText {
|
||||
text: modelData.label || modelData.text || ""
|
||||
pointSize: Style.fontSizeM
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mOnTertiary : Color.mOnSurface
|
||||
color: menuItem.hovered && menuItem.enabled ? Color.mOnHover : Color.mOnSurface
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: modelData.icon === undefined ? root.itemPadding : 0
|
||||
|
||||
@@ -423,7 +423,7 @@ Popup {
|
||||
implicitWidth: 6
|
||||
implicitHeight: 100
|
||||
radius: Style.radiusM
|
||||
color: parent.pressed ? Qt.alpha(Color.mTertiary, 0.8) : parent.hovered ? Qt.alpha(Color.mTertiary, 0.8) : Qt.alpha(Color.mTertiary, 0.8)
|
||||
color: Qt.alpha(Color.mHover, 0.8)
|
||||
opacity: parent.policy === ScrollBar.AlwaysOn || parent.active ? 1.0 : 0.0
|
||||
Behavior on opacity {
|
||||
NumberAnimation {
|
||||
@@ -503,9 +503,9 @@ Popup {
|
||||
|
||||
Rectangle {
|
||||
anchors.fill: parent
|
||||
color: (mouseArea.containsMouse && !isSelected) ? Color.mTertiary : Color.transparent
|
||||
color: (mouseArea.containsMouse && !isSelected) ? Color.mHover : Color.transparent
|
||||
radius: parent.radius
|
||||
border.color: (mouseArea.containsMouse && !isSelected) ? Color.mTertiary : Color.transparent
|
||||
border.color: (mouseArea.containsMouse && !isSelected) ? Color.mHover : Color.transparent
|
||||
border.width: Style.borderS
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
@@ -575,7 +575,7 @@ Popup {
|
||||
if (isSelected)
|
||||
return Color.mSecondary
|
||||
else if (mouseArea.containsMouse)
|
||||
return model.fileIsDir ? Color.mOnTertiary : Color.mOnTertiary
|
||||
return Color.mOnHover
|
||||
else
|
||||
return model.fileIsDir ? Color.mPrimary : Color.mOnSurfaceVariant
|
||||
}
|
||||
@@ -609,7 +609,7 @@ Popup {
|
||||
if (isSelected)
|
||||
return Color.mSecondary
|
||||
else if (mouseArea.containsMouse)
|
||||
return Color.mOnTertiary
|
||||
return Color.mOnHover
|
||||
else
|
||||
return Color.mOnSurfaceVariant
|
||||
}
|
||||
@@ -681,7 +681,7 @@ Popup {
|
||||
if (filePickerPanel.currentSelection.includes(model.filePath))
|
||||
return Color.mSecondary
|
||||
if (mouseArea.containsMouse)
|
||||
return Color.mTertiary
|
||||
return Color.mHover
|
||||
return Color.transparent
|
||||
}
|
||||
radius: Style.radiusS
|
||||
|
||||
@@ -20,8 +20,8 @@ Rectangle {
|
||||
|
||||
property color colorBg: Color.mSurfaceVariant
|
||||
property color colorFg: Color.mPrimary
|
||||
property color colorBgHover: Color.mTertiary
|
||||
property color colorFgHover: Color.mOnTertiary
|
||||
property color colorBgHover: Color.mHover
|
||||
property color colorFgHover: Color.mOnHover
|
||||
property color colorBorder: Color.mOutline
|
||||
property color colorBorderHover: Color.mOutline
|
||||
|
||||
|
||||
@@ -26,8 +26,8 @@ Rectangle {
|
||||
// Color properties
|
||||
property color colorBg: Color.mSurfaceVariant
|
||||
property color colorFg: Color.mPrimary
|
||||
property color colorBgHover: Color.mTertiary
|
||||
property color colorFgHover: Color.mOnTertiary
|
||||
property color colorBgHover: Color.mHover
|
||||
property color colorFgHover: Color.mOnHover
|
||||
property color colorBorder: Color.mOutline
|
||||
property color colorBorderHover: Color.mOutline
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ RowLayout {
|
||||
icon: root.actionButtonIcon
|
||||
backgroundColor: Color.mSecondary
|
||||
textColor: Color.mOnSecondary
|
||||
hoverColor: Color.mTertiary
|
||||
hoverColor: Color.mHover
|
||||
enabled: root.actionButtonEnabled
|
||||
|
||||
onClicked: {
|
||||
|
||||
@@ -6,7 +6,7 @@ import qs.Commons
|
||||
Item {
|
||||
id: root
|
||||
|
||||
property color handleColor: Qt.alpha(Color.mTertiary, 0.8)
|
||||
property color handleColor: Qt.alpha(Color.mHover, 0.8)
|
||||
property color handleHoverColor: handleColor
|
||||
property color handlePressedColor: handleColor
|
||||
property color trackColor: Color.transparent
|
||||
|
||||
+2
-2
@@ -608,7 +608,7 @@ Loader {
|
||||
anchors.fill: parent
|
||||
anchors.margins: 0
|
||||
color: Color.transparent
|
||||
border.color: Color.mTertiary
|
||||
border.color: Color.mPrimary
|
||||
border.width: Style.borderM
|
||||
radius: Style.radiusL
|
||||
visible: panelBackground.isDragged && dragHandler.active
|
||||
@@ -620,7 +620,7 @@ Loader {
|
||||
anchors.fill: parent
|
||||
anchors.margins: 0
|
||||
color: Color.transparent
|
||||
border.color: Color.mTertiary
|
||||
border.color: Color.mPrimary
|
||||
border.width: Style.borderS
|
||||
radius: Style.radiusL
|
||||
opacity: 0.3
|
||||
|
||||
@@ -6,7 +6,7 @@ import qs.Commons
|
||||
T.ScrollView {
|
||||
id: root
|
||||
|
||||
property color handleColor: Qt.alpha(Color.mTertiary, 0.8)
|
||||
property color handleColor: Qt.alpha(Color.mHover, 0.8)
|
||||
property color handleHoverColor: handleColor
|
||||
property color handlePressedColor: handleColor
|
||||
property color trackColor: Color.transparent
|
||||
|
||||
@@ -218,7 +218,7 @@ RowLayout {
|
||||
NText {
|
||||
text: name
|
||||
pointSize: Style.fontSizeM
|
||||
color: highlighted ? Color.mOnTertiary : Color.mOnSurface
|
||||
color: highlighted ? Color.mOnHover : Color.mOnSurface
|
||||
verticalAlignment: Text.AlignVCenter
|
||||
elide: Text.ElideRight
|
||||
Layout.fillWidth: true
|
||||
@@ -245,7 +245,7 @@ RowLayout {
|
||||
text: modelData
|
||||
pointSize: Style.fontSizeXXS
|
||||
font.weight: Style.fontWeightBold
|
||||
color: highlighted ? Color.mOnTertiary : Color.mOnSurface
|
||||
color: highlighted ? Color.mOnHover : Color.mOnSurface
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -253,7 +253,7 @@ RowLayout {
|
||||
}
|
||||
background: Rectangle {
|
||||
width: listView.width
|
||||
color: highlighted ? Color.mTertiary : Color.transparent
|
||||
color: highlighted ? Color.mHover : Color.transparent
|
||||
radius: Style.radiusS
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
|
||||
+1
-1
@@ -117,7 +117,7 @@ Slider {
|
||||
implicitWidth: knobDiameter
|
||||
implicitHeight: knobDiameter
|
||||
radius: width / 2
|
||||
color: root.pressed ? Color.mTertiary : Color.mSurface
|
||||
color: root.pressed ? Color.mHover : Color.mSurface
|
||||
border.color: Color.mPrimary
|
||||
border.width: Style.borderL
|
||||
anchors.centerIn: parent
|
||||
|
||||
@@ -42,7 +42,7 @@ RowLayout {
|
||||
implicitHeight: (root.baseSize - 4)
|
||||
radius: height * 0.5
|
||||
color: Color.mSurfaceVariant
|
||||
border.color: (root.hovering || decreaseArea.containsMouse || increaseArea.containsMouse) ? Color.mTertiary : Color.mOutline
|
||||
border.color: (root.hovering || decreaseArea.containsMouse || increaseArea.containsMouse) ? Color.mHover : Color.mOutline
|
||||
border.width: 1
|
||||
|
||||
Behavior on border.color {
|
||||
@@ -96,7 +96,7 @@ RowLayout {
|
||||
height: parent.height
|
||||
radius: width / 2
|
||||
anchors.left: parent.left
|
||||
color: decreaseArea.containsMouse ? Color.mTertiary : Color.transparent
|
||||
color: decreaseArea.containsMouse ? Color.mHover : Color.transparent
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Style.animationFast
|
||||
@@ -119,7 +119,7 @@ RowLayout {
|
||||
height: 100
|
||||
radius: width / 4
|
||||
|
||||
color: decreaseArea.containsMouse ? Color.mTertiary : Color.transparent
|
||||
color: decreaseArea.containsMouse ? Color.mHover : Color.transparent
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Style.animationFast
|
||||
@@ -154,7 +154,7 @@ RowLayout {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
icon: "chevron-left"
|
||||
pointSize: Style.fontSizeS
|
||||
color: decreaseArea.containsMouse ? Color.mOnTertiary : Color.mPrimary
|
||||
color: decreaseArea.containsMouse ? Color.mOnHover : Color.mPrimary
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
@@ -191,7 +191,7 @@ RowLayout {
|
||||
height: parent.height
|
||||
radius: width / 2
|
||||
anchors.right: parent.right
|
||||
color: increaseArea.containsMouse ? Color.mTertiary : Color.transparent
|
||||
color: increaseArea.containsMouse ? Color.mHover : Color.transparent
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Style.animationFast
|
||||
@@ -214,7 +214,7 @@ RowLayout {
|
||||
height: 100
|
||||
radius: width / 4
|
||||
|
||||
color: increaseArea.containsMouse ? Color.mTertiary : Color.transparent
|
||||
color: increaseArea.containsMouse ? Color.mHover : Color.transparent
|
||||
Behavior on color {
|
||||
ColorAnimation {
|
||||
duration: Style.animationFast
|
||||
@@ -249,7 +249,7 @@ RowLayout {
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
icon: "chevron-right"
|
||||
pointSize: Style.fontSizeS
|
||||
color: increaseArea.containsMouse ? Color.mOnTertiary : Color.mPrimary
|
||||
color: increaseArea.containsMouse ? Color.mOnHover : Color.mPrimary
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
|
||||
Reference in New Issue
Block a user