From a4be03cd5fa8d647c3c242fdc30167b8e3b71d40 Mon Sep 17 00:00:00 2001 From: end-4 <97237370+end-4@users.noreply.github.com> Date: Wed, 15 Oct 2025 13:06:41 +0200 Subject: [PATCH] enable icon fill anim again --- .../modules/common/widgets/MaterialSymbol.qml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/.config/quickshell/ii/modules/common/widgets/MaterialSymbol.qml b/.config/quickshell/ii/modules/common/widgets/MaterialSymbol.qml index 75ff77d9b..a72d911ab 100644 --- a/.config/quickshell/ii/modules/common/widgets/MaterialSymbol.qml +++ b/.config/quickshell/ii/modules/common/widgets/MaterialSymbol.qml @@ -5,13 +5,13 @@ StyledText { id: root property real iconSize: Appearance?.font.pixelSize.small ?? 16 property real fill: 0 - property real truncatedFill: Math.round(fill * 100) / 100 // Reduce memory consumption spikes from constant font remapping + property real truncatedFill: fill.toFixed(1) // Reduce memory consumption spikes from constant font remapping renderType: fill !== 0 ? Text.CurveRendering : Text.NativeRendering font { hintingPreference: Font.PreferFullHinting family: Appearance?.font.family.iconMaterial ?? "Material Symbols Rounded" pixelSize: iconSize - weight: Font.Normal + (Font.DemiBold - Font.Normal) * fill + weight: Font.Normal + (Font.DemiBold - Font.Normal) * truncatedFill variableAxes: { "FILL": truncatedFill, // "wght": font.weight, @@ -20,11 +20,11 @@ StyledText { } } - // Behavior on fill { // Leaky leaky, no good - // NumberAnimation { - // duration: Appearance?.animation.elementMoveFast.duration ?? 200 - // easing.type: Appearance?.animation.elementMoveFast.type ?? Easing.BezierSpline - // easing.bezierCurve: Appearance?.animation.elementMoveFast.bezierCurve ?? [0.34, 0.80, 0.34, 1.00, 1, 1] - // } - // } + Behavior on fill { // Leaky leaky, no good + NumberAnimation { + duration: Appearance?.animation.elementMoveFast.duration ?? 200 + easing.type: Appearance?.animation.elementMoveFast.type ?? Easing.BezierSpline + easing.bezierCurve: Appearance?.animation.elementMoveFast.bezierCurve ?? [0.34, 0.80, 0.34, 1.00, 1, 1] + } + } }