diff --git a/components/ToolBar.qml b/components/ToolBar.qml
index 095887e2fdf51147e9ff9c851fb073dd3fdb320a..f91b72fb9834cd2ac365037ea9b5f414614fa6cf 100644
--- a/components/ToolBar.qml
+++ b/components/ToolBar.qml
@@ -3,10 +3,9 @@ import "custom" as Components
 import "plugin"
 
 QStyleBackground {
-    id:styleitem
+    id:toolbar
     width:200
-    height:60
-
-    style: QStyleItem{elementType:"toolbar"}
+    height: styleitem.sizeFromContents(32, 32).height
+    style: QStyleItem{id:styleitem; elementType:"toolbar"}
 }
 
diff --git a/components/ToolButton.qml b/components/ToolButton.qml
index 658d07a5f22501145c672b54f2d7938e1212b1bb..7cabb3d70d0ec7d5dc02001aee55fc24d9c00761 100644
--- a/components/ToolButton.qml
+++ b/components/ToolButton.qml
@@ -5,8 +5,8 @@ import "plugin"
 Components.Button {
     id:button
 
-    width: 40
-    height: 40
+    height: 40; //styleitem.sizeFromContents(32, 32).height
+    width: 40; //styleitem.sizeFromContents(32, 32).width
 
     QStyleItem {elementType: "toolbutton"; id:styleitem  }
 
diff --git a/components/styleitem/qstyleitem.cpp b/components/styleitem/qstyleitem.cpp
index 69c031b00bf420cb81d1ee29b14bf64c69cbe7d1..b5589c9dada909445bc3f52a663ed7475b5d5f59 100644
--- a/components/styleitem/qstyleitem.cpp
+++ b/components/styleitem/qstyleitem.cpp
@@ -166,6 +166,11 @@ QSize QStyleItem::sizeFromContents(int width, int height)
         initStyleOption(&opt);
         opt.text = text();
         return qApp->style()->sizeFromContents(QStyle::CT_CheckBox, &opt, QSize(width,height), widget());
+    } else if (metric == QLatin1String("toolbutton")) {
+        QStyleOptionToolButton opt;
+        initStyleOption(&opt);
+        opt.icon = qApp->style()->standardIcon(QStyle::SP_ArrowBack);
+        return qApp->style()->sizeFromContents(QStyle::CT_ToolButton, &opt, QSize(width,height), widget());
     } else if (metric == QLatin1String("button")) {
         QStyleOptionButton opt;
         initStyleOption(&opt);
diff --git a/examples/Gallery.qml b/examples/Gallery.qml
index 3c73c6fafff22316683de7824d27424b091b7de1..97cfef5b707b78f1f2f1d9130c96ea5da952b48c 100644
--- a/examples/Gallery.qml
+++ b/examples/Gallery.qml
@@ -12,28 +12,27 @@ Rectangle {
         height:40
         Row {
             spacing: 2
-            ToolButton{iconSource: "images/folder_new.png"}
-            ToolButton{iconSource: "images/folder_new.png"}
-            ToolButton{iconSource: "images/folder_new.png"}
-            CheckBox{
-                id:enabledCheck
-                text:"Enabled"
-                checked:true
+            anchors.verticalCenter:parent.verticalCenter
+            ToolButton{
+                iconSource: "images/folder_new.png"
                 anchors.verticalCenter:parent.verticalCenter
             }
-            CheckBox{
-                id:animateCheck
-                text:"Animated"
-                checked:false
+            ToolButton{
+                iconSource: "images/folder_new.png"
                 anchors.verticalCenter:parent.verticalCenter
             }
-            CheckBox{
-                text:"South Tab"
-                id:toolBarPosition
-                checked:false
+            ToolButton{
+                iconSource: "images/folder_new.png"
                 anchors.verticalCenter:parent.verticalCenter
             }
         }
+        CheckBox{
+            id:enabledCheck
+            text:"Enabled"
+            checked:true
+            anchors.right:parent.right
+            anchors.verticalCenter:parent.verticalCenter
+        }
     }
 
     SystemPalette{id:syspal}
@@ -63,7 +62,7 @@ Rectangle {
     TabFrame {
         id:frame
         property int margins : styleitem.style == "mac" ? 16 : 0
-        position: toolBarPosition.checked ? "South" : "North"
+        position: tabPositionGroup.checkedButton == r2 ? "South" : "North"
         tabbar: TabBar{parent:frame}
         anchors.top:toolbar.bottom
         anchors.bottom:parent.bottom
@@ -128,7 +127,7 @@ Rectangle {
                         ProgressBar {
                             indeterminate: true
                         }
-                        Slider {id:slider; value:50; KeyNavigation.tab:c1}
+                        Slider {id:slider; value:50; KeyNavigation.tab:enabledCheck}
                         smooth:true
                     }
                     Column {
@@ -140,8 +139,21 @@ Rectangle {
                             Row {
                                 spacing: 6
                                 anchors.fill:parent
-                                CheckBox{id: c1; text:"Check 1"; KeyNavigation.tab:c2; checked:true}
-                                CheckBox{id: c2; text:"Check 2"; KeyNavigation.tab:r1}
+
+                                CheckBox{
+                                    id:frameCheckbox
+                                    text:"Text frame"
+                                    checked:true
+                                    KeyNavigation.tab:animateCheck;
+                                }
+                                CheckBox{
+                                    id:animateCheck
+                                    text:"Animated"
+
+                                    checked:false
+                                    KeyNavigation.tab:r1
+                                }
+
                             }
                             RotationAnimation on rotation {
                                 from:0; to:360;
@@ -153,10 +165,11 @@ Rectangle {
                         }
                         GroupBox{
                             id:group2
-                            text:"Radio Buttons"
+                            text:"Tab Position"
                             ButtonRow {
-                                RadioButton{id:r1; text:"Radio 1"; KeyNavigation.tab:r2; checked:true}
-                                RadioButton{id:r2; text:"Radio 2"; KeyNavigation.tab:area }
+                                id:tabPositionGroup
+                                RadioButton{id:r1; text:"North"; KeyNavigation.tab:r2; checked:true}
+                                RadioButton{id:r2; text:"South"; KeyNavigation.tab:area }
                             }
                             RotationAnimation on rotation {
                                 from:0; to:360;
@@ -169,6 +182,7 @@ Rectangle {
                         }
                         TextScrollArea {
                             id: area
+                            frame:frameCheckbox.checked
                             text: loremIpsum + loremIpsum
                             KeyNavigation.tab:button1
                         }