aboutsummaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@theqtcompany.com>2016-02-15 14:01:57 +0100
committerJ-P Nurmi <jpnurmi@theqtcompany.com>2016-02-22 11:05:01 +0000
commit581a160a5679ec9fc433a0ff40a294ffe8f86da0 (patch)
treeae1b1cfbd8b009d40a32670010c7ddec88fbca41 /examples
parent004f9dca05215659b5a201c18648580898c2445e (diff)
Material TabBar: highlight at the top when the bar is at the bottom
Even though the Material Design Guidelines recommend against placing tabs at the bottom, we cannot prevent our users from doing that. It is the standard convention on iOS, for instance. Coincidentally, the official Google Translate app for iOS uses Material design, has tabs at the bottom, and has tab highlight at the top of the bar. A screen- shot is attached to QTBUG-50043. Change-Id: Id7c9398b8b4bc9d270f0d908b1a68d68f49d32f0 Task-number: QTBUG-50043 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/controls/gallery/pages/TabBarPage.qml10
1 files changed, 3 insertions, 7 deletions
diff --git a/examples/controls/gallery/pages/TabBarPage.qml b/examples/controls/gallery/pages/TabBarPage.qml
index ba170f2c..7e465ec3 100644
--- a/examples/controls/gallery/pages/TabBarPage.qml
+++ b/examples/controls/gallery/pages/TabBarPage.qml
@@ -41,14 +41,12 @@
import QtQuick 2.6
import Qt.labs.controls 1.0
-Pane {
- id: pane
- padding: 0
+Page {
+ id: page
SwipeView {
id: swipeView
anchors.fill: parent
- anchors.bottomMargin: tabBar.height
currentIndex: tabBar.currentIndex
Repeater {
@@ -79,10 +77,8 @@ Pane {
}
}
- TabBar {
+ footer: TabBar {
id: tabBar
- width: parent.width
- anchors.bottom: parent.bottom
currentIndex: swipeView.currentIndex
TabButton {