Differential D27488 Diff 75948 plugins/kdecorations/aurorae/themes/plastik/package/contents/ui/main.qml
Changeset View
Changeset View
Standalone View
Standalone View
plugins/kdecorations/aurorae/themes/plastik/package/contents/ui/main.qml
Show First 20 Lines • Show All 70 Lines • ▼ Show 20 Line(s) | 70 | } else if (titleAlignCenter) { | |||
---|---|---|---|---|---|
71 | root.titleAlignment = Text.AlignHCenter; | 71 | root.titleAlignment = Text.AlignHCenter; | ||
72 | } else { | 72 | } else { | ||
73 | if (!titleAlignLeft) { | 73 | if (!titleAlignLeft) { | ||
74 | console.log("Error reading title alignment: all alignment options are false"); | 74 | console.log("Error reading title alignment: all alignment options are false"); | ||
75 | } | 75 | } | ||
76 | root.titleAlignment = Text.AlignLeft; | 76 | root.titleAlignment = Text.AlignLeft; | ||
77 | } | 77 | } | ||
78 | root.animateButtons = decoration.readConfig("animateButtons", true); | 78 | root.animateButtons = decoration.readConfig("animateButtons", true); | ||
79 | root.titleShadow = decoration.readConfig("titleShadow", true); | | |||
80 | if (decoration.animationsSupported) { | 79 | if (decoration.animationsSupported) { | ||
81 | root.animationDuration = 150; | 80 | root.animationDuration = 150; | ||
82 | root.animateButtons = false; | 81 | root.animateButtons = false; | ||
83 | } | 82 | } | ||
84 | } | 83 | } | ||
85 | ColorHelper { | 84 | ColorHelper { | ||
86 | id: colorHelper | 85 | id: colorHelper | ||
87 | } | 86 | } | ||
88 | DecorationOptions { | 87 | DecorationOptions { | ||
89 | id: options | 88 | id: options | ||
90 | deco: decoration | 89 | deco: decoration | ||
91 | } | 90 | } | ||
92 | property int borderSize: decorationSettings.borderSize | 91 | property int borderSize: decorationSettings.borderSize | ||
93 | property alias buttonSize: titleRow.captionHeight | 92 | property alias buttonSize: titleRow.captionHeight | ||
94 | property alias titleAlignment: caption.horizontalAlignment | 93 | property alias titleAlignment: caption.horizontalAlignment | ||
95 | property color titleBarColor: options.titleBarColor | 94 | property color titleBarColor: options.titleBarColor | ||
96 | // set by readConfig after Component completed, ensures that buttons do not flicker | 95 | // set by readConfig after Component completed, ensures that buttons do not flicker | ||
97 | property int animationDuration: 0 | 96 | property int animationDuration: 0 | ||
98 | property bool animateButtons: true | 97 | property bool animateButtons: true | ||
99 | property bool titleShadow: true | | |||
100 | Behavior on titleBarColor { | 98 | Behavior on titleBarColor { | ||
101 | ColorAnimation { | 99 | ColorAnimation { | ||
102 | duration: root.animationDuration | 100 | duration: root.animationDuration | ||
103 | } | 101 | } | ||
104 | } | 102 | } | ||
105 | id: root | 103 | id: root | ||
106 | alpha: false | 104 | alpha: false | ||
107 | Rectangle { | 105 | Rectangle { | ||
▲ Show 20 Lines • Show All 163 Lines • ▼ Show 20 Line(s) | 263 | anchors { | |||
271 | topMargin: 3 | 269 | topMargin: 3 | ||
272 | } | 270 | } | ||
273 | color: options.fontColor | 271 | color: options.fontColor | ||
274 | Behavior on color { | 272 | Behavior on color { | ||
275 | ColorAnimation { duration: root.animationDuration } | 273 | ColorAnimation { duration: root.animationDuration } | ||
276 | } | 274 | } | ||
277 | text: decoration.client.caption | 275 | text: decoration.client.caption | ||
278 | font: options.titleFont | 276 | font: options.titleFont | ||
279 | style: root.titleShadow ? Text.Raised : Text.Normal | | |||
280 | styleColor: colorHelper.shade(color, ColorHelper.ShadowShade) | | |||
281 | elide: Text.ElideMiddle | 277 | elide: Text.ElideMiddle | ||
282 | renderType: Text.NativeRendering | 278 | renderType: Text.NativeRendering | ||
283 | } | 279 | } | ||
284 | ButtonGroup { | 280 | ButtonGroup { | ||
285 | id: rightButtonGroup | 281 | id: rightButtonGroup | ||
286 | spacing: 1 | 282 | spacing: 1 | ||
287 | explicitSpacer: root.buttonSize | 283 | explicitSpacer: root.buttonSize | ||
288 | menuButton: menuButtonComponent | 284 | menuButton: menuButtonComponent | ||
▲ Show 20 Lines • Show All 141 Lines • Show Last 20 Lines |