Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stylo - gecko glue code for font-size-adjust. #14227

Merged
merged 1 commit into from Nov 19, 2016

Conversation

chenpighead
Copy link
Contributor

@chenpighead chenpighead commented Nov 15, 2016

Implement the gecko-side glue code for font-size-adjust.
This is a followup for #14125, which is originally filed in #13875.


  • ./mach build -d does not report any errors
  • ./mach test-tidy does not report any errors
  • These changes fix #__ (github issue number if applicable).
  • There are tests for these changes OR
  • These changes do not require tests because _____

This change is Reviewable

@highfive
Copy link

Heads up! This PR modifies the following files:

  • @bholley: components/style/properties/gecko.mako.rs, components/style/properties/longhand/font.mako.rs
  • @emilio: components/style/properties/gecko.mako.rs, components/style/properties/longhand/font.mako.rs

@highfive
Copy link

warning Warning warning

  • These commits modify style code, but no tests are modified. Please consider adding a test!

@highfive highfive added the S-awaiting-review There is new code that needs to be reviewed. label Nov 15, 2016
@chenpighead
Copy link
Contributor Author

Though this is part of the Stylo work, it seems to me that there's no gecko change needed. So, I didn't file a bug on Bugzilla. Please let me know if I should do it. cc @Manishearth @heycam

@chenpighead
Copy link
Contributor Author

self.gecko.mFont.sizeAdjust = other.gecko.mFont.sizeAdjust;
}

pub fn clone_font_size_adjust(&self) -> longhands::font_size_adjust::computed_value::T {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need Clone if it's a Copy type?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I remove Clone, an error occurs while building stylo:

 0:33.04 error: no method named `clone_font_size_adjust` found for type `&gecko_properties::GeckoFont` in the current scope
 0:33.04      --> /Users/jeremy/stylo/obj-x86_64-apple-darwin16.1.0/toolkit/library/gtest/rust/./x86_64-apple-darwin/debug/build/style-c9cd1e6c6606a30e/out/properties.rs:42421:50
 0:33.04       |
 0:33.04 42421 |                             old_style.get_font().clone_font_size_adjust(),
 0:33.04       |                                                  ^^^^^^^^^^^^^^^^^^^^^^
 0:33.04 

Not sure if I should remove the Clone and try to fix this error somewhere else....

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh never mind. It was a misunderstanding.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clone_ isn't related to Clone, it's usually used for animation. From Servo's POV the style structs store servo computed values, so "cloning" one out in stylo is a more complex operation than a regular clone.

use properties::longhands::font_size_adjust::computed_value::T;
use values::specified::Number;

T::Number(Number(self.gecko.mFont.sizeAdjust))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In that case, shouldn't we be checking whether we get a -1.0 here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we should. Fixed in the next version.

@Manishearth
Copy link
Member

@bors-servo r+

thanks!

@bors-servo
Copy link
Contributor

📌 Commit 32bf5ab has been approved by Manishearth

@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-awaiting-review There is new code that needs to be reviewed. labels Nov 15, 2016
@chenpighead
Copy link
Contributor Author

@chenpighead
Copy link
Contributor Author

Not sure if this is necessary, but here is the screenshot of rendering font-size-adjust property test page from a stylo build.

screen shot 2016-11-17 at 12 11 13 am

@Manishearth
Copy link
Member

(yeah, usually a screenshot is preferred)

@chenpighead
Copy link
Contributor Author

Thank you for the pointers. Is there anything else that I can do to make this PR be merged?

@wafflespeanut
Copy link
Contributor

This PR is on its way to getting merged. Please wait till the build succeeds 😄

@bors-servo
Copy link
Contributor

⌛ Testing commit 32bf5ab with merge b5e81bf...

bors-servo pushed a commit that referenced this pull request Nov 17, 2016
Stylo - gecko glue code for font-size-adjust.

<!-- Please describe your changes on the following line: -->

Implement the gecko-side glue code for font-size-adjust.
This is a followup for #14125, which is originally filed in #13875.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14227)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

💔 Test failed - mac-rel-wpt1

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Nov 17, 2016
@wafflespeanut
Copy link
Contributor

@bors-servo retry #11100

@bors-servo
Copy link
Contributor

⌛ Testing commit 32bf5ab with merge 45af839...

bors-servo pushed a commit that referenced this pull request Nov 17, 2016
Stylo - gecko glue code for font-size-adjust.

<!-- Please describe your changes on the following line: -->

Implement the gecko-side glue code for font-size-adjust.
This is a followup for #14125, which is originally filed in #13875.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14227)
<!-- Reviewable:end -->
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Nov 17, 2016
@bors-servo
Copy link
Contributor

💔 Test failed - mac-rel-wpt1

@highfive highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Nov 18, 2016
@bors-servo
Copy link
Contributor

💔 Test failed - linux-rel-wpt

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Nov 18, 2016
@wafflespeanut
Copy link
Contributor

@bors-servo retry #14267

@bors-servo
Copy link
Contributor

⌛ Testing commit 32bf5ab with merge ced548a...

bors-servo pushed a commit that referenced this pull request Nov 18, 2016
Stylo - gecko glue code for font-size-adjust.

<!-- Please describe your changes on the following line: -->

Implement the gecko-side glue code for font-size-adjust.
This is a followup for #14125, which is originally filed in #13875.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14227)
<!-- Reviewable:end -->
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Nov 18, 2016
@bors-servo
Copy link
Contributor

💔 Test failed - mac-rel-wpt1

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Nov 18, 2016
@Manishearth
Copy link
Member

@bors-servo
Copy link
Contributor

⚡ Previous build results for arm32, arm64, linux-dev, linux-rel-wpt, mac-dev-unit, mac-rel-wpt2, windows-dev are reusable. Rebuilding only linux-rel-css, mac-rel-css, mac-rel-wpt1...

@bors-servo
Copy link
Contributor

💔 Test failed - linux-rel-css

@highfive highfive added the S-tests-failed The changes caused existing tests to fail. label Nov 19, 2016
@KiChjang
Copy link
Contributor

@bors-servo
Copy link
Contributor

⌛ Testing commit 32bf5ab with merge a4e26d5...

bors-servo pushed a commit that referenced this pull request Nov 19, 2016
Stylo - gecko glue code for font-size-adjust.

<!-- Please describe your changes on the following line: -->

Implement the gecko-side glue code for font-size-adjust.
This is a followup for #14125, which is originally filed in #13875.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [ ] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14227)
<!-- Reviewable:end -->
@highfive highfive added S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. and removed S-tests-failed The changes caused existing tests to fail. labels Nov 19, 2016
@bors-servo
Copy link
Contributor

💔 Test failed - mac-rel-wpt1

@highfive highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Nov 19, 2016
@wafflespeanut
Copy link
Contributor

@bors-servo retry

I hate #11100 😒

@bors-servo
Copy link
Contributor

⚡ Previous build results for arm32, arm64, linux-dev, linux-rel-css, mac-dev-unit, mac-rel-css, mac-rel-wpt2, windows-dev are reusable. Rebuilding only linux-rel-wpt, mac-rel-wpt1...

@bors-servo
Copy link
Contributor

@bors-servo bors-servo merged commit 32bf5ab into servo:master Nov 19, 2016
@wafflespeanut
Copy link
Contributor

YESSSSSSS!!!! FINALLY!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-tests-failed The changes caused existing tests to fail.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants