RESOLVED FIXED 132164
Subpixel rendering: Inline text selection painting should not snap to integral CSS pixel position.
https://bugs.webkit.org/show_bug.cgi?id=132164
Summary Subpixel rendering: Inline text selection painting should not snap to integra...
zalan
Reported 2014-04-24 19:28:59 PDT
ssia. patch is coming up.
Attachments
Patch (8.93 KB, patch)
2014-04-24 19:40 PDT, zalan
no flags
Patch (8.89 KB, patch)
2014-04-30 17:25 PDT, zalan
no flags
zalan
Comment 1 2014-04-24 19:40:08 PDT
Darin Adler
Comment 2 2014-04-29 09:02:46 PDT
Comment on attachment 230131 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=230131&action=review I wish I understood the difference between “rounding” and “pixel snapping”. > Source/WebCore/rendering/EllipsisBox.cpp:140 > + FloatRect clipRect = pixelSnappedForPainting(x() + paintOffset.x(), top + paintOffset.y(), m_logicalWidth, h, renderer().document().deviceScaleFactor()); > + > context->clip(clipRect); Not sure we need a local variable for this. > Source/WebCore/rendering/InlineTextBox.cpp:760 > + LayoutUnit selHeight = std::max<LayoutUnit>(0, selectionBottom - selectionTop); Might be nice to use the word “selection” instead of the abbreviation “sel” here. > Source/WebCore/rendering/InlineTextBox.cpp:765 > + FloatRect clipRect = pixelSnappedForPainting(LayoutRect(LayoutPoint(localOrigin), LayoutSize(m_logicalWidth, selHeight)), deviceScaleFactor); > context->clip(clipRect); Not sure we need a local variable for this. > Source/WebCore/rendering/InlineTextBox.h:199 > INLINE_BOX_OBJECT_TYPE_CASTS(InlineTextBox, isInlineTextBox()) > - > -void alignSelectionRectToDevicePixels(FloatRect&); > - > } // namespace WebCore Should leave a blank line here.
zalan
Comment 3 2014-04-30 17:25:56 PDT
zalan
Comment 4 2014-04-30 17:26:13 PDT
Comment on attachment 230545 [details] Patch EWS testing.
zalan
Comment 5 2014-04-30 17:31:19 PDT
(In reply to comment #2) > (From update of attachment 230131 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=230131&action=review > > I wish I understood the difference between “rounding” and “pixel snapping”. Nothing, they both round. It is indeed confusing and I am planning to cleanup and fix all these different/legacy terms soon after I removed the compile time flag for subpixel layout.
WebKit Commit Bot
Comment 6 2014-05-01 06:32:14 PDT
Comment on attachment 230545 [details] Patch Clearing flags on attachment: 230545 Committed r168095: <http://trac.webkit.org/changeset/168095>
WebKit Commit Bot
Comment 7 2014-05-01 06:32:19 PDT
All reviewed patches have been landed. Closing bug.
mitz
Comment 8 2014-05-02 11:33:07 PDT
(In reply to comment #6) > (From update of attachment 230545 [details]) > Clearing flags on attachment: 230545 > > Committed r168095: <http://trac.webkit.org/changeset/168095> This caused bug 132474.
zalan
Comment 9 2014-05-02 11:36:44 PDT
(In reply to comment #8) > (In reply to comment #6) > > (From update of attachment 230545 [details] [details]) > > Clearing flags on attachment: 230545 > > > > Committed r168095: <http://trac.webkit.org/changeset/168095> > > This caused bug 132474. This patch made the inline text snapping errors visible for selections. It gets fixed when inline texts start setting its position properly on device pixels.
Note You need to log in before you can comment on or make changes to this bug.