Bug 67445 - [Qt] number input not rendering spin buttons properly in RTL direction
Summary: [Qt] number input not rendering spin buttons properly in RTL direction
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: Qt
Depends on:
Blocks:
 
Reported: 2011-09-01 15:02 PDT by Jarred Nicholls
Modified: 2011-09-02 08:56 PDT (History)
1 user (show)

See Also:


Attachments
Mac (48.24 KB, image/png)
2011-09-01 15:03 PDT, Jarred Nicholls
no flags Details
Windows Classic (21.31 KB, image/png)
2011-09-01 15:03 PDT, Jarred Nicholls
no flags Details
Windows Vista/7 (25.04 KB, image/png)
2011-09-01 15:04 PDT, Jarred Nicholls
no flags Details
X11 windows style (29.49 KB, image/png)
2011-09-01 15:04 PDT, Jarred Nicholls
no flags Details
X11 Plastique (32.25 KB, image/png)
2011-09-01 15:04 PDT, Jarred Nicholls
no flags Details
Proposed Patch (15.28 KB, patch)
2011-09-01 15:05 PDT, Jarred Nicholls
no flags Details | Formatted Diff | Diff
Patch w/o pre-optimization/style issues (15.22 KB, application/octet-stream)
2011-09-01 19:08 PDT, Jarred Nicholls
no flags Details
Patch w/o pre-optimization/style issues (15.22 KB, patch)
2011-09-01 19:09 PDT, Jarred Nicholls
no flags Details | Formatted Diff | Diff
Proposed Patch (16.55 KB, patch)
2011-09-02 07:43 PDT, Jarred Nicholls
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jarred Nicholls 2011-09-01 15:02:59 PDT
Related to bug #65896 the Qt number input wouldn't render its input number in RTL properly.  Also, Plastique style doesn't look as intended.
Comment 1 Jarred Nicholls 2011-09-01 15:03:43 PDT
Created attachment 106038 [details]
Mac
Comment 2 Jarred Nicholls 2011-09-01 15:03:59 PDT
Created attachment 106040 [details]
Windows Classic
Comment 3 Jarred Nicholls 2011-09-01 15:04:16 PDT
Created attachment 106041 [details]
Windows Vista/7
Comment 4 Jarred Nicholls 2011-09-01 15:04:42 PDT
Created attachment 106042 [details]
X11 windows style
Comment 5 Jarred Nicholls 2011-09-01 15:04:57 PDT
Created attachment 106043 [details]
X11 Plastique
Comment 6 Jarred Nicholls 2011-09-01 15:05:25 PDT
Created attachment 106044 [details]
Proposed Patch
Comment 7 WebKit Review Bot 2011-09-01 15:08:58 PDT
Attachment 106044 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/platform/qt/fast/forms/input-a..." exit_code: 1

Source/WebCore/platform/qt/RenderThemeQt.cpp:1128:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
Source/WebCore/platform/qt/RenderThemeQt.cpp:1130:  Tests for true/false, null/non-null, and zero/non-zero should all be done without equality comparisons.  [readability/comparison_to_zero] [5]
Total errors found: 2 in 1 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 8 Jarred Nicholls 2011-09-01 15:11:05 PDT
This is a false positive, I intentionally chose to be explicit with the != 0 comparison for readability.  Happy to edit if anyone disagrees with this choice.
Comment 9 Jarred Nicholls 2011-09-01 16:41:44 PDT
(In reply to comment #8)
> This is a false positive, I intentionally chose to be explicit with the != 0 comparison for readability.  Happy to edit if anyone disagrees with this choice.

It's a pretty useless pre-optimization anyways, I'll just remove those checks I think.
Comment 10 Jarred Nicholls 2011-09-01 19:08:06 PDT
Created attachment 106081 [details]
Patch w/o pre-optimization/style issues
Comment 11 Jarred Nicholls 2011-09-01 19:09:05 PDT
Created attachment 106082 [details]
Patch w/o pre-optimization/style issues
Comment 12 Jarred Nicholls 2011-09-02 07:43:52 PDT
Created attachment 106131 [details]
Proposed Patch

I'm a donkey and didn't rebase some commits and my patch didn't include my changelog commit.
Comment 13 Andreas Kling 2011-09-02 07:54:48 PDT
Comment on attachment 106131 [details]
Proposed Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=106131&action=review

r=me

> Source/WebCore/platform/qt/RenderThemeQt.cpp:1121
> +    // QPlastiqueStyle looks best when the spin buttons are flush with the frame's edge.

You made me look up 'flush', you donkey. :)
Comment 14 WebKit Review Bot 2011-09-02 08:56:50 PDT
Comment on attachment 106131 [details]
Proposed Patch

Clearing flags on attachment: 106131

Committed r94419: <http://trac.webkit.org/changeset/94419>
Comment 15 WebKit Review Bot 2011-09-02 08:56:55 PDT
All reviewed patches have been landed.  Closing bug.