diff options
author | Richard Moe Gustavsen <richard.gustavsen@qt.io> | 2020-08-10 16:49:53 +0200 |
---|---|---|
committer | Richard Moe Gustavsen <richard.gustavsen@qt.io> | 2020-08-11 10:45:26 +0000 |
commit | c3c634e0f921047b221b858ef35769aeee245cc9 (patch) | |
tree | 42e35aa06f27f3bd168861eeaec5557070438bfb /src | |
parent | 74db7a9495fac965e2abd433879064fab3a306f5 (diff) |
Native style: increase text field minimum size
After testing on Big Sur, it becomes clear that
the minimum size (which is also the size of the
nine patch image) needs to be larger in order for
the text field to render correctly.
Change-Id: I74ede6415545f0ddee3fc2175772c1b07c2c3999
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/imports/nativestyle/qstyle/mac/qquickmacstyle_mac.mm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/imports/nativestyle/qstyle/mac/qquickmacstyle_mac.mm b/src/imports/nativestyle/qstyle/mac/qquickmacstyle_mac.mm index 6cf85f14..4648080e 100644 --- a/src/imports/nativestyle/qstyle/mac/qquickmacstyle_mac.mm +++ b/src/imports/nativestyle/qstyle/mac/qquickmacstyle_mac.mm @@ -6044,9 +6044,9 @@ QSize QMacStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt, cons case CT_LineEdit: if (const QStyleOptionFrame *f = qstyleoption_cast<const QStyleOptionFrame *>(opt)) { if (sz.isEmpty()) { - // Minimum size (10, 10) - sz.rwidth() += 2; - sz.rheight() += 6; + // Minimum size (with padding: 18x24) + sz.rwidth() = 10; + sz.rheight() = 20; } // From using pixelTool with XCode/NSTextTextField int leftPadding = 4; |