mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
fonts: Add MallocSizeOf
implementation for FontContext
(#32206)
* fonts: Add `MallocSizeOf` implementation for `FontContext` Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com> * android: remove unused imports in font_list.rs Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> --------- Signed-off-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
This commit is contained in:
parent
160c7c0b0f
commit
1c9120c293
13 changed files with 119 additions and 25 deletions
|
@ -7,6 +7,7 @@ use std::io::Read;
|
|||
use std::path::Path;
|
||||
|
||||
use log::debug;
|
||||
use malloc_size_of_derive::MallocSizeOf;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use style::Atom;
|
||||
use ucd::{Codepoint, UnicodeBlock};
|
||||
|
@ -20,7 +21,7 @@ use crate::text::util::unicode_plane;
|
|||
/// An identifier for a local font on a MacOS system. These values comes from the CoreText
|
||||
/// CTFontCollection. Note that `path` here is required. We do not load fonts that do not
|
||||
/// have paths.
|
||||
#[derive(Clone, Debug, Deserialize, Eq, Hash, PartialEq, Serialize)]
|
||||
#[derive(Clone, Debug, Deserialize, Eq, Hash, MallocSizeOf, PartialEq, Serialize)]
|
||||
pub struct LocalFontIdentifier {
|
||||
pub postscript_name: Atom,
|
||||
pub path: Atom,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue