quickshell-web/modules_old/Quickshell/QsWindow.json
2024-09-28 02:35:19 +03:00

114 lines
4.7 KiB
JSON

{
"name": "QsWindow",
"module": "Quickshell",
"type": "class",
"super": {
"type": "local",
"module": "Quickshell",
"name": "Reloadable"
},
"description": "Base class of Quickshell windows",
"details": "Base class of Quickshell windows\n### Attached properties\n`QSWindow` can be used as an attached object of anything that subclasses {{< qmltypelink type=\"qt\" module=\"qml.QtQuick\" name=\"Item\" mtype=\"\" mname=\"\" >}}.\nIt provides the following properties\n- `window` - the `QSWindow` object.\n- `contentItem` - the `contentItem` property of the window.\n",
"flags": ["uncreatable"],
"properties": {
"width": {
"type": {
"type": "qt",
"module": "qml",
"name": "int"
},
"details": null
},
"height": {
"type": {
"type": "qt",
"module": "qml",
"name": "int"
},
"details": null
},
"data": {
"type": {
"type": "qt",
"module": "qml",
"name": "list",
"of": {
"type": "qt",
"module": "qml.QtQml",
"name": "QtObject"
}
},
"details": null,
"flags": ["default", "readonly"]
},
"backingWindowVisible": {
"type": {
"type": "qt",
"module": "qml",
"name": "bool"
},
"details": "If the window is currently shown. You should generally prefer [prop||visible](#visible).\n\nThis property is useful for ensuring windows spawn in a specific order, and you should\nnot use it in place of [prop||visible](#visible).\n",
"flags": ["readonly"]
},
"contentItem": {
"type": {
"type": "qt",
"module": "qml.QtQuick",
"name": "Item"
},
"details": null,
"flags": ["readonly"]
},
"screen": {
"type": {
"type": "local",
"module": "Quickshell",
"name": "ShellScreen"
},
"details": "The screen that the window currently occupies.\n\nThis may be modified to move the window to the given screen.\n"
},
"mask": {
"type": {
"type": "local",
"module": "Quickshell",
"name": "Region"
},
"details": "The clickthrough mask. Defaults to null.\n\nIf non null then the clickable areas of the window will be determined by the provided region.\n\n```qml\nShellWindow {\n // The mask region is set to `rect`, meaning only `rect` is clickable.\n // All other clicks pass through the window to ones behind it.\n mask: Region { item: rect }\n\n Rectangle {\n id: rect\n\n anchors.centerIn: parent\n width: 100\n height: 100\n }\n}\n```\n\nIf the provided region's intersection mode is `Combine` (the default),\nthen the region will be used as is. Otherwise it will be applied on top of the window region.\n\nFor example, setting the intersection mode to `Xor` will invert the mask and make everything in\nthe mask region not clickable and pass through clicks inside it through the window.\n\n```qml\nShellWindow {\n // The mask region is set to `rect`, but the intersection mode is set to `Xor`.\n // This inverts the mask causing all clicks inside `rect` to be passed to the window\n // behind this one.\n mask: Region { item: rect; intersection: Intersection.Xor }\n\n Rectangle {\n id: rect\n\n anchors.centerIn: parent\n width: 100\n height: 100\n }\n}\n```\n"
},
"color": {
"type": {
"type": "qt",
"module": "qml",
"name": "color"
},
"details": "The background color of the window. Defaults to white.\n\n{{< callout type=\"warning\" >}}\n This seems to behave weirdly when using transparent colors on some systems.\nUsing a colored content item over a transparent window is the recommended way to work around this:\n```qml\nProxyWindow {\n color: \"transparent\"\n Rectangle {\n anchors.fill: parent\n color: \"#20ffffff\"\n\n // your content here\n }\n}\n```\n\n{{< /callout >}}"
},
"visible": {
"type": {
"type": "qt",
"module": "qml",
"name": "bool"
},
"details": "If the window should be shown or hidden. Defaults to true.\n"
},
"windowTransform": {
"type": {
"type": "qt",
"module": "qml.QtQml",
"name": "QtObject"
},
"details": "Opaque property that will receive an update when factors that affect the window's position\nand transform changed.\n\nThis property is intended to be used to force a binding update,\nalong with map[To|From]Item (which is not reactive).\n",
"flags": ["readonly"]
}
},
"functions": [],
"signals": {
"windowConnected": {
"name": "windowConnected",
"details": null,
"params": []
}
},
"variants": {}
}