fixes for drawing
This commit is contained in:
+24
-3
@@ -1,9 +1,30 @@
|
||||
pragma ComponentBehavior: Bound
|
||||
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
import ZShell.Internal
|
||||
|
||||
StrokeCanvas {
|
||||
Item {
|
||||
id: root
|
||||
|
||||
penColor: "white"
|
||||
penWidth: 4
|
||||
readonly property alias content: contentLoader.item
|
||||
readonly property PersistentProperties drawingState: PersistentProperties {
|
||||
property color penColor: "white"
|
||||
property int penWidth: 4
|
||||
|
||||
reloadableId: "drawingState"
|
||||
}
|
||||
required property PersistentProperties visibilities
|
||||
|
||||
Loader {
|
||||
id: contentLoader
|
||||
|
||||
active: root.visibilities.isDrawing
|
||||
anchors.fill: parent
|
||||
|
||||
sourceComponent: StrokeCanvas {
|
||||
penColor: root.drawingState.penColor
|
||||
penWidth: root.drawingState.penWidth
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user