forked from Shinonome/dots-hyprland
material symbols: prevent memory spikes
This commit is contained in:
@@ -6,6 +6,7 @@ Text {
|
|||||||
id: root
|
id: root
|
||||||
property real iconSize: Appearance?.font.pixelSize.small ?? 16
|
property real iconSize: Appearance?.font.pixelSize.small ?? 16
|
||||||
property real fill: 0
|
property real fill: 0
|
||||||
|
property real truncatedFill: Math.round(fill * 100) / 100 // Reduce memory consumption spikes from constant font remapping
|
||||||
renderType: Text.NativeRendering
|
renderType: Text.NativeRendering
|
||||||
font.hintingPreference: Font.PreferFullHinting
|
font.hintingPreference: Font.PreferFullHinting
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
@@ -22,7 +23,7 @@ Text {
|
|||||||
}
|
}
|
||||||
|
|
||||||
font.variableAxes: {
|
font.variableAxes: {
|
||||||
"FILL": fill,
|
"FILL": truncatedFill,
|
||||||
// "wght": font.weight,
|
// "wght": font.weight,
|
||||||
// "GRAD": 0,
|
// "GRAD": 0,
|
||||||
"opsz": iconSize,
|
"opsz": iconSize,
|
||||||
|
|||||||
Reference in New Issue
Block a user