test theme.iconSizes -- works fine

This commit is contained in:
Sebastian Kügler 2013-02-19 17:48:13 +01:00
parent 26b5b98e0a
commit 9a3fb52e78
4 changed files with 17 additions and 13 deletions

View File

@ -38,10 +38,6 @@ PlasmaComponents.Page {
PlasmaExtras.Title { PlasmaExtras.Title {
width: parent.width width: parent.width
elide: Text.ElideRight elide: Text.ElideRight
text: "This is a <i>PlasmaComponent</i>"
}
PlasmaComponents.Label {
width: parent.width
text: "Icons" text: "Icons"
} }
Row { Row {
@ -90,7 +86,7 @@ PlasmaComponents.Page {
} }
Column { Column {
width: parent.width width: parent.width
spacing: _s spacing: _s/2
PlasmaComponents.Button { PlasmaComponents.Button {
text: "Button" text: "Button"
@ -104,6 +100,13 @@ PlasmaComponents.Page {
text: "RadioButton" text: "RadioButton"
//iconSource: "call-stop" //iconSource: "call-stop"
} }
PlasmaComponents.Label {
text: "iconSizes.small : " + theme.iconSizes.small +
", iconSizes.desktop: " + theme.iconSizes.desktop +
",<br />iconSizes.toolbar: " + theme.iconSizes.toolbar +
", iconSizes.dialog : " + theme.iconSizes.dialog
}
} }
} }

View File

@ -26,7 +26,7 @@ import org.kde.qtextracomponents 0.1 as QtExtras
// MousePage // MousePage
PlasmaComponents.Page { PlasmaComponents.Page {
id: melPage id: mousePage
anchors { anchors {
fill: parent fill: parent
margins: _s margins: _s

View File

@ -26,7 +26,7 @@ import org.kde.qtextracomponents 0.1 as QtExtras
// PlasmoidPage // PlasmoidPage
PlasmaComponents.Page { PlasmaComponents.Page {
id: pageTwo id: plasmoidPage
anchors { anchors {
fill: parent fill: parent
margins: _s margins: _s

View File

@ -28,8 +28,8 @@ Item {
width: 100 width: 100
height: 100 height: 100
property int _s: 12 property int _s: theme.iconSizes.small
property int _h: 32 property int _h: theme.iconSizes.desktop
PlasmaCore.DataSource { PlasmaCore.DataSource {
id: dataSource id: dataSource
@ -46,13 +46,13 @@ Item {
} }
height: _h height: _h
currentTab: melPage
PlasmaComponents.TabButton { tab: iconsPage; iconSource: "preferences-desktop-icons"} PlasmaComponents.TabButton { tab: iconsPage; iconSource: "preferences-desktop-icons"}
PlasmaComponents.TabButton { tab: plasmoidPage; iconSource: "plasma"} PlasmaComponents.TabButton { tab: plasmoidPage; iconSource: "plasma"}
PlasmaComponents.TabButton { tab: mousePage; iconSource: "preferences-desktop-mouse"} PlasmaComponents.TabButton { tab: mousePage; iconSource: "preferences-desktop-mouse"}
} }
PlasmaComponents.TabGroup { PlasmaComponents.TabGroup {
id: tabGroup
anchors { anchors {
left: parent.left left: parent.left
right: parent.right right: parent.right
@ -71,12 +71,13 @@ Item {
} }
MousePage { MousePage {
id: mousPage id: mousePage
} }
} }
Component.onCompleted: { Component.onCompleted: {
print("Components Test Applet loaded") print("Components Test Applet loaded");
//dataSource.engine = "org.kde.foobar" //dataSource.engine = "org.kde.foobar"
// tabGroup.currentTab = mousePage;
} }
} }