diff options
Diffstat (limited to 'DOCS/client_api_examples/qml/main.qml')
-rw-r--r-- | DOCS/client_api_examples/qml/main.qml | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/DOCS/client_api_examples/qml/main.qml b/DOCS/client_api_examples/qml/main.qml new file mode 100644 index 0000000000..d921e2a86c --- /dev/null +++ b/DOCS/client_api_examples/qml/main.qml @@ -0,0 +1,39 @@ +import QtQuick 2.0 +import QtQuick.Controls 1.0 + +import mpvtest 1.0 + +Item { + width: 1280 + height: 720 + + MpvObject { + id: renderer + anchors.fill: parent + + MouseArea { + anchors.fill: parent + onClicked: renderer.loadfile("../../../test.mkv") + } + } + + Rectangle { + id: labelFrame + anchors.margins: -50 + radius: 5 + color: "white" + border.color: "black" + opacity: 0.8 + anchors.fill: label + } + + Text { + id: label + anchors.bottom: renderer.bottom + anchors.left: renderer.left + anchors.right: renderer.right + anchors.margins: 100 + wrapMode: Text.WordWrap + text: "QtQuick and mpv are both rendering stuff." + } +} |