d020be15729035594a07797f066c4ef7e86d3820
[mdictionary] / src / mdictionary / qml / TranslationView.qml
1 import Qt 4.7
2 import QtWebKit 1.0
3
4 Rectangle {
5     id: rectangle1
6     width: 500
7     height: 500
8
9
10
11     WebView {
12         id: web_view1
13         anchors.fill: parent
14         url: "http://kokos.pl/"
15
16         onDoubleClick: {
17             console.log(clickX,clickY);
18             heuristicZoom(clickX,clickY,2)
19         }
20        /* onZoomTo: {
21             console.log(zoom);
22             scale=zoom;x=width/2-centerX;
23             y=height/2-centerY
24        }
25        */
26     }
27
28     Button {
29         id: button1
30         textInButton: "test"
31         width: 200;
32         height: 30;
33         x: 41
34         y: 28
35         onClicked: web_view1.scale=web_view1.scale*1.05;
36     }
37
38     Button {
39         id: button2
40         textInButton: "test2"
41         width: 200;
42         height: 30;
43         x: 41
44         y: 68
45         onClicked: web_view1.scale=web_view1.scale*.95;
46     }
47 }