mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Derive Debug on FontGroup and its components
This commit is contained in:
parent
3d078f7c64
commit
c5ede5851e
10 changed files with 16 additions and 8 deletions
|
@ -85,6 +85,7 @@ pub struct FontMetrics {
|
|||
|
||||
pub type SpecifiedFontStyle = FontStyle;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Font {
|
||||
pub handle: FontHandle,
|
||||
pub metrics: FontMetrics,
|
||||
|
@ -111,7 +112,7 @@ bitflags! {
|
|||
}
|
||||
|
||||
/// Various options that control text shaping.
|
||||
#[derive(Clone, Eq, PartialEq, Hash, Copy)]
|
||||
#[derive(Clone, Eq, PartialEq, Hash, Copy, Debug)]
|
||||
pub struct ShapingOptions {
|
||||
/// Spacing to add between each letter. Corresponds to the CSS 2.1 `letter-spacing` property.
|
||||
/// NB: You will probably want to set the `IGNORE_LIGATURES_SHAPING_FLAG` if this is non-null.
|
||||
|
@ -125,7 +126,7 @@ pub struct ShapingOptions {
|
|||
}
|
||||
|
||||
/// An entry in the shape cache.
|
||||
#[derive(Clone, Eq, PartialEq, Hash)]
|
||||
#[derive(Clone, Eq, PartialEq, Hash, Debug)]
|
||||
pub struct ShapeCacheEntry {
|
||||
text: String,
|
||||
options: ShapingOptions,
|
||||
|
@ -206,6 +207,7 @@ impl Font {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct FontGroup {
|
||||
pub fonts: SmallVec<[Rc<RefCell<Font>>; 8]>,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue