Bug 86319 - Unify RenderMathMLSquareRoot.cpp and RenderMathMLRoot.cpp
Summary: Unify RenderMathMLSquareRoot.cpp and RenderMathMLRoot.cpp
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: MathML (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Dave Barton
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-13 08:48 PDT by Dave Barton
Modified: 2012-05-14 11:56 PDT (History)
7 users (show)

See Also:


Attachments
Patch (43.69 KB, patch)
2012-05-13 08:55 PDT, Dave Barton
no flags Details | Formatted Diff | Diff
Patch (43.65 KB, patch)
2012-05-13 23:05 PDT, Dave Barton
no flags Details | Formatted Diff | Diff
Patch for landing (43.77 KB, patch)
2012-05-14 10:31 PDT, Levi Weintraub
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dave Barton 2012-05-13 08:48:50 PDT
Unify RenderMathMLSquareRoot.cpp and RenderMathMLRoot.cpp
Comment 1 Dave Barton 2012-05-13 08:55:50 PDT
Created attachment 141606 [details]
Patch
Comment 2 Darin Adler 2012-05-13 16:12:30 PDT
Comment on attachment 141606 [details]
Patch

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

> Source/WebCore/ChangeLog:14
> +        (WebCore):

Please remove bogus lines like this from the ChangeLog, or you could fix the prepare-ChangeLog script to not emit those.

> Source/WebCore/ChangeLog:19
> +        (WebCore):

Ditto.

> Source/WebCore/ChangeLog:22
> +        (WebCore):

Ditto.

> Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp:91
> +    int frontWidth = static_cast<int>(roundf(gFrontWidthEms * style()->fontSize()));

It seems strange to call static_cast<int>(roundf()) since lroundf does the same thing without a cast.

> Source/WebCore/rendering/mathml/RenderMathMLRoot.cpp:111
> +        int partDipHeight = static_cast<int>(roundf((1 - gRootRadicalDipLeftPointYPos) * baseHeight));

Ditto.

> Source/WebCore/rendering/mathml/RenderMathMLRoot.h:41
> +    virtual void computePreferredLogicalWidths() OVERRIDE;

Why protected rather than private?
Comment 3 Dave Barton 2012-05-13 23:05:42 PDT
Created attachment 141644 [details]
Patch
Comment 4 Dave Barton 2012-05-13 23:09:30 PDT
Thanks for the review+, Darin. I made just the changes you suggested, but my committer paperwork hasn't gone through yet, so I still need a cq+ from someone. Thanks!
Comment 5 Levi Weintraub 2012-05-14 10:02:17 PDT
(In reply to comment #4)
> Thanks for the review+, Darin. I made just the changes you suggested, but my committer paperwork hasn't gone through yet, so I still need a cq+ from someone. Thanks!

I've put you into the commit queue. This was one of the bits of MathML rendering that bugged me the most. Thanks for cleaning it up!
Comment 6 WebKit Review Bot 2012-05-14 10:04:37 PDT
Comment on attachment 141644 [details]
Patch

Rejecting attachment 141644 [details] from commit-queue.

Failed to run "['/mnt/git/webkit-commit-queue/Tools/Scripts/webkit-patch', '--status-host=queues.webkit.org', '-..." exit_code: 1

ERROR: /mnt/git/webkit-commit-queue/LayoutTests/ChangeLog neither lists a valid reviewer nor contains the string "Unreviewed" or "Rubber stamp" (case insensitive).

Full output: http://queues.webkit.org/results/12694256
Comment 7 Levi Weintraub 2012-05-14 10:05:39 PDT
(In reply to comment #6)
> (From update of attachment 141644 [details])
> Rejecting attachment 141644 [details] from commit-queue.
> 
> Failed to run "['/mnt/git/webkit-commit-queue/Tools/Scripts/webkit-patch', '--status-host=queues.webkit.org', '-..." exit_code: 1
> 
> ERROR: /mnt/git/webkit-commit-queue/LayoutTests/ChangeLog neither lists a valid reviewer nor contains the string "Unreviewed" or "Rubber stamp" (case insensitive).
> 
> Full output: http://queues.webkit.org/results/12694256

The ChangeLog needs to be updated with Darin as the reviewer. I can take care of that for you if you'd like.
Comment 8 Dave Barton 2012-05-14 10:12:22 PDT
> The ChangeLog needs to be updated with Darin as the reviewer. I can take care of that for you if you'd like.

That would be wonderful. I meant to do that before creating the new patch and forgot (I am still new and learning). Thanks very much for the commit and the help!!
Comment 9 Levi Weintraub 2012-05-14 10:31:54 PDT
Created attachment 141750 [details]
Patch for landing
Comment 10 WebKit Review Bot 2012-05-14 11:56:50 PDT
Comment on attachment 141750 [details]
Patch for landing

Clearing flags on attachment: 141750

Committed r116975: <http://trac.webkit.org/changeset/116975>
Comment 11 WebKit Review Bot 2012-05-14 11:56:55 PDT
All reviewed patches have been landed.  Closing bug.