aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Universal: fix Pane backgroundv5.6.0-beta1J-P Nurmi2015-12-141-1/+1
| | | | | Change-Id: I8187a968f4f11438c02374ffb2b6b8d33ecb8dc1 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Fix ScrollBar & ScrollIndicator for the new GalleryJ-P Nurmi2015-12-144-8/+34
| | | | | | | | | | | | | | | The Gallery example exposed some new bugs. We must let the scroll bar/indicator initialize its size before layouting it, or else it will be posioned on the edge and eventually grows outside of the flickable it is attached to. Therefore, we must monitor the size changes of the scroll bar/indicator the same way we're monitoring the size changes of the attached flickable. Furthermore, while debugging the issue, I noticed that QQuickScrollBar/Indicator were unnecessarily monitoring all geometry changes. Monitoring only size changes is enough. Change-Id: I2581dba29bb4606642ba470dce85534632d7752e Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Make QQuickStyleSelector case-insensitiveJ-P Nurmi2015-12-141-3/+3
| | | | | | | | | | | | | | | | | This is especially nice for qtlabscontrols.conf: [Controls] Style=material vs. [Controls] Style=Material Previously, only the first syntax worked. Change-Id: Ib4a47dca002acb5c0227f3dcfea7251296f8386e Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Remove QQuickStyleSelector::instance()J-P Nurmi2015-12-145-47/+38
| | | | | | | | | | | It was a bad idea to share the same instance, because non-thread-safe instance() ends up being called from multiple threads. Let the style plugins create their own instances instead, QQuickStyleSelector ctor is not that heavy and there's no such shared state as originally was anticipated. Change-Id: Ie23091c6dd50f5d7abbab3b996da4471054da89a Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Popup: rename show()/hide() to open()/close()J-P Nurmi2015-12-148-31/+31
| | | | | | | | | QML popups have traditionally used more explicit open() and close(). Renaming them to show() and hide() at this stage doesn't seem to have any real advantages. Change-Id: I1e7c8c4817c67e62cef965525e00f5bf125a7d76 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Material style: read theme, accent & primary from qtlabscontrols.confJ-P Nurmi2015-12-142-4/+37
| | | | | Change-Id: Ie55978ae9c76789cf7796752ceefd183c063662b Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Universal style: read theme & accent from qtlabscontrols.confJ-P Nurmi2015-12-142-3/+35
| | | | | Change-Id: Ie41bf8a3b375835a07229eff49e6d10e3ff79992 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Read preferred style from qtlabscontrols.confJ-P Nurmi2015-12-141-0/+7
| | | | | Change-Id: I3aeed5c8316a099eed5ea8df25711193ee3c7d90 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Add QQuickStyle::settings()J-P Nurmi2015-12-142-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Loads ":/qtlabscontrols.conf" from resources. The next step is to make it possible to specify the preferred theme and accent in qtlabscontrols.conf. Different values can be specified for each style, which will take effect when running the app using the respective style. These are the preferred or default values, which can be overridden in code. [Controls] Style=material [Universal] Theme=Dark Accent=Red [Material] Theme=Light Accent=Brown The reason for using our own qtlabscontrols.conf file instead of re-using qt.conf is that qt.conf is strictly purposed for specifying the standard Qt paths for deployment setups. If qt.conf missing paths for QLibraryInfo, Qt fails to load the platform plugin: This application failed to start because it could not find or load the Qt platform plugin "windows|cocoa|xcb". Change-Id: I8da7f0859f004db8adf585b830bce4aa8e7713a9 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Docs: move "Differences between Qt Quick Controls" on its own pageJ-P Nurmi2015-12-142-246/+284
| | | | | Change-Id: Ib00f19f793a4d65b6bd1ba109e92cb310e2d3491 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* tst_activeFocusOnTab: remove unnecessary layouts dependencyJ-P Nurmi2015-12-121-3/+2
| | | | | Change-Id: I6e25c7f391bf02c8e15b078bb0d85de8ec7a2f20 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Universal ComboBox: visualize key & mouse focus differentlyJ-P Nurmi2015-12-121-1/+1
| | | | | Change-Id: I90bc393e63027a4485228a73f571a513cfe5fcc4 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Universal: focus rectangleJ-P Nurmi2015-12-1210-0/+156
| | | | | Change-Id: I74005dcce5f1f41e9455b882f313952f88c364f9 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Add QQuickControl::focusReasonJ-P Nurmi2015-12-1210-2/+194
| | | | | | | | | This allows the Universal style ApplicationWindow to visualize key/tab focus with a focus rectangle, but hide the focus rectangle when the focus moves around for other reasons (mouse, active window, popups...) Change-Id: I5c5b43d7c4c051679e34b806ee43cd80180d7ab8 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* AppWindow docs: fix \L -> \lJ-P Nurmi2015-12-121-1/+1
| | | | | Change-Id: I89fadddbceb77fc20af102f20fed45db17019c14 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Cleanup duplicate ApplicationWindow::activeFocusControl docsJ-P Nurmi2015-12-121-8/+0
| | | | | Change-Id: I939e3788eaf535a126d674dec861313b6f536b83 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Add missing TextArea::pressAndHold() docsJ-P Nurmi2015-12-121-0/+8
| | | | | Change-Id: I09c42985a116feaacc9896a8f0ccaca5fd4c57f9 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* testbench: fix TextArea placeholder textJ-P Nurmi2015-12-121-1/+1
| | | | | Change-Id: I36b036e9bb7f5f0dd66ffae205a90f3b11a3ee27 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Fix QQuickComboBox::focusOutEvent()J-P Nurmi2015-12-121-1/+1
| | | | | | | Call the immediate base class, QQuickControl, instead of QQuickItem. Change-Id: If48283375f010c30a5860903097f3693cbc2b097 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Pane: don't let presses leak throughJ-P Nurmi2015-12-102-0/+30
| | | | | | | | | | | A regression introduced by 38c47c0. Pane is the base type for Frame, GroupBox, and ToolBar. These type of containers shouldn't let presses through. For example, an application that has a listview scrolled below a toolbar, list items under the toolbar should not react when interacting with the toolbar. Change-Id: I7668452fe2d6d89372f032220fa5623b50d334bb Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Add ApplicationWindow::activeFocusControlJ-P Nurmi2015-12-105-48/+371
| | | | | | | | | This makes it possible for ApplicationWindow to visualize key focus navigation with a single focus rectangle that follows the currently active focus control. Change-Id: Ief92bcdc64891b7baa3503216137665a8badcd17 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Register also "unstyled" controls to the Qt.labs.controls namespaceJ-P Nurmi2015-12-101-0/+8
| | | | | | | | | The documentation is full of references to Control and other "unstyled" control. This change makes it possible to use them without importing the templates. Change-Id: I4026d4c212139568ab9229f956b115c328d69b72 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Use TabButtonFont and GroupBoxTitleFont from QPlatformThemeLiang Qi2015-12-106-17/+17
| | | | | | | | * QQuickGroupBox: GroupBoxTitleFont * QQuickTabButton: TabButtonFont Change-Id: Ib2e58a95c49353536231cc93d28dba075629c59f Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Move ApplicationHelper to visualtestutil.h and rename itMitch Curtis2015-12-103-27/+31
| | | | | | | This class is useful for other auto tests, like Popup's. Change-Id: Ie193c07e5b53b67493fceba9a1c32798db2f4e34 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Docs: ApplicationWindowJ-P Nurmi2015-12-102-5/+60
| | | | | Change-Id: Ic565ef245985a5dbbd69cd2fd6473748c66b4f54 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Introduce PaneJ-P Nurmi2015-12-0922-135/+768
| | | | | | | | Provides a background color that matches with the application style and theme. Change-Id: I5e7ea4fededaaf46687a2ea0391f43dbf55e3b42 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Rename Panel to PopupJ-P Nurmi2015-12-0922-246/+242
| | | | | | | | | Popup is a more descriptive name. Furthermore, this name change opens the door for another type called Pane. It gives the appropriate background color for the current style & theme. Change-Id: Idb91d37e807f62e870b50f0b656e84ee2d43a9fb Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* StackView: fix property initializationJ-P Nurmi2015-12-092-2/+24
| | | | | | | | | | | When pushing a url or component, ensure that properties passed to push() are initialized during the incubation. When pushing an item, the properties are set the same way than before, at stack element initialization phase. Change-Id: I19ca10baae43857e1349486059a3317d68d3b2d4 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com> Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Remove Control::layoutDirectionJ-P Nurmi2015-12-098-129/+54
| | | | | | | | Calculate QQuickControl::isMirrored() from LayoutMirroring.enabled (QQuickItemPrivate::isMirrored()) and QLocale::textDirection(). Change-Id: I0e391d27df732734031f3e94d9828a1a2cfa7474 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Docs: Material styleJ-P Nurmi2015-12-094-0/+182
| | | | | Change-Id: Id7a3bc48bb97136d11679c64f424d9c1d81e476e Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* GroupBox: add an example of a checkable groupboxJ-P Nurmi2015-12-096-7/+74
| | | | | | | Adjust the size calculation so that the example works smooth. Change-Id: Iaf25107b0cfaa3ceef0caeba120d1bd74c9bc854 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Round expected event coordinates in Button's events testMitch Curtis2015-12-091-6/+6
| | | | | | | | The test expects 20.5 but gets 21 when run with a 4K monitor on Ubuntu 15.10. Change-Id: I1a71ee8614dcb86a595fd2832f89e0db617f677e Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Print out actual and expected events in Button's events testMitch Curtis2015-12-091-6/+16
| | | | | | | Qt Quick Test only prints out [object Object], which isn't very useful. Change-Id: I01663ea97abae93a5f27e8328a75fb5b3f93129e Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Fix some issues with GifRecorderMitch Curtis2015-12-093-6/+11
| | | | | | | | | | | | - Try to ensure that the correct region is recorded. Sometimes, on specific machines, I've seen the region being offset by a vertical distance of 24 pixels (the size of the title bar). - Try to ensure that the window has time to render before we start recording with byzanz. Change-Id: Ia4c354ba436ed21af0e83303a98faa616be63325 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Add Control::localeJ-P Nurmi2015-12-0712-107/+83
| | | | | | Change-Id: I6c6647de6d286a92b35bca09a45e82cd3343a623 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com> Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Implement Universal style Menu & MenuItemJ-P Nurmi2015-12-073-0/+172
| | | | | Change-Id: I1dd04a9424c69d6824d00e49a9ea5ae2b1a97342 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Update .gitignoreJ-P Nurmi2015-12-051-0/+1
| | | | | Change-Id: Ia724edb5ab73bd7369141902a82fd15aecc0a87b Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Docs: Universal styleJ-P Nurmi2015-12-045-0/+195
| | | | | Change-Id: Ifd5e3d0d25384310b358c5e3bd0d82e8cdef7b53 Reviewed-by: Topi Reiniƶ <topi.reinio@theqtcompany.com>
* Adapt default style to latest designsMitch Curtis2015-12-045-7/+7
| | | | | | | Press fill colours were changed. Change-Id: Ic15039576c4e26aeef9933dab6fb0a0689550ab2 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* StackView: fix crash when attempting to transition null itemsJ-P Nurmi2015-12-042-6/+19
| | | | | | | | Don't attempt to kick off view transitions for stack elements that have failed to load. Change-Id: I6e42785a30abc815d14a07e7d16aad5bde66391d Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Add ComboBoxJ-P Nurmi2015-12-0444-0/+2251
| | | | | Change-Id: I4cfc2367db92786097a1ce66bd4b5a2f71322a2e Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Material Button: fix font inheritanceJ-P Nurmi2015-12-031-0/+1
| | | | | Change-Id: I30235a5a43ec6cfd8107bf0f6433e22c20df4a7d Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* QQuickApplicationWindow: add font propertyLiang Qi2015-12-035-0/+215
| | | | | Change-Id: I6f946994f789704aa2efa94aaea0129d0d73d005 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Implement QQuickMenuItem::defaultFont()J-P Nurmi2015-12-032-0/+8
| | | | | Change-Id: I93205a226cd2a66236f9dd98e0b9039363900d75 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* ItemDelegate: implement highlighted stateJ-P Nurmi2015-12-033-3/+13
| | | | | Change-Id: I6c4cdd97fcdaa86c2bdc5a8f465c2d9b6eddcf13 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Promote Button::highlighted to AbstractButtonJ-P Nurmi2015-12-037-63/+42
| | | | | Change-Id: I0e17a6c25dfd89fdb547720e9a626c2ec9d7765a Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Adapt MenuItem to designsMitch Curtis2015-12-032-4/+6
| | | | | | | Decrease the padding and swap the label/indicator order. Change-Id: I0ee2528d3c3111024fe1a6e52acc0da1a0d30990 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Make Qt::Key_Escape close MenuMitch Curtis2015-12-032-0/+7
| | | | | Change-Id: Ib7d74b556378f7ec5ac3156c92a02d6834bff82e Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* QQuickStyleSelector: don't inherit QObjectJ-P Nurmi2015-12-026-28/+20
| | | | | | | | Fixes the "QObject: Cannot create children for a parent that is in a different thread." -warnings. Change-Id: I94ed34c6c4c7a6b6507e91e74a354630b0ad6d04 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Add QQuickStyleJ-P Nurmi2015-12-0212-315/+387
| | | | | | | | | Now that we have a good place for it, we can share a common base class for QQuickMaterialStyle and QQuickUniversalStyle. QQuickStyle implements the inheritance pattern for attached styles, in one place. Change-Id: I459d98f96ce7c6de1ce7ef716e859f459278d8ad Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>