aboutsummaryrefslogtreecommitdiffstats
path: root/examples/declarative/window/window_rc.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples/declarative/window/window_rc.py')
-rw-r--r--examples/declarative/window/window_rc.py328
1 files changed, 328 insertions, 0 deletions
diff --git a/examples/declarative/window/window_rc.py b/examples/declarative/window/window_rc.py
new file mode 100644
index 000000000..71a65fc44
--- /dev/null
+++ b/examples/declarative/window/window_rc.py
@@ -0,0 +1,328 @@
+# Resource object code (Python 3)
+# Created by: object code
+# Created by: The Resource Compiler for Qt version 6.5.0
+# WARNING! All changes made in this file will be lost!
+
+from PySide6 import QtCore
+
+qt_resource_data = b"\
+\x00\x00\x04\xe8\
+/\
+/ Copyright (C) \
+2021 The Qt Comp\
+any Ltd.\x0a// SPDX\
+-License-Identif\
+ier: LicenseRef-\
+Qt-Commercial OR\
+ BSD-3-Clause\x0a\x0ai\
+mport QtQuick\x0aim\
+port QtQuick.Con\
+trols\x0a\x0aColumn {\x0a\
+ id: root\x0a \
+ spacing: 8\x0a\x0a \
+ Label {\x0a \
+ text: \x22Total nu\
+mber of screens:\
+ \x22 + screenInfo.\
+count\x0a fo\
+nt.bold: true\x0a \
+ }\x0a\x0a Flow {\x0a\
+ spacing:\
+ 12\x0a widt\
+h: parent.width\x0a\
+\x0a Repeate\
+r {\x0a \
+id: screenInfo\x0a \
+ model\
+: (Qt.applicatio\
+n as Application\
+).screens\x0a \
+ Label {\x0a \
+ re\
+quired property \
+string name\x0a \
+ requ\
+ired property in\
+t virtualX\x0a \
+ requi\
+red property int\
+ virtualY\x0a \
+ requir\
+ed property var \
+modelData // avo\
+id shadowing Lab\
+el.width and hei\
+ght\x0a\x0a \
+ lineHeight:\
+ 1.5\x0a \
+ text: name \
++ \x22\x5cn\x22 + virtual\
+X + \x22, \x22 + virtu\
+alY + \x22 \x22 + mode\
+lData.width + \x22x\
+\x22 + modelData.he\
+ight\x0a \
+ }\x0a }\x0a \
+ }\x0a\x0a Componen\
+t.onCompleted: {\
+\x0a var scr\
+eens = (Qt.appli\
+cation as Applic\
+ation).screens;\x0a\
+ for (var\
+ i = 0; i < scre\
+ens.length; ++i)\
+\x0a con\
+sole.log(\x22screen\
+ \x22 + screens[i].\
+name + \x22 has geo\
+metry \x22 +\x0a \
+ \
+ screens[i].vir\
+tualX + \x22, \x22 + s\
+creens[i].virtua\
+lY + \x22 \x22 +\x0a \
+ \
+ screens[i].wi\
+dth + \x22x\x22 + scre\
+ens[i].height)\x0a \
+ }\x0a}\x0a\
+\x00\x00\x04\x8e\
+\x00\
+\x00\x16\x10x\x9c\xcdXKo\xdb8\x10\xbe\xfbW\xb0\
+\xdaK\xb2\x85\xdf\xed\xc5E\xb0H\x5ctS E\x9b\
+8h\x0a,\xf6\xa0Hc\x8b\x1bZ4H*v6\
+\x9b\xff\xbe#\x91\xd4\xc3\xa2d\xa7q\xb7\xcb\x8b%r\
+\xf8q\xe6\x9b\x878\xee\xf7\xc9\x94\xaf\x1e\x04]D\x8a\
+\x1cM\x8f\xc9h0\x1a\x92\xeb\x08\xc8\xa5\xc2\x95\xe5\xca\
+\x8f\x1f\xc8\x85\x0a{\x9d~\x9f\xcc\xbe\xbc\xff\xd6\xbd\xa0\
+\x01\xc4\x12\xba\x1fC\x88\x15\x9dS\x10\x13b\xe6\xae`\
+\xde\xbdT]\xdc\xb6\x04\x11P\x9f\x91\xcfW\xe4l\xf6\
+\xbe;\xeeN\x99\x9fH\xe8t\xe8r\xc5\x85B\xf0\xcb\
+\x84\x06w[\xaf\xbd)\x8f\x95\xe0Lv:\x97\xea\xf3\
+\xed_\x10(\xf2\xd8!8h8!\x82s\x95\xbd\xac\
+\x04_\x81P\x0fD\x00\x1e\x11\xc2\xdcO\x98\x9a\xad\xfc\
+\x80\xc6\x8b\x09\x19\x0e\xaaB\xb3\x07\xa9`\xf9\xc5g\xa0\
+\x14\x90\x95\xfe\x9dlM?\x92\xa7Nu\xdb\xbd/H\
+\xa0\xd5\xb9\xa1q\xc8\xd7\x13\xa2\x7f\x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e4\x98\xc3\xf7\xb2M\xa9k\x81\x02<\x01\xc4\xc7\
+\xd8yZF\x8a\xce\xdf\x99\xce\xdf\xed.\xbd\xee\xe6O\
+<\x91p\x8a\x0dq\xcb\xa1\x8d\xe6\xa5\xa3\xe5\xdb\xa9\xfd\
+p\x82\xae\x83A0\x1eB\x9b\x1e\x8dwO\xab\x84\xd0\
+\x91aBP8\xef\x14VV\xf1U.\x89\xcf\x8dr\
+{\xbb\xa5`\xf6\xd9\xd7x\xac\x8d\xb0\xa1\x8a\x94\xbeH\
+i\x8d\x5c\xf0\xf2LS\x16\x0f\xdf\x0e\xda\x08o\xb8\xa9\
+\xcf\x1b*u\x8b\x9a\xc7N\xa4t\x1c\xea\xea\x9d\x0e`\
+\xb2\xde\x88?\xe7\xa0\xbd\xdb\x99g\x06\x17\x83y\x11[\
+\xe9\xcb\xcf\x08-\xef[c\x1c\x8c[\xc3\xa0\x96w\x8c\
+K8j\xfa(6Wk\xb9b\xbe\x8cl\xbd\x9ee\
+o%\xd2x|M\x97\xc0\x13\x9b\x05\x95\x7f3K\x7f\
+\xc1(\x91\x809\xe3\xa9\xf3/I\x8e\xfe,\
+\x00\x00\x03\xfa\
+/\
+/ Copyright (C) \
+2021 The Qt Comp\
+any Ltd.\x0a// SPDX\
+-License-Identif\
+ier: LicenseRef-\
+Qt-Commercial OR\
+ BSD-3-Clause\x0a\x0ai\
+mport QtQuick\x0aim\
+port shared\x0a\x0a//!\
+ [splash-propert\
+ies]\x0aWindow {\x0a \
+ id: splash\x0a \
+ color: \x22transpa\
+rent\x22\x0a title:\
+ \x22Splash Window\x22\
+\x0a modality: Q\
+t.ApplicationMod\
+al\x0a flags: Qt\
+.SplashScreen\x0a \
+ property int t\
+imeoutInterval: \
+2000\x0a signal \
+timeout\x0a//! [spl\
+ash-properties]\x0a\
+//! [screen-prop\
+erties]\x0a x: (\
+Screen.width - s\
+plashImage.width\
+) / 2\x0a y: (Sc\
+reen.height - sp\
+lashImage.height\
+) / 2\x0a//! [scree\
+n-properties]\x0a \
+ width: splashI\
+mage.width\x0a h\
+eight: splashIma\
+ge.height\x0a\x0a I\
+mage {\x0a i\
+d: splashImage\x0a \
+ source: I\
+mages.qtLogo\x0a \
+ MouseArea {\
+\x0a anc\
+hors.fill: paren\
+t\x0a on\
+Clicked: Qt.quit\
+()\x0a }\x0a \
+ }\x0a //! [time\
+r]\x0a Timer {\x0a \
+ interval:\
+ splash.timeoutI\
+nterval; running\
+: true; repeat: \
+false\x0a on\
+Triggered: {\x0a \
+ splash.\
+visible = false\x0a\
+ spla\
+sh.timeout()\x0a \
+ }\x0a }\x0a \
+ //! [timer]\x0a \
+ Component.onCom\
+pleted: visible \
+= true\x0a}\x0a\
+\x00\x00\x02\xff\
+\x00\
+\x00\x0adx\x9c\xadV\xdfo\xda0\x10~\xcf_q\
+\xcb\x13l#\x01\xd6MS\xfa0mT[+\xa1\xb5\
+\x85J\xeb\xb4\xee\xc1$\x07XM\xec\xc8q(h\xe2\
+\x7f\x9f\x9d_8\x90\x12\xaa-O\xb9\xf3w\xf7}\xf1\
+\x9d}q]\x18\xf1x#\xe8b)\xa13\xea\xc2\xb0\
+?\x1c\xc0\xdd\x12\xe1V\xaa\x95(&l\x03c\x198\
+\x96\xeb\xc2\xf4\xe6\xe2\xbe7\xa6>\xb2\x04{W\x012\
+I\xe7\x14\x85\x07\x85o\x82\xf3\xde\xad\xec\xa9\xb0\x08\x85\
+OI\x08\xd7\x13\xf82\xbd\xe8\xbd\xeb\x8dB\x92&h\
+Y4\x8a\xb9\x90*\xf9mJ\xfd\xc7=\xd3\x19q&\
+\x05\x0f\x13\xcb\xba\x92\x18\xc1\x1f\x0b\xd4C\x03\x0f\x04\xe7\
+23\x9eh \x97\x1e\x9c\xf5\xfb\x99\xb9D-\xdc\x83\
+X\xf0\x18\x85\xdc|\x134pT\xd2\x90\xfaT^f\
+\x8b\xf0\x06\x06\x1f\xac\x0c=O\x99/)g\xc0\x05U\
+\xe2\x89~\xbf\xe3S)([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97\xean\x88\xfb7\xf9\
+\x01\xae\xd4@+\xd4\x0b}m\xb5j\xcfC2\x09\x13\
+\x1d`\x12?ODV\x84\x86d\x16\x22\xac\xa8\x90)\
+\xd1{\x95<J\x1e\x9f\xc0\x97\xe1>\x97\x09~45\
+\xd4>\xe8\xb2\xb5\xc1\xb8\xda<= ){\xb1\xa2\x02\
+\x7f\xafE\xbc\x05CE\xb1\xf0\xf3\x08\xaf1\x8f\x9f\xe7\
+\xd1\xff\x00N\xd3\xe4.x\x8c\xa5\xbc\xd8\x1dC\x84\xb1\
+\xa8\xd7\x8e\x96\xbf\x98\xdb\xf0_T\xc5\x07?\x0b\x87\xe2\
+\x0e1\x95\xc6\x92\xb46g\x9e\x13>\xe8\xab\xa3!\xd0\
+\x97\x84-B4\xc3'\xa5so*\xa9Y\xc8\xd5\xff\
+\x9b-0\xa8\x8f\x9eb\xa24\xdf\x0c\x83~\x0d[\xce\
+\x9c,foHm\xad\xad\xf5\x17o|\x1ar\
+"
+
+qt_resource_name = b"\
+\x00\x06\
+\x07\xe0Kg\
+\x00w\
+\x00i\x00n\x00d\x00o\x00w\
+\x00\x0e\
+\x0ei\x17\x5c\
+\x00A\
+\x00l\x00l\x00S\x00c\x00r\x00e\x00e\x00n\x00s\x00.\x00q\x00m\x00l\
+\x00\x0a\
+\x0bi\x98\xbc\
+\x00w\
+\x00i\x00n\x00d\x00o\x00w\x00.\x00q\x00m\x00l\
+\x00\x0a\
+\x08\x90\x1a|\
+\x00S\
+\x00p\x00l\x00a\x00s\x00h\x00.\x00q\x00m\x00l\
+\x00\x11\
+\x02YG\x1c\
+\x00C\
+\x00u\x00r\x00r\x00e\x00n\x00t\x00S\x00c\x00r\x00e\x00e\x00n\x00.\x00q\x00m\x00l\
+\
+"
+
+qt_resource_struct = b"\
+\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
+\x00\x00\x00\x00\x00\x00\x00\x00\
+\x00\x00\x00\x00\x00\x02\x00\x00\x00\x04\x00\x00\x00\x02\
+\x00\x00\x00\x00\x00\x00\x00\x00\
+\x00\x00\x00h\x00\x01\x00\x00\x00\x01\x00\x00\x0d|\
+\x00\x00\x01\x82Y\xad^\x0f\
+\x00\x00\x00N\x00\x00\x00\x00\x00\x01\x00\x00\x09~\
+\x00\x00\x01\x82Y\xad^\x0f\
+\x00\x00\x004\x00\x01\x00\x00\x00\x01\x00\x00\x04\xec\
+\x00\x00\x01\x82Y\xad^\x0f\
+\x00\x00\x00\x12\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
+\x00\x00\x01\x82Y\xad^\x0f\
+"
+
+def qInitResources():
+ QtCore.qRegisterResourceData(0x03, qt_resource_struct, qt_resource_name, qt_resource_data)
+
+def qCleanupResources():
+ QtCore.qUnregisterResourceData(0x03, qt_resource_struct, qt_resource_name, qt_resource_data)
+
+qInitResources()