|
|
Created:
4 years, 3 months ago by lunalu1 Modified:
4 years, 3 months ago CC:
blink-reviews, blink-reviews-layout_chromium.org, chromium-reviews, eae+blinkwatch, jchaffraix+rendering, leviw+renderwatch, pdr+renderingwatchlist_chromium.org, szager+layoutwatch_chromium.org, zoltan1 Target Ref:
refs/pending/heads/master Project:
chromium Visibility:
Public. |
DescriptionRefactoring out the code in LayoutTreeAsText::writeLayoutObject.
BUG=481588
Committed: https://crrev.com/ecf51ddf5158be270b3ad65d613c9498d644fc6b
Cr-Commit-Position: refs/heads/master@{#419072}
Patch Set 1 : Initial commit #
Total comments: 8
Patch Set 2 : Codereview update #
Total comments: 2
Patch Set 3 : Rename helper #
Total comments: 21
Patch Set 4 : Codereview update #
Total comments: 6
Patch Set 5 : LayoutUnit #Patch Set 6 : Revert to Original Impl #
Total comments: 2
Patch Set 7 : Rebase #Messages
Total messages: 139 (88 generated)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
The CQ bit was unchecked by lunalu@chromium.org
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: linux_chromium_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presub...)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
benjhayden@chromium.org changed reviewers: + benjhayden@chromium.org
https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBox.cpp:4876: if (cb && cb->isTableCell()) Should this be moved to a virtual method so that you don't need to check isTableCell and then call toLayoutTableCell? https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: Would be better not to just dump 0, 0 as the x and y here. Would it be possible to go ahead and use linesBox.x() and linesBox.y() in this CL so as not to break TracedLayoutObject? I realize that might mean updating a bunch of layout tests, but perhaps layout-dev has a feasible way to do that? https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.cpp:3206: if (isLayoutView()) { Should this be moved to a virtual method so that LayoutView can override it? https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp (left): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp:40: tracedValue->setDouble("absX", object.absoluteBoundingBoxRect().x()); Can you restore absX and absY? Sorry, I realize I accidentally asked you to delete them, my bad. :-)
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
On 2016/08/29 20:45:28, benjhayden wrote: > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > third_party/WebKit/Source/core/layout/LayoutBox.cpp:4876: if (cb && > cb->isTableCell()) > Should this be moved to a virtual method so that you don't need to check > isTableCell and then call toLayoutTableCell? > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: Would be > better not to just dump 0, 0 as the x and y here. > Would it be possible to go ahead and use linesBox.x() and linesBox.y() in this > CL so as not to break TracedLayoutObject? I realize that might mean updating a > bunch of layout tests, but perhaps layout-dev has a feasible way to do that? > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > third_party/WebKit/Source/core/layout/LayoutObject.cpp:3206: if (isLayoutView()) > { > Should this be moved to a virtual method so that LayoutView can override it? > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > File third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp (left): > > https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp:40: > tracedValue->setDouble("absX", object.absoluteBoundingBoxRect().x()); > Can you restore absX and absY? Sorry, I realize I accidentally asked you to > delete them, my bad. :-) Hi Ben, I made some changes based on your comments. I am not so confident with some of the changes, could you please take a look? I didn't make the change in LayoutObject.cpp:3206 as you requested because I wasn't so clear about what you were suggesting. Could you please clarify on that. Thank you for your time, Luna
https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBox.cpp:4876: if (cb && cb->isTableCell()) On 2016/08/29 20:45:27, benjhayden wrote: > Should this be moved to a virtual method so that you don't need to check > isTableCell and then call toLayoutTableCell? I moved this part to a virtual method but I don't think I did it right. Could you please be more clear about how to make this part virtual? Thanks https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: Would be better not to just dump 0, 0 as the x and y here. On 2016/08/29 20:45:27, benjhayden wrote: > Would it be possible to go ahead and use linesBox.x() and linesBox.y() in this > CL so as not to break TracedLayoutObject? I realize that might mean updating a > bunch of layout tests, but perhaps layout-dev has a feasible way to do that? I will use linesBox.x() and linesBox.y() for now, and figure out which layout tests to be updated later. https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.cpp:3206: if (isLayoutView()) { On 2016/08/29 20:45:27, benjhayden wrote: > Should this be moved to a virtual method so that LayoutView can override it? Could you please clarify on this? So to create a virtual method that essentially do nothing, but LayoutView override it to update the width and height? Can a LayoutObject be both a LayoutText/LayoutInline/LayoutTableCell/LayoutBox and a LayoutView? https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp (left): https://codereview.chromium.org/2280153002/diff/120001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp:40: tracedValue->setDouble("absX", object.absoluteBoundingBoxRect().x()); On 2016/08/29 20:45:27, benjhayden wrote: > Can you restore absX and absY? Sorry, I realize I accidentally asked you to > delete them, my bad. :-) Done.
Hi Ben, When you have time, do you mind to reply to my comments? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Mon, Aug 29, 2016 at 4:45 PM, <benjhayden@chromium.org> wrote: > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutBox.cpp > File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutBox.cpp#newcode4876 > third_party/WebKit/Source/core/layout/LayoutBox.cpp:4876: if (cb && > cb->isTableCell()) > Should this be moved to a virtual method so that you don't need to check > isTableCell and then call toLayoutTableCell? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutInline.cpp > File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutInline.cpp#newcode1372 > third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: > Would be better not to just dump 0, 0 as the x and y here. > Would it be possible to go ahead and use linesBox.x() and linesBox.y() > in this CL so as not to break TracedLayoutObject? I realize that might > mean updating a bunch of layout tests, but perhaps layout-dev has a > feasible way to do that? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutObject.cpp > File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutObject.cpp#newcode3206 > third_party/WebKit/Source/core/layout/LayoutObject.cpp:3206: if > (isLayoutView()) { > Should this be moved to a virtual method so that LayoutView can override > it? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp > File third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp > (left): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp#oldcode40 > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp:40: > tracedValue->setDouble("absX", object.absoluteBoundingBoxRect().x()); > Can you restore absX and absY? Sorry, I realize I accidentally asked you > to delete them, my bad. :-) > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
Hi Ben, When you have time, do you mind to reply to my comments? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Mon, Aug 29, 2016 at 4:45 PM, <benjhayden@chromium.org> wrote: > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutBox.cpp > File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutBox.cpp#newcode4876 > third_party/WebKit/Source/core/layout/LayoutBox.cpp:4876: if (cb && > cb->isTableCell()) > Should this be moved to a virtual method so that you don't need to check > isTableCell and then call toLayoutTableCell? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutInline.cpp > File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutInline.cpp#newcode1372 > third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: > Would be better not to just dump 0, 0 as the x and y here. > Would it be possible to go ahead and use linesBox.x() and linesBox.y() > in this CL so as not to break TracedLayoutObject? I realize that might > mean updating a bunch of layout tests, but perhaps layout-dev has a > feasible way to do that? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutObject.cpp > File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/LayoutObject.cpp#newcode3206 > third_party/WebKit/Source/core/layout/LayoutObject.cpp:3206: if > (isLayoutView()) { > Should this be moved to a virtual method so that LayoutView can override > it? > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp > File third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp > (left): > > https://codereview.chromium.org/2280153002/diff/120001/ > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp#oldcode40 > third_party/WebKit/Source/core/layout/TracedLayoutObject.cpp:40: > tracedValue->setDouble("absX", object.absoluteBoundingBoxRect().x()); > Can you restore absX and absY? Sorry, I realize I accidentally asked you > to delete them, my bad. :-) > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_compile_dbg_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_comp...)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Hi Ben, Thank you for the feedback. I have updated the CL based on your comments. Please take another look. Regards, Luna
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_...)
Patchset #1 (id:1) has been deleted
Patchset #1 (id:20001) has been deleted
Patchset #1 (id:40001) has been deleted
Patchset #3 (id:100001) has been deleted
Patchset #1 (id:60001) has been deleted
Patchset #3 (id:140001) has been deleted
Patchset #3 (id:160001) has been deleted
Patchset #1 (id:80001) has been deleted
This is probably my last comment. I'll try to see if I can get somebody on layout-dev to take a look. https://codereview.chromium.org/2280153002/diff/180001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBlock.h (right): https://codereview.chromium.org/2280153002/diff/180001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBlock.h:431: virtual void adjustForTableCells(LayoutRect&) const {} Can you rename this to adjustChildDebugRect()? I appreciate keeping the variable name to make review easier, but as a method name it's unclear.
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Renamed the helper as suggested. Please take another look. Thanks https://codereview.chromium.org/2280153002/diff/180001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBlock.h (right): https://codereview.chromium.org/2280153002/diff/180001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBlock.h:431: virtual void adjustForTableCells(LayoutRect&) const {} On 2016/09/08 20:18:07, benjhayden wrote: > Can you rename this to adjustChildDebugRect()? > I appreciate keeping the variable name to make review easier, but as a method > name it's unclear. Done.
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_...)
benjhayden@chromium.org changed reviewers: + skobes@chromium.org
Luna, Steve has agreed to review this. Thanks for reviewing this, Steve!
lgtm, please wait for skobes
https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBlock.h (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBlock.h:429: // FIXME: Temporary in order ot ensure compatibility with existing layout test Current Blink style is to use "TODO(username)" instead of FIXME. Also, typo: "ot" -> "to" https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBox.cpp:4856: LayoutRect r = frameRect(); We generally avoid single-letter abbreviations in variable names. Can you call this "rect" (and "block" for the containing block below)? Same in the other files that do this. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: Would be better not to just dump 0, 0 as the x and y here. It looks like this FIXME has been addressed? https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1375: IntRect linesBox = enclosingIntRect(linesBoundingBox()); Why aren't we just returning linesBoundingBox()? This will lose subpixel precision. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1376: LayoutRect r = LayoutRect(IntRect(IntRect(linesBox.x(), linesBox.y(), linesBox.width(), linesBox.height()))); Remove redundant cast to IntRect. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.cpp:82: #include "platform/scroll/ScrollableArea.h" Do you need this? There are no other changes in the file. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.h:1369: // Fixed implementation for LayoutText, LayoutInline, LayoutTableCell and The comment should describe what the method does, e.g. "Returns a rect corresponding to this LayoutObject's bounds for use in debugging output". You don't need to list the classes that override it. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.h:1373: // This method should never be reached as it's overriden by subclasses. Why not just make it pure virtual? Then the compiler will catch any missing overrides. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutTableCell.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutTableCell.cpp:1050: LayoutRect r = LayoutRect(location().x(), location().y() + intrinsicPaddingBefore(), size().width(), size().height() - intrinsicPaddingBefore() - intrinsicPaddingAfter()); Wrap this line at the commas for readability. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutText.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutText.cpp:1771: IntRect linesBox = enclosingIntRect(linesBoundingBox()); Same question re. rounding to ints.
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Thank you for reviewing my CL. I have made the change based on your comments (I am not so sure if I did it correctly upon change in LayoutText.cpp). Please take another look. Regards, Luna https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBlock.h (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBlock.h:429: // FIXME: Temporary in order ot ensure compatibility with existing layout test On 2016/09/09 20:27:41, skobes wrote: > Current Blink style is to use "TODO(username)" instead of FIXME. > > Also, typo: "ot" -> "to" Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutBox.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutBox.cpp:4856: LayoutRect r = frameRect(); On 2016/09/09 20:27:41, skobes wrote: > We generally avoid single-letter abbreviations in variable names. Can you call > this "rect" (and "block" for the containing block below)? > > Same in the other files that do this. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1372: // FIXME: Would be better not to just dump 0, 0 as the x and y here. On 2016/09/09 20:27:41, skobes wrote: > It looks like this FIXME has been addressed? Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1375: IntRect linesBox = enclosingIntRect(linesBoundingBox()); On 2016/09/09 20:27:41, skobes wrote: > Why aren't we just returning linesBoundingBox()? This will lose subpixel > precision. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1376: LayoutRect r = LayoutRect(IntRect(IntRect(linesBox.x(), linesBox.y(), linesBox.width(), linesBox.height()))); On 2016/09/09 20:27:41, skobes wrote: > Remove redundant cast to IntRect. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.cpp:82: #include "platform/scroll/ScrollableArea.h" On 2016/09/09 20:27:41, skobes wrote: > Do you need this? There are no other changes in the file. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.h:1369: // Fixed implementation for LayoutText, LayoutInline, LayoutTableCell and On 2016/09/09 20:27:41, skobes wrote: > The comment should describe what the method does, e.g. "Returns a rect > corresponding to this LayoutObject's bounds for use in debugging output". You > don't need to list the classes that override it. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.h:1373: // This method should never be reached as it's overriden by subclasses. On 2016/09/09 20:27:41, skobes wrote: > Why not just make it pure virtual? Then the compiler will catch any missing > overrides. Then I have to write an overriding function for subclasses: LayoutSVGGradientStop and LayoutSVGImage https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutTableCell.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutTableCell.cpp:1050: LayoutRect r = LayoutRect(location().x(), location().y() + intrinsicPaddingBefore(), size().width(), size().height() - intrinsicPaddingBefore() - intrinsicPaddingAfter()); On 2016/09/09 20:27:41, skobes wrote: > Wrap this line at the commas for readability. Done. https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutText.cpp (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutText.cpp:1771: IntRect linesBox = enclosingIntRect(linesBoundingBox()); On 2016/09/09 20:27:41, skobes wrote: > Same question re. rounding to ints. Done.
https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutObject.h (right): https://codereview.chromium.org/2280153002/diff/200001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutObject.h:1373: // This method should never be reached as it's overriden by subclasses. On 2016/09/12 14:45:14, loonybear wrote: > On 2016/09/09 20:27:41, skobes wrote: > > Why not just make it pure virtual? Then the compiler will catch any missing > > overrides. > > Then I have to write an overriding function for subclasses: > LayoutSVGGradientStop and LayoutSVGImage If there are subclasses that don't override it, then why does it call NOTREACHED()? https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1375: LayoutRect rect = LayoutRect(linesBox); This line doesn't do anything. You can inline the call to linesBoundingBox in the return statement, like this: return linesBoundingBox(); https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutView.cpp:1006: block->adjustChildDebugRect(rect); At this point, the rect is empty. Should this be done after the width and height are set?
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutInline.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutInline.cpp:1375: LayoutRect rect = LayoutRect(linesBox); On 2016/09/12 17:09:35, skobes wrote: > This line doesn't do anything. You can inline the call to linesBoundingBox in > the return statement, like this: > > return linesBoundingBox(); Done. https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutView.cpp:1006: block->adjustChildDebugRect(rect); On 2016/09/12 17:09:35, skobes wrote: > At this point, the rect is empty. Should this be done after the width and > height are set? I did this part according to the following code in LayoutTreeAsText.cpp:186-221. And it seems like the adjustChildDebugRect() (as adjustForTableCells) was done before setting the width and height for the LayoutView object. LayoutBlock* cb = o.containingBlock(); bool adjustForTableCells = cb ? cb->isTableCell() : false; LayoutRect r; if (o.isText()) { ... } else if (o.isLayoutInline()) { ... } else if (o.isTableCell()) { ... } else if (o.isBox()) { ... } // FIXME: Temporary in order to ensure compatibility with existing layout test results. if (adjustForTableCells) r.move(0, -toLayoutTableCell(o.containingBlock())->intrinsicPaddingBefore()); if (o.isLayoutView()) { r.setWidth(LayoutUnit(toLayoutView(o).viewWidth(IncludeScrollbars))); r.setHeight(LayoutUnit(toLayoutView(o).viewHeight(IncludeScrollbars))); }
https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutView.cpp:1006: block->adjustChildDebugRect(rect); On 2016/09/12 17:48:48, loonybear wrote: > On 2016/09/12 17:09:35, skobes wrote: > > At this point, the rect is empty. Should this be done after the width and > > height are set? > > I did this part according to the following code in LayoutTreeAsText.cpp:186-221. > And it seems like the adjustChildDebugRect() (as adjustForTableCells) was done > before setting the width and height for the LayoutView object. I see. I guess the order doesn't matter since adjustChildDebugRect doesn't care about the size (and is temporary anyway), so this is ok.
https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutView.cpp (right): https://codereview.chromium.org/2280153002/diff/220001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutView.cpp:1006: block->adjustChildDebugRect(rect); On 2016/09/12 17:54:05, skobes wrote: > On 2016/09/12 17:48:48, loonybear wrote: > > On 2016/09/12 17:09:35, skobes wrote: > > > At this point, the rect is empty. Should this be done after the width and > > > height are set? > > > > I did this part according to the following code in > LayoutTreeAsText.cpp:186-221. > > And it seems like the adjustChildDebugRect() (as adjustForTableCells) was done > > before setting the width and height for the LayoutView object. > > I see. I guess the order doesn't matter since adjustChildDebugRect doesn't care > about the size (and is temporary anyway), so this is ok. Done.
My only remaining concern is the one about making debugRect pure virtual.
On 2016/09/12 18:29:40, skobes wrote: > My only remaining concern is the one about making debugRect pure virtual. So should I make it pure virtual and for the three other inherent classes, just write the method as {LayoutRect rect; return rect;} ?
On 2016/09/12 18:38:42, loonybear wrote: > So should I make it pure virtual and for the three other inherent classes, just > write the method as {LayoutRect rect; return rect;} ? Ideally they would have a more meaningful implementation. What does LayoutTreeAsText currently do when it encounters instances of these classes?
On 2016/09/12 18:43:36, skobes wrote: > On 2016/09/12 18:38:42, loonybear wrote: > > So should I make it pure virtual and for the three other inherent classes, > just > > write the method as {LayoutRect rect; return rect;} ? > > Ideally they would have a more meaningful implementation. What does > LayoutTreeAsText currently do when it encounters instances of these classes? Thanks for pointing that out (my previous implementation was wrong). I misinterpreted the code before. For the other inherent classes, besides adjustForTableCells (if the containing block is TableCell), it just creates a rect. Please see the code below. I guess I could either: A. define debugRect() in LayoutObject.cpp as: LayoutRect rect; LayoutBlock* block = containingBlock(); if (block) block->adjustChildDebugRect(rect); return rect; Or B. make debugRect() pure virtual and define it explicitly for the other inherent classes (in this case, there will be duplication). So I think the option A makes sense. Here is the current code in LayoutTreeAsText: LayoutBlock* cb = o.containingBlock(); bool adjustForTableCells = cb ? cb->isTableCell() : false; LayoutRect r; if (o.isText()) { ... } else if (o.isLayoutInline()) { ... } else if (o.isTableCell()) { ... } else if (o.isBox()) { ... } // FIXME: Temporary in order to ensure compatibility with existing layout test results. if (adjustForTableCells) r.move(0, -toLayoutTableCell(o.containingBlock())->intrinsicPaddingBefore()); if (o.isLayoutView()) { ... } ts << " " << r;
Please see the updated change.
lgtm
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_...) mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The problem comes from LayoutText.cpp. The original code looks like: LayoutRect LayoutText::debugRect() const { IntRect linesBox = enclosingIntRect(linesBoundingBox()); LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), linesBox.width(), linesBox.height())); ... return rect; } The current code looks like: LayoutRect LayoutText::debugRect() const { LayoutRect linesBox = linesBoundingBox(); LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), linesBox.width().toInt(), linesBox.height().toInt())); ... return rect; } ​I am not sure if we should update the layout tests or revert the change.​ ​Regards,​ Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Mon, Sep 12, 2016 at 2:43 PM, <skobes@chromium.org> wrote: > On 2016/09/12 18:38:42, loonybear wrote: > > So should I make it pure virtual and for the three other inherent > classes, > just > > write the method as {LayoutRect rect; return rect;} ? > > Ideally they would have a more meaningful implementation. What does > LayoutTreeAsText currently do when it encounters instances of these > classes? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
The problem comes from LayoutText.cpp. The original code looks like: LayoutRect LayoutText::debugRect() const { IntRect linesBox = enclosingIntRect(linesBoundingBox()); LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), linesBox.width(), linesBox.height())); ... return rect; } The current code looks like: LayoutRect LayoutText::debugRect() const { LayoutRect linesBox = linesBoundingBox(); LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), linesBox.width().toInt(), linesBox.height().toInt())); ... return rect; } ​I am not sure if we should update the layout tests or revert the change.​ ​Regards,​ Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Mon, Sep 12, 2016 at 2:43 PM, <skobes@chromium.org> wrote: > On 2016/09/12 18:38:42, loonybear wrote: > > So should I make it pure virtual and for the three other inherent > classes, > just > > write the method as {LayoutRect rect; return rect;} ? > > Ideally they would have a more meaningful implementation. What does > LayoutTreeAsText currently do when it encounters instances of these > classes? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
On 2016/09/14 14:50:04, chromium-reviews wrote: > The problem comes from LayoutText.cpp. The original code looks like: > LayoutRect LayoutText::debugRect() const > { > IntRect linesBox = enclosingIntRect(linesBoundingBox()); > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > linesBox.width(), linesBox.height())); > ... return rect; > } > > The current code looks like: > > LayoutRect LayoutText::debugRect() const > { > LayoutRect linesBox = linesBoundingBox(); > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > linesBox.width().toInt(), linesBox.height().toInt())); > ... return rect; > } Neither of these seem ideal. Can we keep everything in LayoutUnits?
Now that I change it to LayoutRect LayoutText::debugRect() const { LayoutRect linesBox = linesBoundingBox(); LayoutRect rect = LayoutRect(enclosingIntRect(LayoutRect(LayoutUnit(firstRunX()), LayoutUnit(firstRunY()), LayoutUnit(linesBox.width()), LayoutUnit(linesBox.height())))); ... return rect; } The test results match the expectation now. But I am not so convinced this is the right fix. Is there anything cleaner I can do? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 12:35 PM, <skobes@chromium.org> wrote: > On 2016/09/14 14:50:04, chromium-reviews wrote: > > The problem comes from LayoutText.cpp. The original code looks like: > > LayoutRect LayoutText::debugRect() const > > { > > IntRect linesBox = enclosingIntRect(linesBoundingBox()); > > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > > linesBox.width(), linesBox.height())); > > ... return rect; > > } > > > > The current code looks like: > > > > LayoutRect LayoutText::debugRect() const > > { > > LayoutRect linesBox = linesBoundingBox(); > > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > > linesBox.width().toInt(), linesBox.height().toInt())); > > ... return rect; > > } > > Neither of these seem ideal. Can we keep everything in LayoutUnits? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
Now that I change it to LayoutRect LayoutText::debugRect() const { LayoutRect linesBox = linesBoundingBox(); LayoutRect rect = LayoutRect(enclosingIntRect(LayoutRect(LayoutUnit(firstRunX()), LayoutUnit(firstRunY()), LayoutUnit(linesBox.width()), LayoutUnit(linesBox.height())))); ... return rect; } The test results match the expectation now. But I am not so convinced this is the right fix. Is there anything cleaner I can do? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 12:35 PM, <skobes@chromium.org> wrote: > On 2016/09/14 14:50:04, chromium-reviews wrote: > > The problem comes from LayoutText.cpp. The original code looks like: > > LayoutRect LayoutText::debugRect() const > > { > > IntRect linesBox = enclosingIntRect(linesBoundingBox()); > > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > > linesBox.width(), linesBox.height())); > > ... return rect; > > } > > > > The current code looks like: > > > > LayoutRect LayoutText::debugRect() const > > { > > LayoutRect linesBox = linesBoundingBox(); > > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), > > linesBox.width().toInt(), linesBox.height().toInt())); > > ... return rect; > > } > > Neither of these seem ideal. Can we keep everything in LayoutUnits? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
May I ask why we want the expected results to be all INT values? Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 1:44 PM, Luna Lu <lunalu@google.com> wrote: > Now that I change it to > LayoutRect LayoutText::debugRect() const > { > LayoutRect linesBox = linesBoundingBox(); > LayoutRect rect = LayoutRect(enclosingIntRect( > LayoutRect(LayoutUnit(firstRunX()), LayoutUnit(firstRunY()), > LayoutUnit(linesBox.width()), LayoutUnit(linesBox.height())))); > ... > return rect; > } > > The test results match the expectation now. But I am not so convinced this > is the right fix. Is there anything cleaner I can do? > > Thanks > > > Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 > > On Wed, Sep 14, 2016 at 12:35 PM, <skobes@chromium.org> wrote: > >> On 2016/09/14 14:50:04, chromium-reviews wrote: >> > The problem comes from LayoutText.cpp. The original code looks like: >> > LayoutRect LayoutText::debugRect() const >> > { >> > IntRect linesBox = enclosingIntRect(linesBoundingBox()); >> > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), >> > linesBox.width(), linesBox.height())); >> > ... return rect; >> > } >> > >> > The current code looks like: >> > >> > LayoutRect LayoutText::debugRect() const >> > { >> > LayoutRect linesBox = linesBoundingBox(); >> > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), >> > linesBox.width().toInt(), linesBox.height().toInt())); >> > ... return rect; >> > } >> >> Neither of these seem ideal. Can we keep everything in LayoutUnits? >> >> https://codereview.chromium.org/2280153002/ >> > > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
May I ask why we want the expected results to be all INT values? Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 1:44 PM, Luna Lu <lunalu@google.com> wrote: > Now that I change it to > LayoutRect LayoutText::debugRect() const > { > LayoutRect linesBox = linesBoundingBox(); > LayoutRect rect = LayoutRect(enclosingIntRect( > LayoutRect(LayoutUnit(firstRunX()), LayoutUnit(firstRunY()), > LayoutUnit(linesBox.width()), LayoutUnit(linesBox.height())))); > ... > return rect; > } > > The test results match the expectation now. But I am not so convinced this > is the right fix. Is there anything cleaner I can do? > > Thanks > > > Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 > > On Wed, Sep 14, 2016 at 12:35 PM, <skobes@chromium.org> wrote: > >> On 2016/09/14 14:50:04, chromium-reviews wrote: >> > The problem comes from LayoutText.cpp. The original code looks like: >> > LayoutRect LayoutText::debugRect() const >> > { >> > IntRect linesBox = enclosingIntRect(linesBoundingBox()); >> > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), >> > linesBox.width(), linesBox.height())); >> > ... return rect; >> > } >> > >> > The current code looks like: >> > >> > LayoutRect LayoutText::debugRect() const >> > { >> > LayoutRect linesBox = linesBoundingBox(); >> > LayoutRect rect = LayoutRect(IntRect(firstRunX(), firstRunY(), >> > linesBox.width().toInt(), linesBox.height().toInt())); >> > ... return rect; >> > } >> >> Neither of these seem ideal. Can we keep everything in LayoutUnits? >> >> https://codereview.chromium.org/2280153002/ >> > > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
On 2016/09/14 17:57:34, chromium-reviews wrote: > May I ask why we want the expected results to be all INT values? I don't know that we do, unless the fractional bits are indeterminate for some reason. How big of a rebaseline does it cause if we don't convert to int?
Either .61 or .64 example: LayoutText {#text} at (0,0) size 271x19 LayoutText {#text} at (0,0) size 270.39x19 Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:01 PM, <skobes@chromium.org> wrote: > On 2016/09/14 17:57:34, chromium-reviews wrote: > > May I ask why we want the expected results to be all INT values? > > I don't know that we do, unless the fractional bits are indeterminate for > some > reason. > > How big of a rebaseline does it cause if we don't convert to int? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
Either .61 or .64 example: LayoutText {#text} at (0,0) size 271x19 LayoutText {#text} at (0,0) size 270.39x19 Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:01 PM, <skobes@chromium.org> wrote: > On 2016/09/14 17:57:34, chromium-reviews wrote: > > May I ask why we want the expected results to be all INT values? > > I don't know that we do, unless the fractional bits are indeterminate for > some > reason. > > How big of a rebaseline does it cause if we don't convert to int? > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
On 2016/09/14 18:25:54, chromium-reviews wrote: > Either .61 or .64 > example: > LayoutText {#text} at (0,0) size 271x19 > LayoutText {#text} at (0,0) size 270.39x19 I meant, how many tests are affected? If it's only a few, and if the output is consistent, then I'd be in favor of updating the expectations. But if it's a large number, or if the output is not stable, then we should match the existing behavior (and perhaps file a bug to follow up on the issue later).
12 + 2 tests. Regressions: Unexpected text-only failures (12) fast/text/ellipsis-ltr-text-in-ltr-flow-underline-composition.html [ Failure ] fast/text/ellipsis-ltr-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-ltr-text-in-ltr-flow.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow-underline-composition.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow.html [ Failure ] fast/text/ellipsis-mixed-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-mixed-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-ltr-flow.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow.html [ Failure ] Regressions: Unexpected image and text failures (2) fast/text/ellipsis-rtl-text-in-ltr-flow-underline-composition.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow-underline-composition.html [ Failure ] Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:35 PM, <skobes@chromium.org> wrote: > On 2016/09/14 18:25:54, chromium-reviews wrote: > > Either .61 or .64 > > example: > > LayoutText {#text} at (0,0) size 271x19 > > LayoutText {#text} at (0,0) size 270.39x19 > > I meant, how many tests are affected? If it's only a few, and if the > output is > consistent, then I'd be in favor of updating the expectations. But if it's > a > large number, or if the output is not stable, then we should match the > existing > behavior (and perhaps file a bug to follow up on the issue later). > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
12 + 2 tests. Regressions: Unexpected text-only failures (12) fast/text/ellipsis-ltr-text-in-ltr-flow-underline-composition.html [ Failure ] fast/text/ellipsis-ltr-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-ltr-text-in-ltr-flow.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow-underline-composition.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-ltr-text-in-rtl-flow.html [ Failure ] fast/text/ellipsis-mixed-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-mixed-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-ltr-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-ltr-flow.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow-underline.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow.html [ Failure ] Regressions: Unexpected image and text failures (2) fast/text/ellipsis-rtl-text-in-ltr-flow-underline-composition.html [ Failure ] fast/text/ellipsis-rtl-text-in-rtl-flow-underline-composition.html [ Failure ] Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:35 PM, <skobes@chromium.org> wrote: > On 2016/09/14 18:25:54, chromium-reviews wrote: > > Either .61 or .64 > > example: > > LayoutText {#text} at (0,0) size 271x19 > > LayoutText {#text} at (0,0) size 270.39x19 > > I meant, how many tests are affected? If it's only a few, and if the > output is > consistent, then I'd be in favor of updating the expectations. But if it's > a > large number, or if the output is not stable, then we should match the > existing > behavior (and perhaps file a bug to follow up on the issue later). > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
Let's update the expectations. (The image diffs will be unrelated.) On 2016/09/14 18:45:11, blink-reviews wrote: > 12 + 2 tests. > > Regressions: Unexpected text-only failures (12) > fast/text/ellipsis-ltr-text-in-ltr-flow-underline-composition.html [ > Failure ] > fast/text/ellipsis-ltr-text-in-ltr-flow-underline.html [ Failure ] > fast/text/ellipsis-ltr-text-in-ltr-flow.html [ Failure ] > fast/text/ellipsis-ltr-text-in-rtl-flow-underline-composition.html [ > Failure ] > fast/text/ellipsis-ltr-text-in-rtl-flow-underline.html [ Failure ] > fast/text/ellipsis-ltr-text-in-rtl-flow.html [ Failure ] > fast/text/ellipsis-mixed-text-in-ltr-flow-underline.html [ Failure ] > fast/text/ellipsis-mixed-text-in-rtl-flow-underline.html [ Failure ] > fast/text/ellipsis-rtl-text-in-ltr-flow-underline.html [ Failure ] > fast/text/ellipsis-rtl-text-in-ltr-flow.html [ Failure ] > fast/text/ellipsis-rtl-text-in-rtl-flow-underline.html [ Failure ] > fast/text/ellipsis-rtl-text-in-rtl-flow.html [ Failure ] > > Regressions: Unexpected image and text failures (2) > fast/text/ellipsis-rtl-text-in-ltr-flow-underline-composition.html [ > Failure ] > fast/text/ellipsis-rtl-text-in-rtl-flow-underline-composition.html [ > Failure ] > > > Luna Lu | Software Engineer | mailto:lunalu@google.com | +1 519 513 5751 > > On Wed, Sep 14, 2016 at 2:35 PM, <mailto:skobes@chromium.org> wrote: > > > On 2016/09/14 18:25:54, chromium-reviews wrote: > > > Either .61 or .64 > > > example: > > > LayoutText {#text} at (0,0) size 271x19 > > > LayoutText {#text} at (0,0) size 270.39x19 > > > > I meant, how many tests are affected? If it's only a few, and if the > > output is > > consistent, then I'd be in favor of updating the expectations. But if it's > > a > > large number, or if the output is not stable, then we should match the > > existing > > behavior (and perhaps file a bug to follow up on the issue later). > > > > https://codereview.chromium.org/2280153002/ > > > > -- > You received this message because you are subscribed to the Google Groups "Blink > Reviews" group. > To unsubscribe from this group and stop receiving emails from it, send an email > to mailto:blink-reviews+unsubscribe@chromium.org.
Patchset #8 (id:300001) has been deleted
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Hi, I am thinking about splitting this into 2 CL's. For the current one, I only refactor (i.e., I keep the very original implementation). I will address other FIXME's/TODO's/implementation change in the next CL. If you think that splitting this CL is a good idea, could you please take another look at it once I revert all the changes? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:57 PM, <skobes@chromium.org> wrote: > Let's update the expectations. > > (The image diffs will be unrelated.) > > On 2016/09/14 18:45:11, blink-reviews wrote: > > 12 + 2 tests. > > > > Regressions: Unexpected text-only failures (12) > > fast/text/ellipsis-ltr-text-in-ltr-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-ltr-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-ltr-flow.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow.html [ Failure ] > > fast/text/ellipsis-mixed-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-mixed-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-ltr-flow.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow.html [ Failure ] > > > > Regressions: Unexpected image and text failures (2) > > fast/text/ellipsis-rtl-text-in-ltr-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow-underline-composition.html [ > > Failure ] > > > > > > Luna Lu | Software Engineer | mailto:lunalu@google.com | +1 519 513 5751 > > > > On Wed, Sep 14, 2016 at 2:35 PM, <mailto:skobes@chromium.org> wrote: > > > > > On 2016/09/14 18:25:54, chromium-reviews wrote: > > > > Either .61 or .64 > > > > example: > > > > LayoutText {#text} at (0,0) size 271x19 > > > > LayoutText {#text} at (0,0) size 270.39x19 > > > > > > I meant, how many tests are affected? If it's only a few, and if the > > > output is > > > consistent, then I'd be in favor of updating the expectations. But if > it's > > > a > > > large number, or if the output is not stable, then we should match the > > > existing > > > behavior (and perhaps file a bug to follow up on the issue later). > > > > > > https://codereview.chromium.org/2280153002/ > > > > > > > -- > > You received this message because you are subscribed to the Google Groups > "Blink > > Reviews" group. > > To unsubscribe from this group and stop receiving emails from it, send an > email > > to mailto:blink-reviews+unsubscribe@chromium.org. > > > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Blink Reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-reviews+unsubscribe@chromium.org.
Hi, I am thinking about splitting this into 2 CL's. For the current one, I only refactor (i.e., I keep the very original implementation). I will address other FIXME's/TODO's/implementation change in the next CL. If you think that splitting this CL is a good idea, could you please take another look at it once I revert all the changes? Thanks Luna Lu | Software Engineer | lunalu@google.com | +1 519 513 5751 On Wed, Sep 14, 2016 at 2:57 PM, <skobes@chromium.org> wrote: > Let's update the expectations. > > (The image diffs will be unrelated.) > > On 2016/09/14 18:45:11, blink-reviews wrote: > > 12 + 2 tests. > > > > Regressions: Unexpected text-only failures (12) > > fast/text/ellipsis-ltr-text-in-ltr-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-ltr-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-ltr-flow.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-ltr-text-in-rtl-flow.html [ Failure ] > > fast/text/ellipsis-mixed-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-mixed-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-ltr-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-ltr-flow.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow-underline.html [ Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow.html [ Failure ] > > > > Regressions: Unexpected image and text failures (2) > > fast/text/ellipsis-rtl-text-in-ltr-flow-underline-composition.html [ > > Failure ] > > fast/text/ellipsis-rtl-text-in-rtl-flow-underline-composition.html [ > > Failure ] > > > > > > Luna Lu | Software Engineer | mailto:lunalu@google.com | +1 519 513 5751 > > > > On Wed, Sep 14, 2016 at 2:35 PM, <mailto:skobes@chromium.org> wrote: > > > > > On 2016/09/14 18:25:54, chromium-reviews wrote: > > > > Either .61 or .64 > > > > example: > > > > LayoutText {#text} at (0,0) size 271x19 > > > > LayoutText {#text} at (0,0) size 270.39x19 > > > > > > I meant, how many tests are affected? If it's only a few, and if the > > > output is > > > consistent, then I'd be in favor of updating the expectations. But if > it's > > > a > > > large number, or if the output is not stable, then we should match the > > > existing > > > behavior (and perhaps file a bug to follow up on the issue later). > > > > > > https://codereview.chromium.org/2280153002/ > > > > > > > -- > > You received this message because you are subscribed to the Google Groups > "Blink > > Reviews" group. > > To unsubscribe from this group and stop receiving emails from it, send an > email > > to mailto:blink-reviews+unsubscribe@chromium.org. > > > > https://codereview.chromium.org/2280153002/ > -- You received this message because you are subscribed to the Google Groups "Chromium-reviews" group. To unsubscribe from this group and stop receiving emails from it, send an email to chromium-reviews+unsubscribe@chromium.org.
On 2016/09/14 21:45:51, chromium-reviews wrote: > I am thinking about splitting this into 2 CL's. For the current one, I only > refactor (i.e., I keep the very original implementation). I will address > other FIXME's/TODO's/implementation change in the next CL. Yes that's fine.
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
The CQ bit was unchecked by lunalu@chromium.org
Patchset #6 (id:260001) has been deleted
Patchset #5 (id:240001) has been deleted
Patchset #5 (id:280001) has been deleted
Patchset #6 (id:340001) has been deleted
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by lunalu@chromium.org
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
The CQ bit was unchecked by lunalu@chromium.org
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was checked by lunalu@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
Hi skobes, I have reverted the change to the original impl. Could you please take a final look before I submit? Thanks
https://codereview.chromium.org/2280153002/diff/360001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutText.h (right): https://codereview.chromium.org/2280153002/diff/360001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutText.h:184: void applyTextTransformFromTo(int from, int len, const ComputedStyle*); Where did this come from?
Done. Thanks https://codereview.chromium.org/2280153002/diff/360001/third_party/WebKit/Sou... File third_party/WebKit/Source/core/layout/LayoutText.h (right): https://codereview.chromium.org/2280153002/diff/360001/third_party/WebKit/Sou... third_party/WebKit/Source/core/layout/LayoutText.h:184: void applyTextTransformFromTo(int from, int len, const ComputedStyle*); On 2016/09/15 19:04:36, skobes wrote: > Where did this come from? Done.
lgtm
The CQ bit was checked by lunalu@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from benjhayden@chromium.org Link to the patchset: https://codereview.chromium.org/2280153002/#ps380001 (title: "Update")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: cast_shell_android on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_a...) chromeos_daisy_chromium_compile_only_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromeos_daisy_...) linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
Patchset #7 (id:380001) has been deleted
The CQ bit was checked by lunalu@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from benjhayden@chromium.org, skobes@chromium.org Link to the patchset: https://codereview.chromium.org/2280153002/#ps400001 (title: "Rebase")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: linux_chromium_chromeos_ozone_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_...)
Patchset #7 (id:400001) has been deleted
The CQ bit was checked by lunalu@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from benjhayden@chromium.org, skobes@chromium.org Link to the patchset: https://codereview.chromium.org/2280153002/#ps420001 (title: "Rebase")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Message was sent while issue was closed.
Committed patchset #7 (id:420001)
Message was sent while issue was closed.
Description was changed from ========== Refactoring out the code in LayoutTreeAsText::writeLayoutObject. BUG=481588 ========== to ========== Refactoring out the code in LayoutTreeAsText::writeLayoutObject. BUG=481588 Committed: https://crrev.com/ecf51ddf5158be270b3ad65d613c9498d644fc6b Cr-Commit-Position: refs/heads/master@{#419072} ==========
Message was sent while issue was closed.
Patchset 7 (id:??) landed as https://crrev.com/ecf51ddf5158be270b3ad65d613c9498d644fc6b Cr-Commit-Position: refs/heads/master@{#419072} |