aboutsummaryrefslogtreecommitdiffstats
path: root/tests/systemtests/declarative/qsgimage/ImageNG.qml
diff options
context:
space:
mode:
authorYann Bodson <yann.bodson@nokia.com>2011-07-05 13:06:54 +1000
committerQt by Nokia <qt-info@nokia.com>2011-07-20 03:07:06 +0200
commita8925e668aca0e1d2b90308c8286e5bb68f9ee42 (patch)
tree36b30e9aae31ac2afb001b0e581343ed892812fa /tests/systemtests/declarative/qsgimage/ImageNG.qml
parent86896ff9b2e0387b0b265f927e7cc3f7b40f498b (diff)
Improvements to Image element
- add Image.Pad as a fillMode - add horizontal and vertical alignment properties Task-number: QTBUG-18291 Change-Id: Iaaf3b2d02c47ad01d2c8b49d146f1a9401b2558d Reviewed-on: http://codereview.qt.nokia.com/1468 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Martin Jones <martin.jones@nokia.com> Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
Diffstat (limited to 'tests/systemtests/declarative/qsgimage/ImageNG.qml')
-rw-r--r--tests/systemtests/declarative/qsgimage/ImageNG.qml19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/systemtests/declarative/qsgimage/ImageNG.qml b/tests/systemtests/declarative/qsgimage/ImageNG.qml
new file mode 100644
index 0000000000..4a10910fcf
--- /dev/null
+++ b/tests/systemtests/declarative/qsgimage/ImageNG.qml
@@ -0,0 +1,19 @@
+import QtQuick 2.0
+
+Image {
+ property bool explicitSize: true
+ property alias label: lb.text
+
+ width: explicitSize ? 200 : undefined; height: explicitSize ? 150 : undefined
+ smooth: true
+
+ Rectangle {
+ border.color: "red"; color: "transparent"
+ anchors.fill: parent
+ }
+
+ Text {
+ id: lb
+ anchors.top: parent.bottom; anchors.horizontalCenter: parent.horizontalCenter; anchors.topMargin: 4
+ }
+}