Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upadd reftest for curious text clipping rounding error #2810
Conversation
|
Echoing on the verbal conversation we had, I believe this is a good case for the "chasing" infrastructure that I tried to land recently in #2710. If it worked, we'd be able to do:
|
|
OK, I finally found the cause of this. In this case, the Normally this doesn't actually affect the rendering of a text run (the clip rect is correct in this case). However, if the glyph is inside a complex clip rect, WR may decide to draw a clip mask for the text run. In this case, it uses the bounds of the text run to work out a minimal clip mask size to allocate. Once that happens, the clip mask shader assumes that any pixels which get rendered that are outside the bounds of the clip mask are transparent / clipped. So what we need to do is take a look at the Gecko code and see if we can find out why the bounding rect on this text run is too tight. |
|
I'll leave this open for now, but hopefully if we can find / fix this in Gecko we can just close this PR. |
|
is this being possible a security issue for wr? |
|
@gankro I'm not sure I follow - could you explain further? |
|
so assuming an attack vector of corrupting the display list:
|
|
Not that I can think of, although I'm no expert on any of this stuff. |
|
Closing this for now - please re-open if there's more work / discussion needed here. |
Gankra commentedJun 6, 2018
•
edited by larsbergstrom
This is a minimum reproduction of https://bugzilla.mozilla.org/show_bug.cgi?id=1464371
currently fails on master
(nb you could remove the second text-run but i wanted it there to prove to myself that i was measuring the right thing)
This change is