@@ -1,76 +1,76 | |||||
1 | /**************************************************************************** |
|
1 | /**************************************************************************** | |
2 | ** |
|
2 | ** | |
3 | ** Copyright (C) 2012 Digia Plc |
|
3 | ** Copyright (C) 2012 Digia Plc | |
4 | ** All rights reserved. |
|
4 | ** All rights reserved. | |
5 | ** For any questions to Digia, please use contact form at http://qt.digia.com |
|
5 | ** For any questions to Digia, please use contact form at http://qt.digia.com | |
6 | ** |
|
6 | ** | |
7 | ** This file is part of the Qt Commercial Charts Add-on. |
|
7 | ** This file is part of the Qt Commercial Charts Add-on. | |
8 | ** |
|
8 | ** | |
9 | ** $QT_BEGIN_LICENSE$ |
|
9 | ** $QT_BEGIN_LICENSE$ | |
10 | ** Licensees holding valid Qt Commercial licenses may use this file in |
|
10 | ** Licensees holding valid Qt Commercial licenses may use this file in | |
11 | ** accordance with the Qt Commercial License Agreement provided with the |
|
11 | ** accordance with the Qt Commercial License Agreement provided with the | |
12 | ** Software or, alternatively, in accordance with the terms contained in |
|
12 | ** Software or, alternatively, in accordance with the terms contained in | |
13 | ** a written agreement between you and Digia. |
|
13 | ** a written agreement between you and Digia. | |
14 | ** |
|
14 | ** | |
15 | ** If you have questions regarding the use of this file, please use |
|
15 | ** If you have questions regarding the use of this file, please use | |
16 | ** contact form at http://qt.digia.com |
|
16 | ** contact form at http://qt.digia.com | |
17 | ** $QT_END_LICENSE$ |
|
17 | ** $QT_END_LICENSE$ | |
18 | ** |
|
18 | ** | |
19 | ****************************************************************************/ |
|
19 | ****************************************************************************/ | |
20 |
|
20 | |||
21 | import QtQuick 1.0 |
|
21 | import QtQuick 1.0 | |
22 |
|
22 | |||
23 | Row { |
|
23 | Row { | |
24 | anchors.fill: parent |
|
24 | anchors.fill: parent | |
25 | spacing: 5 |
|
25 | spacing: 5 | |
26 | property variant chartLegend |
|
26 | property variant chartLegend | |
27 |
|
27 | |||
28 | Flow { |
|
28 | Flow { | |
29 | spacing: 5 |
|
29 | spacing: 5 | |
30 | flow: Flow.TopToBottom |
|
30 | flow: Flow.TopToBottom | |
31 |
|
31 | |||
32 | Button { |
|
32 | Button { | |
33 | text: "legend visible" |
|
33 | text: "legend visible" | |
34 | onClicked: chartLegend.visible = !chartLegend.visible; |
|
34 | onClicked: chartLegend.visible = !chartLegend.visible; | |
35 | } |
|
35 | } | |
36 | Button { |
|
36 | Button { | |
37 | text: "legend bckgrd visible" |
|
37 | text: "legend bckgrd visible" | |
38 | onClicked: chartLegend.backgroundVisible = !chartLegend.backgroundVisible; |
|
38 | onClicked: chartLegend.backgroundVisible = !chartLegend.backgroundVisible; | |
39 | } |
|
39 | } | |
40 | Button { |
|
40 | Button { | |
41 | text: "legend color" |
|
41 | text: "legend color" | |
42 | onClicked: chartLegend.color = main.nextColor(); |
|
42 | onClicked: chartLegend.color = main.nextColor(); | |
43 | } |
|
43 | } | |
44 | Button { |
|
44 | Button { | |
45 | text: "legend border color" |
|
45 | text: "legend border color" | |
46 | onClicked: chartLegend.borderColor = main.nextColor(); |
|
46 | onClicked: chartLegend.borderColor = main.nextColor(); | |
47 | } |
|
47 | } | |
48 | Button { |
|
48 | Button { | |
49 | text: "legend label color" |
|
49 | text: "legend label color" | |
50 | onClicked: chartLegend.labelColor = main.nextColor(); |
|
50 | onClicked: chartLegend.labelColor = main.nextColor(); | |
51 | } |
|
51 | } | |
52 | Button { |
|
52 | Button { | |
53 | text: "legend top" |
|
53 | text: "legend top" | |
54 |
onClicked: chartLegend.alignment |
|
54 | onClicked: chartLegend.alignment = Qt.AlignTop; | |
55 | } |
|
55 | } | |
56 | Button { |
|
56 | Button { | |
57 | text: "legend bottom" |
|
57 | text: "legend bottom" | |
58 |
onClicked: chartLegend.alignment |
|
58 | onClicked: chartLegend.alignment = Qt.AlignBottom; | |
59 | } |
|
59 | } | |
60 | Button { |
|
60 | Button { | |
61 | text: "legend left" |
|
61 | text: "legend left" | |
62 |
onClicked: chartLegend.alignment |
|
62 | onClicked: chartLegend.alignment = Qt.AlignLeft; | |
63 | } |
|
63 | } | |
64 | Button { |
|
64 | Button { | |
65 | text: "legend right" |
|
65 | text: "legend right" | |
66 |
onClicked: chartLegend.alignment |
|
66 | onClicked: chartLegend.alignment = Qt.AlignRight; | |
67 | } |
|
67 | } | |
68 | } |
|
68 | } | |
69 |
|
69 | |||
70 | FontEditor { |
|
70 | FontEditor { | |
71 | fontDescription: "legend" |
|
71 | fontDescription: "legend" | |
72 | function editedFont() { |
|
72 | function editedFont() { | |
73 | return chartLegend.font; |
|
73 | return chartLegend.font; | |
74 | } |
|
74 | } | |
75 | } |
|
75 | } | |
76 | } |
|
76 | } |
General Comments 0
You need to be logged in to leave comments.
Login now