From aa8a72a9d8c8dde42f4fd547bf7fb85db6cf5993 Mon Sep 17 00:00:00 2001 From: Ly-sec Date: Tue, 26 Aug 2025 20:05:45 +0200 Subject: [PATCH] Fix named workspace text positioning Workspace.qml: add slight centerOffset --- Modules/Bar/Widgets/Workspace.qml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Modules/Bar/Widgets/Workspace.qml b/Modules/Bar/Widgets/Workspace.qml index 8dc2b9e..3bf9ff4 100644 --- a/Modules/Bar/Widgets/Workspace.qml +++ b/Modules/Bar/Widgets/Workspace.qml @@ -161,6 +161,18 @@ Item { Loader { anchors.centerIn: parent + anchors.verticalCenterOffset: { + if (model.isFocused) + return 0 + if (model.name && model.name.length > 0) + return 1 * scaling + return 0 + } + anchors.horizontalCenterOffset: { + if (model.name && model.name.length > 0) + return 0.5 * scaling + return 0 + } active: Settings.data.bar.showWorkspacesNames sourceComponent: Component { Text { @@ -173,6 +185,7 @@ Item { } font.pointSize: model.isFocused ? Style.fontSizeXS * scaling : Style.fontSizeXXS * scaling font.capitalization: Font.AllUppercase + //font.family: Settings.data.ui.fontFixed horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter wrapMode: Text.Wrap