diff options
author | Liang Qi <liang.qi@qt.io> | 2016-10-11 07:45:07 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2016-10-11 07:45:07 +0200 |
commit | 84e83e27dfba7215cb7a8f7210dab84cc400bb07 (patch) | |
tree | 2605b3e032982ed7048813612ec8d3816334cffa /src/quicktemplates2/qquicktabbar.cpp | |
parent | e3dac16b8da272c14c169227a8befe07e7852126 (diff) | |
parent | a3b706531b98c64137acaebf26756828cd43a2a0 (diff) |
Merge remote-tracking branch 'origin/5.8' into dev
Change-Id: I6a3a103e702dfa25c8ac1702be92faf3bb2b01d7
Diffstat (limited to 'src/quicktemplates2/qquicktabbar.cpp')
-rw-r--r-- | src/quicktemplates2/qquicktabbar.cpp | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/quicktemplates2/qquicktabbar.cpp b/src/quicktemplates2/qquicktabbar.cpp index 6d7a505a..ddcf7b12 100644 --- a/src/quicktemplates2/qquicktabbar.cpp +++ b/src/quicktemplates2/qquicktabbar.cpp @@ -60,13 +60,24 @@ QT_BEGIN_NAMESPACE \snippet qtquickcontrols2-tabbar.qml 1 - \section2 Flickable Tabs + \section2 Resizing Tabs By default, TabBar resizes its buttons to fit the width of the control. The available space is distributed equally to each button. The default resizing behavior can be overridden by setting an explicit width for the - buttons. If the total width of the buttons exceeds the available width - of the tab bar, it automatically becomes flickable. + buttons. + + The following example illustrates how to keep each tab button at their + implicit size instead of being resized to fit the tabbar: + + \borderedimage qtquickcontrols2-tabbar-explicit.png + + \snippet qtquickcontrols2-tabbar-explicit.qml 1 + + \section2 Flickable Tabs + + If the total width of the buttons exceeds the available width of the tab bar, + it automatically becomes flickable. \image qtquickcontrols2-tabbar-flickable.png |