Material: don't set all caps for Button text
The guidelines have changed since Material 2, and they now recommend to use sentence case: https://m3.material.io/components/buttons/guidelines Amendsf47f8d6931
. Change-Id: I055f4acc9c1e594b5c87818bcce5abd774b01d04 Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io> (cherry picked from commit4a7d15c74b
) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
106901c032
commit
9c555b2947
|
@ -47,7 +47,6 @@ void QQuickMaterialTheme::initialize(QQuickTheme *theme)
|
|||
|
||||
// https://material.io/guidelines/components/buttons.html#buttons-style
|
||||
buttonFont.setPixelSize(dense ? 13 : 14);
|
||||
buttonFont.setCapitalization(QFont::AllUppercase);
|
||||
buttonFont.setWeight(QFont::Medium);
|
||||
theme->setFont(QQuickTheme::Button, buttonFont);
|
||||
theme->setFont(QQuickTheme::TabBar, buttonFont);
|
||||
|
|
|
@ -636,15 +636,15 @@ TestCase {
|
|||
return [
|
||||
{tag: "Button:pixelSize", type: "Button", attribute: "pixelSize", value: 14, window: 20, pane: 10},
|
||||
{tag: "Button:weight", type: "Button", attribute: "weight", value: Font.Medium, window: Font.Black, pane: Font.Bold},
|
||||
{tag: "Button:capitalization", type: "Button", attribute: "capitalization", value: Font.AllUppercase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
{tag: "Button:capitalization", type: "Button", attribute: "capitalization", value: Font.MixedCase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
|
||||
{tag: "TabButton:pixelSize", type: "TabButton", attribute: "pixelSize", value: 14, window: 20, pane: 10},
|
||||
{tag: "TabButton:weight", type: "TabButton", attribute: "weight", value: Font.Medium, window: Font.Black, pane: Font.Bold},
|
||||
{tag: "TabButton:capitalization", type: "TabButton", attribute: "capitalization", value: Font.AllUppercase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
{tag: "TabButton:capitalization", type: "TabButton", attribute: "capitalization", value: Font.MixedCase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
|
||||
{tag: "ToolButton:pixelSize", type: "ToolButton", attribute: "pixelSize", value: 14, window: 20, pane: 10},
|
||||
{tag: "ToolButton:weight", type: "ToolButton", attribute: "weight", value: Font.Medium, window: Font.Black, pane: Font.Bold},
|
||||
{tag: "ToolButton:capitalization", type: "ToolButton", attribute: "capitalization", value: Font.AllUppercase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
{tag: "ToolButton:capitalization", type: "ToolButton", attribute: "capitalization", value: Font.MixedCase, window: Font.Capitalize, pane: Font.AllLowercase},
|
||||
|
||||
{tag: "ItemDelegate:pixelSize", type: "ItemDelegate", attribute: "pixelSize", value: 14, window: 20, pane: 10},
|
||||
{tag: "ItemDelegate:weight", type: "ItemDelegate", attribute: "weight", value: Font.Medium, window: Font.Black, pane: Font.Bold},
|
||||
|
|
Loading…
Reference in New Issue