Fixes: removed extra padding on icon
This commit is contained in:
@@ -7,7 +7,15 @@ import "../../config"
|
|||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
implicitWidth: label.implicitWidth + 4
|
// Independent left/right breathing room around the glyph. Material
|
||||||
|
// Symbols icons aren't monospaced — each one's font-reported advance
|
||||||
|
// width (label.implicitWidth) bakes in its own side bearings, so the
|
||||||
|
// same "+4, centered" math that every other bar icon uses can still
|
||||||
|
// look tighter/looser icon-to-icon. Tune these two by eye instead of
|
||||||
|
// the icon's own bounding box to even it out against its neighbours.
|
||||||
|
property real iconLeftPadding: 0
|
||||||
|
property real iconRightPadding: 0
|
||||||
|
implicitWidth: root.iconLeftPadding + label.implicitWidth + root.iconRightPadding
|
||||||
implicitHeight: Appearance.barHeight
|
implicitHeight: Appearance.barHeight
|
||||||
|
|
||||||
// The bar's own PanelWindow — passed in from Bar.qml so this popup can
|
// The bar's own PanelWindow — passed in from Bar.qml so this popup can
|
||||||
@@ -128,7 +136,9 @@ Item {
|
|||||||
|
|
||||||
Text {
|
Text {
|
||||||
id: label
|
id: label
|
||||||
anchors.centerIn: parent
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
anchors.left: parent.left
|
||||||
|
anchors.leftMargin: root.iconLeftPadding
|
||||||
font.family: Appearance.iconFontFamilyRounded
|
font.family: Appearance.iconFontFamilyRounded
|
||||||
font.variableAxes: Appearance.iconFontAxes
|
font.variableAxes: Appearance.iconFontAxes
|
||||||
font.pixelSize: 16
|
font.pixelSize: 16
|
||||||
|
|||||||
Reference in New Issue
Block a user