Icons: Plus and Minus

+ removed vertical hack in NIcon
This commit is contained in:
LemmyCook 2025-09-08 16:02:21 -04:00
parent ea6b8e0c02
commit b91112fc7a
7 changed files with 9 additions and 16 deletions

View file

@ -82,7 +82,6 @@ Rectangle {
// Icon (optional)
NIcon {
Layout.alignment: Qt.AlignVCenter
layoutTopMargin: 1 * scaling
visible: root.icon !== ""
text: root.icon
font.pointSize: root.iconSize

View file

@ -3,18 +3,10 @@ import QtQuick.Layouts
import qs.Commons
import qs.Widgets
Text {
// Optional layout nudge for optical alignment when used inside Layouts
property real layoutTopMargin: 0
text: "\uEE15" // default skull icon
text: "\uEE15" // fallback/default to skull icon
font.family: "bootstrap-icons"
font.pointSize: Style.fontSizeL * scaling
font.variableAxes: {
"wght"// slightly bold to ensure all lines looks good
: (Font.Normal + Font.Bold) / 2.5
}
color: Color.mOnSurface
verticalAlignment: Text.AlignVCenter
Layout.topMargin: layoutTopMargin
}

View file

@ -95,7 +95,7 @@ RowLayout {
NIcon {
anchors.centerIn: parent
text: "remove"
text: FontService.icons["minus"]
font.pointSize: Style.fontSizeS * scaling
color: decreaseArea.containsMouse ? Color.mOnPrimary : Color.mPrimary
}
@ -130,7 +130,7 @@ RowLayout {
NIcon {
anchors.centerIn: parent
text: "add"
text: FontService.icons["plus"]
font.pointSize: Style.fontSizeS * scaling
color: increaseArea.containsMouse ? Color.mOnPrimary : Color.mPrimary
}