mirror of
https://github.com/servo/servo.git
synced 2025-08-25 15:18:22 +01:00
Stylo: Bug 1350175 - Support getting line / column number of CSS rules
Fix font_cache_thread test
This commit is contained in:
parent
58253f545b
commit
bc156cfe1c
12 changed files with 151 additions and 56 deletions
|
@ -10,6 +10,7 @@ path = "lib.rs"
|
|||
doctest = false
|
||||
|
||||
[dependencies]
|
||||
cssparser = "0.13.3"
|
||||
gfx = {path = "../../../components/gfx"}
|
||||
ipc-channel = "0.7"
|
||||
style = {path = "../../../components/style"}
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use cssparser::SourceLocation;
|
||||
use gfx::font_cache_thread::FontCacheThread;
|
||||
use ipc_channel::ipc;
|
||||
use style::computed_values::font_family::FamilyName;
|
||||
|
@ -23,6 +24,10 @@ fn test_local_web_font() {
|
|||
let font_face_rule = FontFaceRuleData {
|
||||
family: Some(family_name.clone()),
|
||||
sources: Some(vec![Source::Local(variant_name)]),
|
||||
source_location: SourceLocation {
|
||||
line: 0,
|
||||
column: 0,
|
||||
},
|
||||
};
|
||||
|
||||
font_cache_thread.add_web_font(
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
extern crate cssparser;
|
||||
extern crate gfx;
|
||||
extern crate ipc_channel;
|
||||
extern crate style;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue