Commit 72450a2a authored by Guo Yunhe's avatar Guo Yunhe

Wallpaper: hide color or blur filling options for full filling mode

Summary:
Related to patch https://phabricator.kde.org/D7047 . Pointed out by @ngraham

Make a new option called "Edge filling". Users can choose either "Blur image" or "Solid color". They are only visible when the image filling mode is "Center" or "Scale and keep ratio".

When it is "Center":

{F5447565}

When it is "Tile":

{F5447053}

Reviewers: ngraham, jensreuterberg

Reviewed By: ngraham, jensreuterberg

Subscribers: jensreuterberg, broulik, ngraham, davidedmundson, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D8441
parent be190d54
......@@ -34,7 +34,7 @@ ColumnLayout {
property alias cfg_Color: colorDialog.color
property string cfg_Image
property int cfg_FillMode
property alias cfg_Blur: blurCheckBox.checked
property alias cfg_Blur: blurRadioButton.checked
property var cfg_SlidePaths: ""
property int cfg_SlideInterval: 0
......@@ -128,21 +128,24 @@ ColumnLayout {
}
}
QtControls.ExclusiveGroup { id: backgroundGroup }
Row {
//x: formAlignment - positionLabel.paintedWidth
id: blurRow
spacing: units.largeSpacing / 2
visible: cfg_FillMode === Image.PreserveAspectFit || cfg_FillMode === Image.Pad
QtControls.Label {
id: blurLabel
width: formAlignment - units.largeSpacing
anchors {
verticalCenter: blurCheckBox.verticalCenter
}
anchors.verticalCenter: blurRadioButton.verticalCenter
horizontalAlignment: Text.AlignRight
text: i18nd("plasma_applet_org.kde.image", "Background:")
}
QtControls.CheckBox {
id: blurCheckBox
text: i18nd("plasma_applet_org.kde.image", "Use blur background filling")
QtControls.RadioButton {
id: blurRadioButton
text: i18nd("plasma_applet_org.kde.image", "Blur")
checked: true
exclusiveGroup: backgroundGroup
}
}
......@@ -155,12 +158,16 @@ ColumnLayout {
Row {
id: colorRow
visible: cfg_FillMode === Image.PreserveAspectFit || cfg_FillMode === Image.Pad
spacing: units.largeSpacing / 2
QtControls.Label {
width: formAlignment - units.largeSpacing
anchors.verticalCenter: colorButton.verticalCenter
horizontalAlignment: Text.AlignRight
text: i18nd("plasma_applet_org.kde.image", "Background Color:")
}
QtControls.RadioButton {
id: colorRadioButton
text: i18nd("plasma_applet_org.kde.image", "Solid color")
checked: false
exclusiveGroup: backgroundGroup
}
QtControls.Button {
id: colorButton
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment