Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
import QtQuick 2.0
import QtQuick.Layouts 1.1
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.kwin.private.kdecoration 1.0 as KDecoration
import org.kde.kquickcontrolsaddons 2.0 as KQuickControlsAddons
Item {
id: main
width: 400
height: 400
KDecoration.Bridge {
id: bridgeItem
// plugin: "org.kde.breeze"
// theme: ""
plugin: "org.kde.kwin.aurorae"
theme: "__aurorae__svg__Adapta"
}
KDecoration.Settings {
id: settingsItem
bridge: bridgeItem.bridge
borderSizesIndex: 3 // Normal
}
KDecoration.Decoration {
id: activePreview
anchors.fill: parent
anchors.margins: units.smallSpacing
bridge: bridgeItem.bridge
settings: settingsItem
Component.onCompleted: {
client.caption = "App Name"
client.active = true;
// anchors.leftMargin = Qt.binding(function() { return 10 - (activePreview.shadow ? activePreview.shadow.paddingLeft : 0);});
// anchors.rightMargin = Qt.binding(function() { return 40 - (activePreview.shadow ? activePreview.shadow.paddingRight : 0);});
// anchors.topMargin = Qt.binding(function() { return 40 - (activePreview.shadow ? activePreview.shadow.paddingTop : 0);});
// anchors.bottomMargin = Qt.binding(function() { return 10 - (activePreview.shadow ? activePreview.shadow.paddingBottom : 0);});
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.