aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout
Commit message (Collapse)AuthorAgeFilesLines
* Implemented paint worklet properties.Alan Jeffrey2017-07-114-8/+27
|
* Auto merge of #17615 - bholley:simplify_local_context, r=emiliobors-servo2017-07-052-46/+7
|\ | | | | | | | | | | | | | | | | | | | | Rip out the generic abstractions around ThreadLocalStyleContext https://bugzilla.mozilla.org/show_bug.cgi?id=1378540 <!-- 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/17615) <!-- Reviewable:end -->
| * Rip out the generic abstractions around ThreadLocalStyleContext.Bobby Holley2017-07-052-46/+7
| | | | | | | | MozReview-Commit-ID: 5WTLuk323Ac
* | Auto merge of #17556 - jyc:inline-metrics-of-block, r=emiliobors-servo2017-07-051-11/+29
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | layout: Clean up inline_metrics_of_block a little. Previously the variable names were a little confusing (ascent was used for the space_above_baseline in one branch and the and ascent field in another branch, and was not really the ascent in one). Also add a small diagram. <!-- Please describe your changes on the following line: --> --- <!-- 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 - [X] These changes do not require tests because they just refactor existing code <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- 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/17556) <!-- Reviewable:end -->
| * layout: Clean up inline_metrics_of_block a little.Jonathan Chan2017-07-051-11/+29
| | | | | | | | | | | | | | Previously the variable names were a little confusing (ascent was used for the space_above_baseline in one branch and the and ascent field in another branch, and was not really the ascent in one). Also add a small diagram.
* | Replace remaining usage of deprecated Range::step_bySimon Sapin2017-07-052-6/+21
| | | | | | | | … which is being removed in https://github.com/rust-lang/rust/pull/43012
* | Auto merge of #17581 - mbrubeck:incremental, r=pcwaltonbors-servo2017-06-302-1/+24
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix incremental layout bugs for absolute and cleared elements Fixes #17307. <del>There were two underlying bugs:</del> * <del>Nodes were not marked dirty when their style attribute changed.</del> * BaseFlow flags set during flow construction could get out of sync with the element's style if repair_style was called. --- - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #17307 - [x] There are tests for these changes <!-- 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/17581) <!-- Reviewable:end -->
| * | Update flags for absolutely positioned elements on style changesMatt Brubeck2017-06-302-1/+24
| | | | | | | | | | | | Fixes #17307.
* | | stylo: Implement -moz-prefixed radial gradientsNazım Can Altınova2017-06-301-2/+2
|/ /
* | Implemented paint worklet rendering context.Alan Jeffrey2017-06-301-8/+17
| |
* | Implemented paint worklets invoking worklet scripts.Alan Jeffrey2017-06-291-0/+1
|/
* Make text-shadow and box-shadow use SimpleShadowAnthony Ramine2017-06-282-20/+25
|
* Use the Separator trait for the filter propertyAnthony Ramine2017-06-272-17/+16
|
* remove various things now that Rust 1.17 is requiredNathan Froyd2017-06-233-10/+2
| | | | | std::ptr::eq and Arc::ptr_eq are now usuable, and we can replace a panic!() with abort().
* Paint worklet size should agree with Chrome.Alan Jeffrey2017-06-221-2/+6
|
* Auto merge of #17395 - pyfisch:issue17387, r=emiliobors-servo2017-06-211-5/+5
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make background gradient cover padding CSS-gradients should not only cover the content of an element but also the padding (but not the border). <!-- Please describe your changes on the following line: --> Thanks to @atouchet for catching this. <!-- 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 - [x] These changes fix #17387 (github issue number if applicable). <!-- Either: --> - [x] These changes do not require tests because gradients are hard to test automatically but you can use [this gist](https://gist.github.com/pyfisch/fa263c8dfc57e5812fe8a4869ad61513) as a manual test. <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- 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/17395) <!-- Reviewable:end -->
| * Make background gradient cover paddingPyfisch2017-06-201-5/+5
| | | | | | | | | | | | | | CSS-gradients should not only cover the content of an element but also the padding (but not the border). Add a reftest.
* | Update WR (z-buffer fix, border-image fill support).Glenn Watson2017-06-211-0/+1
| |
* | Use generics for the filter propertyAnthony Ramine2017-06-203-7/+9
|/ | | | This introduces an additional shadow type for drop-shadow().
* UntrySimon Sapin2017-06-184-16/+14
|
* Rename LengthOrPercentageOrAutoOrContent to FlexBasisAnthony Ramine2017-06-171-12/+15
|
* Remove explicit dependencies on serde_deriveSimon Sapin2017-06-162-4/+1
|
* Bump serde to 1.0Bastien Orivel2017-06-161-7/+7
|
* Auto merge of #17352 - glennw:update-wr-faster-text, r=emiliobors-servo2017-06-161-1/+1
|\ | | | | | | | | | | | | | | Update WR (CPU text optimizations, image format renames). <!-- 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/17352) <!-- Reviewable:end -->
| * Update WR (CPU text optimizations, image format renames).Glenn Watson2017-06-161-1/+1
| |
* | Auto merge of #17348 - emilio:bup, r=bholleybors-servo2017-06-151-8/+3
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | style: Inline RestyleData. Bug: 1368236 MozReview-Commit-ID: 49s3SO0PMHf <!-- 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/17348) <!-- Reviewable:end -->
| * style: Inline RestyleData.Emilio Cobos Álvarez2017-06-161-8/+3
| | | | | | | | | | Bug: 1368236 MozReview-Commit-ID: 49s3SO0PMHf
* | Make computed types hold Percentage instead of bare CSSFloatAnthony Ramine2017-06-158-16/+17
|/
* Bump rayon to 0.8.Bobby Holley2017-06-141-1/+1
| | | | MozReview-Commit-ID: 8OFE5PghMzl
* Make BaseFlow::stacking_relative_position a vector.Nicolas Silva2017-06-148-23/+22
|
* Bump euclid to 0.14.Nicolas Silva2017-06-1411-74/+82
|
* Derive ToCss for cursor keywordsAnthony Ramine2017-06-081-2/+2
|
* Auto merge of #17219 - upsuper:currentcolor, r=Manishearth,birtlesbors-servo2017-06-075-27/+15
|\ | | | | | | | | | | | | | | | | | | | | Support interpolation between currentcolor and numeric color This is the Servo side change of [bug 1345709](https://bugzilla.mozilla.org/show_bug.cgi?id=1345709). <!-- 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/17219) <!-- Reviewable:end -->
| * Add separate computed Color value.Xidorn Quan2017-06-084-6/+3
| |
| * Create RGBAColor for colors compute to RGBA.Xidorn Quan2017-06-081-21/+12
| |
* | Auto merge of #17192 - mbrubeck:layout, r=pcwaltonbors-servo2017-06-071-11/+28
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Parallel layout optimizations This takes some of the optimizations made to parallel styling in #16971 and applies them to parallel layout. Specifically: * Reduce the chunk size, to increase chances for parallelism on trees with small fan-out. * Reduce allocations by using SmallVec. * Reduce task switching by processing up to one chunk of children within the same rayon task as the parent. This cuts the "Primary Layout Pass" time in **half** on the MySpace page from [tp5n], and on my other real-world test pages it is a small improvement or close to no change. [tp5n]: https://wiki.mozilla.org/Buildbot/Talos/Tests#tp5n_pages_set --- - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes do not require tests because they affect performance only <!-- 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/17192) <!-- Reviewable:end -->
| * Reduce allocations during parallel layoutMatt Brubeck2017-06-061-7/+27
| |
| * Reduce parallel layout chunk size to 16Matt Brubeck2017-06-061-4/+1
| |
* | Implemented the plumbing for paint worklets.Alan Jeffrey2017-06-072-126/+225
| |
* | Auto merge of #17202 - BorisChiou:stylo/animation/mismatched_transform, ↵bors-servo2017-06-061-0/+6
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r=Manishearth,birtles stylo: Bug 1335998 - Handle interpolation and accumulation of mismatched transform lists These are the interdependent patches of Bug 1335998. We want to do interpolation and accumulation for mismatched transform lists, so introduce ComputedOperation::InterpolateMatrix and ComputedOperation::Accumulation. Both arms store the from_list and to_list, and resolve them until we have the layout information. For the Servo part, we haven't implemented how to read the transform lists in layout/fragment.rs, but I think it would be easy. (related issue #13267) --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix [Bug 1335998](https://bugzilla.mozilla.org/show_bug.cgi?id=1335998) - [X] There are tests for these changes <!-- 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/17202) <!-- Reviewable:end -->
| * | Define ComputedOperation::AccmulateMatrix.Boris Chiou2017-06-071-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | If we set the composite operation to accumulate, we may need to accumulate two mismatched transform lists, and then to interpolate them. In order to accumulate two mismatched transform lists, we also need the reference box information, so use the same idea as that for interpolation. i.e. use AccmulateMatrix to store it temporarily, and convert it into matrix later.
| * | Define ComputedOperation::InterpolateMatrix.Boris Chiou2017-06-071-0/+4
| |/ | | | | | | | | | | | | We use this arm to store the interpolated result of two mismatched transform lists, and we resolve it until we know the reference box size (on Gecko side). The conversion from ComputedOperation::InterpolateMatrix to eCSSKeyword_interpolatematrix will be implemented later in this patch series.
* / Make text-shadow reuse Shadow directly.Xidorn Quan2017-06-071-4/+3
|/
* Bump euclid to 0.13 and heapsize to 0.4Bastien Orivel2017-06-051-3/+3
|
* Bump cssparser to 0.13.7Manish Goregaokar2017-06-021-1/+1
|
* Use BorderSideWidth for outline-widthAnthony Ramine2017-06-021-1/+1
|
* Use generics for text spacing propertiesAnthony Ramine2017-06-021-5/+5
|
* Use generics for the line-height propertyAnthony Ramine2017-06-021-4/+5
|
* Update rayon to 0.7.1.Cameron McCormack2017-05-311-1/+1
| | | | To take advantage of nikomatsakis/rayon#348.
* Auto merge of #16317 - eloycoto:issue6799, r=emiliobors-servo2017-05-303-32/+50
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix #6799: set stacking_context_position correctly on fragment_border_iterator Hey, First of all, this is my first PR to Servo project and I'm learning Rust, so sorry if you see something that it's not correct. I did that as best as I know. This PR fix the issue #6799; I tried all the corner cases that I can think about it and always get the right result and the same as other browsers. Related to the build: - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix #6799 In the other hand, I added the test in the cssom folder, is where getBoundingClientRect is defined, so I think that is the best place. I'm sure that the line 122 can be better, but I didn't find a way to transform a Point2D from f32 to px in a easy way. I'm here to listen to your recommendations and fix any issue. Thanks! <!-- 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/16317) <!-- Reviewable:end -->