The interface in #8210 allows us to create custom instances of CSS parse error reporters. We should write a test in tests/unit/style/stylesheets.rs that tries to parse invalid CSS and have a custom reporter that asserts the errors that are reported.
Code: tests/unit/style/stylesheets.rs, http://doc.servo.org/style_traits/trait.ParseErrorReporter.htmlFixes#8842
Source-Repo: https://github.com/servo/servo
Source-Revision: 4c4df37a128d2848f13fc2e5ebd4d69a4db8c483
This commits updates rust-selectors to use the generic parser, and as
such it moves the element state into the style crate.
Source-Repo: https://github.com/servo/servo
Source-Revision: ae20f2556bc7807b39b6649ac1f738644abcc26a
This is part of slimming down the dependencies of geckolib.
Source-Repo: https://github.com/servo/servo
Source-Revision: 3680e82cab766a412a969a21c0cdff0c7f97d7bc
This makes the initial download for skia go from a 300 MB git repository to a 5 MB tarball. This should help with issues like #6132 and #7687.
Fix https://github.com/servo/skia/issues/70
This builds, but the at the moment causes a number of tidy errors for duplicated crates.
Source-Repo: https://github.com/servo/servo
Source-Revision: 8b95d7b8d860ec4c0834192083361a9fb78ddbeb
Updated string_cache to 0.2, and updated the dependencies that depend on string_cache.
Removed references to string_cache_plugin.
Import atom! and ns! from string_cache.
Replaced ns!("") by ns!().
Replaced ns!(XML) and co by ns!(xml) and co.
Replaced Atom::from_slice by Atom::from.
Replaced atom.as_slice() by &*atom.
r? @SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: 188fa9378c103093f1f8dac24bff0d9d237fd2bc
Stylesheets for `HTMLLinkElement`s are now loaded by the resource task, triggered by the element in question. Stylesheets are owned by the elements they're associated with, which can be `HTMLStyleElement`, `HTMLLinkElement`, and `HTMLMetaElement` (for `<meta name="viewport">).
Additionally, the quirks mode stylesheet (just as the user and user agent stylesheets a couple of commits ago), is implemented as a lazy static, loaded once per process and shared between all documents.
This all has various nice consequences:
- Stylesheet loading becomes a non-blocking operation.
- Stylesheets are removed when the element they're associated with is removed from the document.
- It'll be possible to implement the CSSOM APIs that require direct access to the stylesheets (i.e., ~ all of them).
- Various subtle correctness issues are fixed.
One piece of interesting follow-up work would be to move parsing of external stylesheets to the resource task, too. Right now, it happens in the link element once loading is complete, so blocks the script task. Moving it to the resource task would probably be fairly straight-forward as it doesn't require access to any external state.
Depends on #7979 because without that loading stylesheets asynchronously breaks lots of content.
Source-Repo: https://github.com/servo/servo
Source-Revision: 7ff3a17524e0e703e3ac279441729c185444be24
Translate <meta name=viewport> as according to [CSS Device Adaption § 9](http://dev.w3.org/csswg/css-device-adapt/#viewport-meta)
Note: as the PR currently stands, handling `<meta name=viewport>` elements always occurs. This is probably not desired for some contexts (e.g. desktop), but I'm unsure of how to conditionally handle elements based on that.
Source-Repo: https://github.com/servo/servo
Source-Revision: a7743052cad0387733c90940fa91733ede32772c
Thanks to @Jinwoo-Song for the original commit, which I just rebased and cleaned up. Fixes#6237.
Source-Repo: https://github.com/servo/servo
Source-Revision: 6a12f00d6d392651bae10365b4c806f36d704b21
This checks every .toml file for an asterisk and prints an error if found.
Source-Repo: https://github.com/servo/servo
Source-Revision: 58e9bc6583b6ebbeb27e3b28a6b271ee48cd695a
Sorry for not doing it yesterday, I couldn't.
cc @metajack @SimonSapin
Source-Repo: https://github.com/servo/servo
Source-Revision: 4ebb95ccd8e034007eacb447a054919ef4af2bf7
This property determines the background positioning area, that is the position of
the origin of an image specified using the 'background-image' CSS property.
'background-origin' is ignored when background-attachment is fixed.
Spec: http://dev.w3.org/csswg/css-backgrounds-3/#background-originFixes#6045.
r? @pcwalton
cc @yichoi
Source-Repo: https://github.com/servo/servo
Source-Revision: 8c402728247c73268df9389948ee9a9d9e4063b2
Spec: http://dev.w3.org/csswg/css-device-adapt/
Currently, the actual viewport is used by the layout task as part of the reflow, and the compositor uses the zoom constraints. I'm not sure if anywhere else currently needs access to the constraints (i.e. there's no CSSOM as far as I can tell).
I did not implement sections 9 (viewport <META>) or 10 (handling 'auto' for 'zoom').
Source-Repo: https://github.com/servo/servo
Source-Revision: ccf1e6b9a701cf4ff010fa1f1b4ba9d656d962af
On my laptop, running `./mach test-unit` goes from about 11 minutes to 22 seconds, when run after `./mach build`.
Fix#5291.
Source-Repo: https://github.com/servo/servo
Source-Revision: 017d1053617f6769d7f355e4a97d52ae67e53d1c
--HG--
rename : servo/components/net/test.jpeg => servo/tests/unit/net/test.jpeg
rename : servo/components/script/tests.rs => servo/tests/unit/script/size_of.rs