Граф коммитов

15455 Коммитов

Автор SHA1 Сообщение Дата
Tiaan Louw 7ace11cfe2 Bug 1899011 - In Lab/Oklab, very small a and b values makes the color achromatic r=layout-reviewers,emilio
Using an dynamic epsilon to check for small a and b values.

Differential Revision: https://phabricator.services.mozilla.com/D211665
2024-05-29 14:26:39 +00:00
Emilio Cobos Álvarez 0c79149d0a Bug 1899272 - Defer computation of registered custom color properties if needed. r=dshin,firefox-style-system-reviewers,zrhoffman
This is a bit less complicated than lengths because there's no cycle
possible which could turn the color-scheme declaration invalid afaict.

So it's just that we need to defer the colors when color-scheme is
specified, which is slightly annoying, but maybe not too bad.

I had to tweak a bit the code to defer properties to fix a bug that we
were papering over accidentally. We were using the wrong registration
here:

  https://searchfox.org/mozilla-central/rev/f60bb10a5fe6936f9e9f9e8a90d52c18a0ffd818/servo/components/style/custom_properties.rs#1613

That's the registration for reference.name, not for name, which
papered over some issues. The fix is simple tho, which is storing a
single CustomPropertiesMap.

Differential Revision: https://phabricator.services.mozilla.com/D211860
2024-05-29 14:19:02 +00:00
Emilio Cobos Álvarez 710739a2b0 Bug 1899318 - Fix at-property-animation to account for spec ambiguity. r=firefox-style-system-reviewers,zrhoffman
See https://github.com/w3c/csswg-drafts/issues/10371 for the spec issue.

Differential Revision: https://phabricator.services.mozilla.com/D211871
2024-05-29 10:25:03 +00:00
Zach Hoffman 589054a01b Bug 1899446 - Allow transitioning from a custom property to None. r=firefox-animation-reviewers,firefox-style-system-reviewers,boris
If `getComputedStyle(...).getPropertyValue` is called on a registered
custom property that is used in a transition and that custom property's
registration is removed, `to` can be `None`.

Differential Revision: https://phabricator.services.mozilla.com/D211947
2024-05-29 00:24:39 +00:00
Zach Hoffman 2ee1113256 Bug 1899406 - Check custom property AnimationValue for None before unwrapping. r=boris,firefox-animation-reviewers,firefox-style-system-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D211925
2024-05-28 21:18:10 +00:00
Emilio Cobos Álvarez bf28f82a23 Bug 1899187 - Use cbindgen for column-count. r=firefox-style-system-reviewers,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D211784
2024-05-28 09:37:23 +00:00
Emilio Cobos Álvarez e86daa2b4d Bug 1899187 - Various extra mako simplifications. r=firefox-style-system-reviewers,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D211783
2024-05-28 09:37:22 +00:00
Emilio Cobos Álvarez 686f4b7379 Bug 1899187 - Use cbindgen for initial-letter. r=firefox-style-system-reviewers,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D211782
2024-05-28 09:37:22 +00:00
Emilio Cobos Álvarez b4d60bef91 Bug 1899187 - Use cbindgen for border-spacing. r=firefox-style-system-reviewers,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D211781
2024-05-28 09:37:22 +00:00
Emilio Cobos Álvarez 297dfea1e6 Bug 1899187 - Use a real percentage for -moz-min-font-size-ratio. r=firefox-style-system-reviewers,layout-reviewers,boris
Differential Revision: https://phabricator.services.mozilla.com/D211780
2024-05-28 09:37:21 +00:00
Emilio Cobos Álvarez 4b8f8f4639 Bug 1899126 - Simplify some font-variant code to take advantage of cbindgen and derived implementations. r=jfkthame,layout-reviewers
While at it do fontLanguageOverride to, in order to remove
impl_simple_type_with_conversion.

Differential Revision: https://phabricator.services.mozilla.com/D211761
2024-05-28 09:37:21 +00:00
Jonathan Watt 7b0b5f40c7 Bug 1897756. Implement parsing of CSS 'position-visibility' property. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D210910
2024-05-28 00:52:04 +00:00
Emilio Cobos Álvarez 6887add27f Bug 1899126 - Simplify text-transform representation. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D211731
2024-05-27 17:24:10 +00:00
Emilio Cobos Álvarez ba160c14d5 Bug 1899126 - Derive parsing of grid-auto-flow. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D211730
2024-05-27 17:24:10 +00:00
Emilio Cobos Álvarez e7119c58e6 Bug 1899126 - Derive parse of TextUnderlinePosition. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D211729
2024-05-27 17:24:09 +00:00
Emilio Cobos Álvarez 2c375ea2dd Bug 1899126 - Fix the documentation of #[css(bitflags())]. r=jwatt
The attribute is called validate_mixed because it only applies to mixed
flags.

Differential Revision: https://phabricator.services.mozilla.com/D211732
2024-05-27 17:23:47 +00:00
Emilio Cobos Álvarez 62e49ed870 Bug 1899126 - Simplify TextOverflow handling in the style engine. r=jwatt
No good reason to have different computed / specified representations.

Differential Revision: https://phabricator.services.mozilla.com/D211728
2024-05-27 17:14:32 +00:00
Jonathan Watt 9fe31d66da Bug 1897619. Implement parsing of CSS 'position-anchor' property. r=emilio,firefox-style-system-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D210880
2024-05-27 14:43:11 +00:00
Gregory Pappas dd4a8773bb Bug 1851085 - Remove layout.css.computed-style.shorthands pref r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D211487
2024-05-26 16:47:47 +00:00
Tiaan Louw d1fc08d7c5 Bug 1898468 - When converting legacy rgb(..) to color(srgb ..), ensure the flags are set accordingly r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211341
2024-05-24 07:16:57 +00:00
Sandor Molnar 746dddb873 Backed out changeset 4593c7cfe72e (bug 1898468) for causing wpt failures @ /css/css-properties-values-api/registered-property-computation.html CLOSED TREE 2024-05-24 01:26:11 +03:00
Tiaan Louw 97ed797d2f Bug 1898468 - When converting legacy rgb(..) to color(srgb ..), ensure the flags are set accordingly r=layout-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D211341
2024-05-23 20:54:23 +00:00
Tamas Szentpeteri 4f1c8ce88a Backed out 2 changesets (bug 1897619) for causing wpt failures on position-anchor-basics.html
Backed out changeset d1e736673f03 (bug 1897619)
Backed out changeset 62489eeeb03e (bug 1897619)
2024-05-21 18:53:31 +03:00
Jonathan Watt 3fa7097c7f Bug 1897619. Implement parsing of CSS 'position-anchor' property. r=emilio,firefox-style-system-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D210880
2024-05-21 10:12:22 +00:00
Emilio Cobos Álvarez 0d680476b7 Bug 1897774 - Implement Debug for HeaderSlice manually. r=firefox-style-system-reviewers,tlouw
Otherwise it doesn't show what the slice contains, which makes restyle
logs a bit useless.

Differential Revision: https://phabricator.services.mozilla.com/D210929
2024-05-21 07:53:43 +00:00
Mike Hommey 769f66bc78 Bug 1894142 - Avoid non-local impls in the style crate. r=emilio
Rustc 1.79 warns about them (which --enable-warnings-as-errors turns
into errors).

Differential Revision: https://phabricator.services.mozilla.com/D210574
2024-05-20 19:51:56 +00:00
Tiaan Louw dbd7895df6 Bug 1897092 - Don't clamp hsl/hwb channels for modern syntax colors r=layout-reviewers,emilio
If hsl/hwb colors were created with rcs, then they are assumed to be
modern syntax and thens hould not be gamut mapped/clipped in any way.

Differential Revision: https://phabricator.services.mozilla.com/D210615
2024-05-20 08:37:32 +00:00
Emilio Cobos Álvarez f5fdfec994 Bug 1897605 - Derive more stuff in anchor-positioning types. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D210877
2024-05-19 23:00:53 +00:00
Emilio Cobos Álvarez f9454c2afe Bug 1897361 - Share counter-style / list-style-type representation between Servo and Gecko. r=jwatt
It's not clear to me what is going on there or what caused it. I suspect
it might be:

  https://searchfox.org/mozilla-central/rev/1f46481d6c16f27c989e72b898fd1fddce9f445f/servo/components/style/gecko/values.rs#69

Which is the only potential from_raw_parts caller there. But hard to say
without a regression range.

However I've been wanting to get rid of that code for a while, and
this is a good opportunity for that.

The WithCounterStyleNameOrSymbols stuff isn't super pretty, but it has
only two callers, and something more complicated might require further
refactoring.

Differential Revision: https://phabricator.services.mozilla.com/D210814
2024-05-19 21:24:16 +00:00
Cristian Tuns e65d93ace2 Backed out changeset dffe004546c6 (bug 1897361) for causing reftest failures in /list-1.html CLOSED TREE 2024-05-19 17:09:47 -04:00
Emilio Cobos Álvarez f3519ac0d9 Bug 1897361 - Share counter-style / list-style-type representation between Servo and Gecko. r=jwatt
It's not clear to me what is going on there or what caused it. I suspect
it might be:

  https://searchfox.org/mozilla-central/rev/1f46481d6c16f27c989e72b898fd1fddce9f445f/servo/components/style/gecko/values.rs#69

Which is the only potential from_raw_parts caller there. But hard to say
without a regression range.

However I've been wanting to get rid of that code for a while, and
this is a good opportunity for that.

The WithCounterStyleNameOrSymbols stuff isn't super pretty, but it has
only two callers, and something more complicated might require further
refactoring.

Differential Revision: https://phabricator.services.mozilla.com/D210814
2024-05-19 19:42:38 +00:00
Jonathan Watt 060c48abc9 Bug 1897605. Implement parsing of CSS 'anchor-scope'. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D210874
2024-05-18 16:47:28 +00:00
Jonathan Watt aac256321a Bug 1897405 p1. Implement parsing of CSS 'anchor-name'. r=emilio,devtools-reviewers,firefox-style-system-reviewers,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D210787
2024-05-18 16:47:27 +00:00
Emilio Cobos Álvarez d465f4f516 Bug 1897035 - Remove nightly-only crash that now I understand. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D210816
2024-05-18 12:17:00 +00:00
David Shin 2ca5c3766f Bug 1896380: Don't double-invalidate relative selector dependencies for `:empty` and `:(first|last)-child`. r=firefox-style-system-reviewers,emilio
Such cas is  invalidated out-of-band in `RestyleManager` because
their invalidation can be trivially determined. Don't consider them
again while determining the general-case relative selector invalidation.

Also fix `:only-child` being classified as a simple edge selector, and
prevent them from ending up in the any (`*`) bucket in `InvalidationMap`.

Differential Revision: https://phabricator.services.mozilla.com/D210343
2024-05-17 17:00:43 +00:00
Ting-Yu Lin fb92ee5f64 Bug 1824877 Part 2 - Rename nsHTMLScrollFrame to mozilla::ScrollContainerFrame. r=dholbert
Also, change the ScrollContainerFrame::GetFrameName() to return
"ScrollContainer" instead of "HTMLScroll".

Differential Revision: https://phabricator.services.mozilla.com/D210233
2024-05-15 17:50:48 +00:00
Jonathan Kew 2851ee606a Bug 1891700 - Accept color-mix() in font palette override colors, provided the components used are absolute colors. r=tlouw
Differential Revision: https://phabricator.services.mozilla.com/D208115
2024-05-15 10:45:18 +00:00
Gregory Pappas 82ffaa5566 Bug 1842478 - Remove layout.css.individual-transform.enabled pref r=boris,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D184176
2024-05-14 08:33:44 +00:00
Stanca Serban dd6e430c1b Backed out changeset afa417babef9 (bug 1842478) for causing mochitests failures in test_transitions_per_property.html. CLOSED TREE 2024-05-14 08:00:39 +03:00
Gregory Pappas 87bbc28083 Bug 1842478 - Remove layout.css.individual-transform.enabled pref r=boris,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D184176
2024-05-14 01:20:52 +00:00
Gregory Pappas 262f539b78 Bug 1861958 - Remove layout.css.container-queries.enabled pref r=emilio,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D192207
2024-05-13 21:54:28 +00:00
Narcis Beleuzu a0e0f8ed65 Backed out changeset d062a9fa5bb6 (bug 1861958) for "container" related failures. CLOSED TREE 2024-05-13 23:14:39 +03:00
Gregory Pappas 86fb45470b Bug 1861958 - Remove layout.css.container-queries.enabled pref r=emilio,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D192207
2024-05-13 17:17:52 +00:00
Emilio Cobos Álvarez 2580c7b865 Bug 1894756 - Remove owning_ref. r=firefox-style-system-reviewers,supply-chain-reviewers,zrhoffman,sylvestre
The only use of this type used to be carrying around an owning reference
to a thread-local. However, since bug 1577439 we're leaking the
allocation intentionally, so we can simplify the code to explicitly use
`Box::leak()`, which in turn removes all unsafe usage around these, and
allows us to drop the owning_ref dependency altogether.

Differential Revision: https://phabricator.services.mozilla.com/D209912
2024-05-10 08:15:04 +00:00
Noemi Erli beb4579b25 Backed out changeset 4713c801a53d (bug 1894756) for causing valgrind bustages CLOSED TREE 2024-05-10 04:37:33 +03:00
Emilio Cobos Álvarez 1ebcef86f4 Bug 1894756 - Remove owning_ref. r=firefox-style-system-reviewers,supply-chain-reviewers,zrhoffman,sylvestre
The only use of this type used to be carrying around an owning reference
to a thread-local. However, since bug 1577439 we're leaking the
allocation intentionally, so we can simplify the code to explicitly use
`Box::leak()`, which in turn removes all unsafe usage around these, and
allows us to drop the owning_ref dependency altogether.

Differential Revision: https://phabricator.services.mozilla.com/D209912
2024-05-09 17:11:52 +00:00
Emilio Cobos Álvarez 4d5aee49f3 Bug 1281158 - Parse alternative text for the content property. r=dshin
This doesn't yet expose it to a11y but that will be done by the a11y
folks, since this blocks some of the a11y interop test-cases.

Modify the tests to not hit the network, and make -moz-alt-content not
exposed to content (we only need it for UA stylesheets).

Differential Revision: https://phabricator.services.mozilla.com/D209690
2024-05-08 16:06:47 +00:00
Emilio Cobos Álvarez dc9b47aecf Bug 1281158 - Improve interaction of ThinVec in the style system. r=dshin
This is the logical continuation of bug 1121792. This improves on the
existing support by totally removing all the manual nsTArray bindings,
which have always been a bit clumsy.

This is a prerequisite for bug 1281158 because I want to use ThinVec to
avoid a few extra heap allocations in the computed values of the Content
property.

Differential Revision: https://phabricator.services.mozilla.com/D209689
2024-05-08 16:06:46 +00:00
David Shin dd2d1fcb2e Bug 1892089: Support font-relative line-height units in SVG. r=longsonr,emilio
Differential Revision: https://phabricator.services.mozilla.com/D207870
2024-05-07 20:35:08 +00:00
Emilio Cobos Álvarez fb06f366ae Bug 1889429 - Remove most native tree code. r=mac-reviewers,desktop-theme-reviewers,places-reviewers,win-reviewers,dao,handyman,mstange
Most of this code is already dead. The native appearance on macOS
doesn't work on dark mode, and on Windows and Linux we are already
overriding it.

Add a first-column tree property to be able to align the inner borders
on macOS properly.

Differential Revision: https://phabricator.services.mozilla.com/D206526
2024-05-06 19:22:35 +00:00