point QML Value Type
ein Wert mit den Attributen „x“ und „y“. Mehr...
| Import Statement: | import QtQml |
Ausführliche Beschreibung
Der Typ „ point “ bezieht sich auf einen Wert mit den Attributen „ x “ und „ y “.
Um einen „ point “-Wert zu erstellen, geben Sie ihn als „x,y“-Zeichenkette an:
CustomObject { myPointProperty: "0,20" }Oder verwenden Sie die Funktion ` Qt.point()`:
CustomObject { myPointProperty: Qt.point(0, 20) }Beachten Sie bei der Integration mit C++, dass jeder Wert vom Typ „ QPoint “ oder „ QPointF “, der von C++ an QML übergeben wird, automatisch in einen Wert vom Typ „ point “ konvertiert wird. Wenn ein Wert vom Typ „ point “ an C++ übergeben wird, wird er automatisch in einen Wert vom Typ „ QPointF “ konvertiert.
Eigenschaften vom Typ „ point “ sind standardmäßig vom Typ „ Qt.point(0, 0) “.
Siehe auch QML-Werttypen.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.