Repository navigation
Implement Element.client{Top,Left,Width,Height} - #6662
Conversation
|
Thanks for the pull request, and welcome! The Servo team is excited to review your changes, and you should hear from @metajack (or someone else) soon. |
|
Critic review: https://critic.hoppipolla.co.uk/r/5594 This is an external review system which you may optionally use for the code review of your pull request. In order to help critic track your changes, please do not make in-place history rewrites (e.g. via |
There was a problem hiding this comment.
Maybe we should group this into a single get_geometry() umbrella function with an associated GeometryMetric enum containing ClientTop, ClientWidth enum so we don't have a dozen functions here. (BTW, ClientGeometry probably isn't the right word, since there are non-"client" metrics too; offsetTop, for example.)
|
Looks good. For Thanks for the work here, BTW—this is going to make a lot of pages throw exceptions less often 👍 |
4672018 to
162ecd0
Compare
|
This now fully implements Review status: 0 of 8 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. components/script/layout_interface.rs, line 99 [r1] (raw file): Comments from the review on Reviewable.io |
|
A test for something with |
|
D'oh, of course. I had that in my manual testing but completely forgot to add it to the wpt test. Fixed. Review status: 0 of 8 files reviewed at latest revision, 1 unresolved discussion, all commit checks successful. Comments from the review on Reviewable.io |
There was a problem hiding this comment.
Specify in the comment that this is in pixels.
|
This looks good modulo some minor nits. |
|
Nits addressed. r? @pcwalton. Review status: 0 of 8 files reviewed at latest revision, 5 unresolved discussions, all commit checks successful. components/layout/layout_task.rs, line 130 [r3] (raw file): components/layout/layout_task.rs, line 1443 [r3] (raw file): components/script/layout_interface.rs, line 98 [r3] (raw file): tests/wpt/mozilla/tests/mozilla/client-top-left-height-width.html, line 113 [r3] (raw file): Comments from the review on Reviewable.io |
|
Reviewed 7 of 7 files at r1, 9 of 9 files at r2, 1 of 1 files at r3. Comments from the review on Reviewable.io |
|
@bors-servo r=glennw,pcwatson |
|
📌 Commit 126938a has been approved by |
|
Good old Patrick Watson. Project wouldn't be the same without him. |
This isn't done, but contains a working implementation of at least
clientTop. Feedback would be much appreciated: it's probably far from ideal.Implementing
clientLeftis straight-forward, I think, butclientWidthandclientHeightrequire accessing theborder_box- and I don't know how that works, yet.