Initial import from the monolithic Qt.
[profile/ivi/qtdeclarative.git] / tests / auto / declarative / qmlvisual / webview / autosize / autosize.qml
1 import QtQuick 1.0
2 import QtWebKit 1.0
3
4 // The WebView size is determined by the width, height,
5 // preferredWidth, and preferredHeight properties.
6 Rectangle {
7     property string skip: "WebView tests not counting until resources allocated to WebView maintenance"
8     id: rect
9     color: "white"
10     width: 200
11     height: layout.height
12     Column {
13         id: layout
14         spacing: 2
15         WebView {
16             html: "No width defined."
17             Rectangle {                color: "#10000000"
18                 anchors.fill: parent
19             }
20         }
21         WebView {
22             width: rect.width
23             html: "The width is full."
24             Rectangle {
25                 color: "#10000000"
26                 anchors.fill: parent
27             }
28         }
29         WebView {
30             width: rect.width/2
31             html: "The width is half."
32             Rectangle {
33                 color: "#10000000"
34                 anchors.fill: parent
35             }
36         }
37         WebView {
38             preferredWidth: rect.width/2
39             html: "The preferredWidth is half."
40             Rectangle {
41                 color: "#10000000"
42                 anchors.fill: parent
43             }
44         }
45         WebView {
46             preferredWidth: rect.width/2
47             html: "The_preferredWidth_is_half."
48             Rectangle {
49                 color: "#10000000"
50                 anchors.fill: parent
51             }
52         }
53         WebView {
54             width: rect.width/2
55             html: "The_width_is_half."
56             Rectangle {
57                 color: "#10000000"
58                 anchors.fill: parent
59             }
60         }
61     }
62 }