aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/material
Commit message (Collapse)AuthorAgeFilesLines
* Material: update palette on primary/accent color changeNikita Krupenko2016-04-201-0/+47
| | | | | | Task-number: QTBUG-52631 Change-Id: Ib1649f44cdbc14770b1759ef7f4d7ea92f148cc1 Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
* Material: corrected default, ToolButton and checkable controls fontsNikita Krupenko2016-03-161-4/+16
| | | | | | | | | According to Android sources, ToolButton has the same font, as other buttons and checkable controls use default (system) font. Also, set proper size for default font. Change-Id: I355ab57ef476918bab346538fefbd6c0209d2221 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Store explicit and resolved font separatelyJ-P Nurmi2016-03-151-23/+53
| | | | | | | Change-Id: I80bd45244077cd75f24c4ca1af6485f4c6a23b39 Task-number: QTBUG-50984 Task-number: QTBUG-51696 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Change style inheritance for popupsJ-P Nurmi2016-03-151-1/+3
| | | | | | | | | | | | | | | | | | The decision to make popups inherit theme & accent from its parent item was driven by ComboBox. However, in many cases it has an undesired side effect, so we've changed Popup to inherit its style attributes from the parent window instead, just like we did for fonts. The only exception to this is ComboBox, where the popup is an integral part of the control. This special case is now handled in the respective style implementation. A concrete example is that we can now specify dark theme by default for Material style ToolBar to get a better matching light text against the colorful background. In Gallery, this won't effect the options menu, which is a child of a ToolButton. The menu retains light theme along the rest of the application. Change-Id: Ibdc8fcf5b5fa258d853410a9b40368472424a8c6 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Test Material fontsJ-P Nurmi2016-03-111-0/+41
| | | | | | | Change-Id: Id80b0e851c82eecd6a8ae32f436b1a4bde0df40a Task-number: QTBUG-50984 Task-number: QTBUG-51696 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* tst_material/universal: use the appropriate styleJ-P Nurmi2016-03-113-0/+10
| | | | | | | | | | | | The main purpose of these tests were to test the attached property and its inheritance, so it didn't matter which particular style was active while running the tests. However, it simply looks better if they run with the appropriate style, and this also allows us to add style-specific tests (such as font attributes). Change-Id: I827f26e469bce3445ffe7e24d6299bcfb587d849 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* Refactor PopupJ-P Nurmi2016-01-221-1/+1
| | | | | | | | | | | Added relevant properties to make it almost like a Control: x, y, width, height, padding, background... This change makes popup use an internal item where the style/user-supplied contentItem and background are re-parented. This way we can provide a default style (background) for Popup. Change-Id: I3e7933562464c5c852e4ba4bc37d9ac25691c714 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Material: default primary to Indigo & accent to PinkJ-P Nurmi2016-01-201-2/+2
| | | | | | | | | | These colors are used as an example in the Google Material Design Guidelines, and as defaults in Android Studio app templates. Change-Id: I6236e4fd388817e05e22ec0b7aadedb3fae68fa1 Task-number: QTBUG-50330 Reviewed-by: Nikita Krupenko <krnekit@gmail.com> Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Restore Material::primaryJ-P Nurmi2016-01-201-23/+63
| | | | | | | | | | | | | The idea was that users would simply configure a different accent color for the toolbar, but the only way to do this is in code, which creates a hard dependency to the material style. A separate primary color makes it possible to configure both colors in :/qtlabscontrols.conf, which nicely avoids style specific dependencies. Change-Id: Ia5ad92b57f9aea32e16e9260117e8d32b3356556 Task-number: QTBUG-50329 Reviewed-by: Nikita Krupenko <krnekit@gmail.com> Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Fix style inheritanceJ-P Nurmi2016-01-151-0/+38
| | | | | | Change-Id: I46f4ea38d21f0f6a22bd247e02fe92a5b0d0d454 Task-number: QTBUG-50470 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Improve Material & Universal warningsJ-P Nurmi2016-01-141-5/+5
| | | | | | | | | | | | | | | | | | Before: QQuickMaterialStyle: unknown accent "foo" After: qrc:/main.qml:28:9: QML CheckBox: unknown Material.accent value: foo Furthermore, before invalid values in :/qtlabscontrols.conf were silently ignored. Now it gives a clear warning: :/qtlabscontrols.conf: unknown Material theme value: foo Change-Id: I0be4eb26ffe23643e282197dc76a091801ab2f4d Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Material: add support for user-defined accent colorsJ-P Nurmi2016-01-141-13/+56
| | | | | | Change-Id: Ia88cfcb307d03977c45bff32ad2b1d290d183a57 Task-number: QTBUG-50178 Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
* Fix style inheritance for popupsJ-P Nurmi2016-01-081-0/+28
| | | | | | Change-Id: I7bc36cb68e8d668fff2270e018de7eb1c71ccd20 Task-number: QTBUG-50347 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
* Add tst_materialJ-P Nurmi2015-11-303-0/+275
Tests that the inheritance of theme & accent works as expected. This is useful for avoiding regressions in the process of introducing a shared base class for QQuickMaterialStyle and QQuickUniversalStyle. Change-Id: Ib2eb5922323131fb531344b80dc928a0a07cca90 Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>