aboutsummaryrefslogtreecommitdiffstats
path: root/components/gfx/platform
diff options
context:
space:
mode:
authorSimon Sapin <simon.sapin@exyr.org>2018-11-01 23:45:06 +0100
committerSimon Sapin <simon.sapin@exyr.org>2018-11-06 15:26:02 +0100
commit45f7199eee82c66637ec68287eafa40a651001c4 (patch)
tree8c0802f4ac7b89c2ce4d73063c8f65b9ee5face9 /components/gfx/platform
parent86f148fb97601413c0d983f21b760d973ade7a75 (diff)
downloadservo-45f7199eee82c66637ec68287eafa40a651001c4.tar.gz
servo-45f7199eee82c66637ec68287eafa40a651001c4.zip
`cargo fix --edition`
Diffstat (limited to 'components/gfx/platform')
-rw-r--r--components/gfx/platform/freetype/android/font_list.rs2
-rw-r--r--components/gfx/platform/freetype/font.rs12
-rw-r--r--components/gfx/platform/freetype/font_list.rs2
-rw-r--r--components/gfx/platform/macos/font.rs10
-rw-r--r--components/gfx/platform/macos/font_list.rs2
-rw-r--r--components/gfx/platform/mod.rs8
-rw-r--r--components/gfx/platform/windows/font.rs12
-rw-r--r--components/gfx/platform/windows/font_list.rs2
-rw-r--r--components/gfx/platform/windows/font_template.rs2
9 files changed, 26 insertions, 26 deletions
diff --git a/components/gfx/platform/freetype/android/font_list.rs b/components/gfx/platform/freetype/android/font_list.rs
index 9cf9c512e09..940283c55c5 100644
--- a/components/gfx/platform/freetype/android/font_list.rs
+++ b/components/gfx/platform/freetype/android/font_list.rs
@@ -6,7 +6,7 @@ use std::cell::RefCell;
use std::fs::File;
use std::io::{self, Read};
use std::path::Path;
-use text::util::is_cjk;
+use crate::text::util::is_cjk;
use ucd::{Codepoint, UnicodeBlock};
use xml5ever::Attribute;
use xml5ever::driver::parse_document;
diff --git a/components/gfx/platform/freetype/font.rs b/components/gfx/platform/freetype/font.rs
index c774728fef0..b3762b26fe7 100644
--- a/components/gfx/platform/freetype/font.rs
+++ b/components/gfx/platform/freetype/font.rs
@@ -3,8 +3,8 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use app_units::Au;
-use font::{FontHandleMethods, FontMetrics, FontTableMethods};
-use font::{FontTableTag, FractionalPixel, GPOS, GSUB, KERN};
+use crate::font::{FontHandleMethods, FontMetrics, FontTableMethods};
+use crate::font::{FontTableTag, FractionalPixel, GPOS, GSUB, KERN};
use freetype::freetype::{FT_Done_Face, FT_New_Face, FT_New_Memory_Face};
use freetype::freetype::{FT_F26Dot6, FT_Face, FT_FaceRec};
use freetype::freetype::{FT_Get_Char_Index, FT_Get_Postscript_Name};
@@ -16,8 +16,8 @@ use freetype::freetype::{FT_SizeRec, FT_Size_Metrics, FT_UInt, FT_Vector};
use freetype::freetype::FT_Sfnt_Tag;
use freetype::succeeded;
use freetype::tt_os2::TT_OS2;
-use platform::font_context::FontContextHandle;
-use platform::font_template::FontTemplateData;
+use crate::platform::font_context::FontContextHandle;
+use crate::platform::font_template::FontTemplateData;
use servo_atoms::Atom;
use std::{mem, ptr};
use std::ffi::CString;
@@ -27,8 +27,8 @@ use style::computed_values::font_stretch::T as FontStretch;
use style::computed_values::font_weight::T as FontWeight;
use style::values::computed::font::FontStyle;
use super::c_str_to_string;
-use text::glyph::GlyphId;
-use text::util::fixed_to_float;
+use crate::text::glyph::GlyphId;
+use crate::text::util::fixed_to_float;
// This constant is not present in the freetype
// bindings due to bindgen not handling the way
diff --git a/components/gfx/platform/freetype/font_list.rs b/components/gfx/platform/freetype/font_list.rs
index e1ef486fa43..378f2f1944c 100644
--- a/components/gfx/platform/freetype/font_list.rs
+++ b/components/gfx/platform/freetype/font_list.rs
@@ -13,7 +13,7 @@ use libc::{c_char, c_int};
use std::ffi::CString;
use std::ptr;
use super::c_str_to_string;
-use text::util::is_cjk;
+use crate::text::util::is_cjk;
static FC_FAMILY: &'static [u8] = b"family\0";
static FC_FILE: &'static [u8] = b"file\0";
diff --git a/components/gfx/platform/macos/font.rs b/components/gfx/platform/macos/font.rs
index dca2175c5ab..6e0bb05c1ef 100644
--- a/components/gfx/platform/macos/font.rs
+++ b/components/gfx/platform/macos/font.rs
@@ -13,16 +13,16 @@ use core_graphics::geometry::CGRect;
use core_text::font::CTFont;
use core_text::font_descriptor::{SymbolicTraitAccessors, TraitAccessors};
use core_text::font_descriptor::kCTFontDefaultOrientation;
-use font::{FontHandleMethods, FontMetrics, FontTableMethods, FontTableTag, FractionalPixel};
-use font::{GPOS, GSUB, KERN};
-use platform::font_template::FontTemplateData;
-use platform::macos::font_context::FontContextHandle;
+use crate::font::{FontHandleMethods, FontMetrics, FontTableMethods, FontTableTag, FractionalPixel};
+use crate::font::{GPOS, GSUB, KERN};
+use crate::platform::font_template::FontTemplateData;
+use crate::platform::macos::font_context::FontContextHandle;
use servo_atoms::Atom;
use std::{fmt, ptr};
use std::ops::Range;
use std::sync::Arc;
use style::values::computed::font::{FontStretch, FontStyle, FontWeight};
-use text::glyph::GlyphId;
+use crate::text::glyph::GlyphId;
const KERN_PAIR_LEN: usize = 6;
diff --git a/components/gfx/platform/macos/font_list.rs b/components/gfx/platform/macos/font_list.rs
index 44412771bee..624d9b9a4a9 100644
--- a/components/gfx/platform/macos/font_list.rs
+++ b/components/gfx/platform/macos/font_list.rs
@@ -3,7 +3,7 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use core_text;
-use text::util::unicode_plane;
+use crate::text::util::unicode_plane;
use ucd::{Codepoint, UnicodeBlock};
pub fn for_each_available_family<F>(mut callback: F)
diff --git a/components/gfx/platform/mod.rs b/components/gfx/platform/mod.rs
index 106b232e308..a14abaafe47 100644
--- a/components/gfx/platform/mod.rs
+++ b/components/gfx/platform/mod.rs
@@ -3,16 +3,16 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#[cfg(any(target_os = "linux", target_os = "android"))]
-pub use platform::freetype::{font, font_context};
+pub use crate::platform::freetype::{font, font_context};
#[cfg(any(target_os = "linux", target_os = "android"))]
-pub use platform::freetype::{font_list, font_template};
+pub use crate::platform::freetype::{font_list, font_template};
#[cfg(target_os = "windows")]
-pub use platform::windows::{font, font_context, font_list, font_template};
+pub use crate::platform::windows::{font, font_context, font_list, font_template};
#[cfg(target_os = "macos")]
-pub use platform::macos::{font, font_context, font_list, font_template};
+pub use crate::platform::macos::{font, font_context, font_list, font_template};
#[cfg(any(target_os = "linux", target_os = "android"))]
mod freetype {
diff --git a/components/gfx/platform/windows/font.rs b/components/gfx/platform/windows/font.rs
index 26490d9c52c..d9f80de1103 100644
--- a/components/gfx/platform/windows/font.rs
+++ b/components/gfx/platform/windows/font.rs
@@ -10,11 +10,11 @@ use app_units::Au;
use dwrote;
use dwrote::{Font, FontFace, FontFile};
use dwrote::{FontStretch, FontStyle};
-use font::{FontHandleMethods, FontMetrics, FontTableMethods};
-use font::{FontTableTag, FractionalPixel};
-use platform::font_template::FontTemplateData;
-use platform::windows::font_context::FontContextHandle;
-use platform::windows::font_list::font_from_atom;
+use crate::font::{FontHandleMethods, FontMetrics, FontTableMethods};
+use crate::font::{FontTableTag, FractionalPixel};
+use crate::platform::font_template::FontTemplateData;
+use crate::platform::windows::font_context::FontContextHandle;
+use crate::platform::windows::font_list::font_from_atom;
use servo_atoms::Atom;
use std::fmt;
use std::ops::Deref;
@@ -25,7 +25,7 @@ use style::values::computed::font::FontStyle as StyleFontStyle;
use style::values::generics::NonNegative;
use style::values::generics::font::FontStyle as GenericFontStyle;
use style::values::specified::font::FontStretchKeyword;
-use text::glyph::GlyphId;
+use crate::text::glyph::GlyphId;
use truetype;
// 1em = 12pt = 16px, assuming 72 points per inch and 96 px per inch
diff --git a/components/gfx/platform/windows/font_list.rs b/components/gfx/platform/windows/font_list.rs
index b2d73b3db5c..44a3f3704d7 100644
--- a/components/gfx/platform/windows/font_list.rs
+++ b/components/gfx/platform/windows/font_list.rs
@@ -7,7 +7,7 @@ use servo_atoms::Atom;
use std::collections::HashMap;
use std::sync::Mutex;
use std::sync::atomic::{Ordering, AtomicUsize};
-use text::util::unicode_plane;
+use crate::text::util::unicode_plane;
use ucd::{Codepoint, UnicodeBlock};
lazy_static! {
diff --git a/components/gfx/platform/windows/font_template.rs b/components/gfx/platform/windows/font_template.rs
index 53eae0347fd..49deeee736f 100644
--- a/components/gfx/platform/windows/font_template.rs
+++ b/components/gfx/platform/windows/font_template.rs
@@ -2,7 +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 platform::windows::font_list::{descriptor_from_atom, font_from_atom};
+use crate::platform::windows::font_list::{descriptor_from_atom, font_from_atom};
use servo_atoms::Atom;
use std::fmt;
use std::io;