зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1646811 - servo: Implement CanvasRenderingContext2D.font property.
Depends on D80237 Differential Revision: https://phabricator.services.mozilla.com/D80238
This commit is contained in:
Родитель
27f264de00
Коммит
464c001324
|
@ -2602,7 +2602,7 @@ pub mod style_structs {
|
|||
|
||||
% for style_struct in data.active_style_structs():
|
||||
% if style_struct.name == "Font":
|
||||
#[derive(Clone, Debug, MallocSizeOf)]
|
||||
#[derive(Clone, Debug, MallocSizeOf, Serialize, Deserialize)]
|
||||
% else:
|
||||
#[derive(Clone, Debug, MallocSizeOf, PartialEq)]
|
||||
% endif
|
||||
|
|
|
@ -80,6 +80,8 @@ impl ToAnimatedValue for FontWeight {
|
|||
ToAnimatedZero,
|
||||
ToCss,
|
||||
ToResolvedValue,
|
||||
Serialize,
|
||||
Deserialize,
|
||||
)]
|
||||
/// The computed value of font-size
|
||||
pub struct FontSize {
|
||||
|
@ -179,7 +181,7 @@ impl ToAnimatedValue for FontSize {
|
|||
}
|
||||
|
||||
#[derive(Clone, Debug, Eq, PartialEq, ToComputedValue, ToResolvedValue)]
|
||||
#[cfg_attr(feature = "servo", derive(Hash, MallocSizeOf))]
|
||||
#[cfg_attr(feature = "servo", derive(Hash, MallocSizeOf, Serialize, Deserialize))]
|
||||
/// Specifies a prioritized list of font family names or generic family names.
|
||||
pub struct FontFamily {
|
||||
/// The actual list of family names.
|
||||
|
@ -445,7 +447,17 @@ impl SingleFontFamily {
|
|||
|
||||
#[cfg(feature = "servo")]
|
||||
#[derive(
|
||||
Clone, Debug, Eq, Hash, MallocSizeOf, PartialEq, ToComputedValue, ToResolvedValue, ToShmem,
|
||||
Clone,
|
||||
Debug,
|
||||
Eq,
|
||||
Hash,
|
||||
MallocSizeOf,
|
||||
PartialEq,
|
||||
ToComputedValue,
|
||||
ToResolvedValue,
|
||||
ToShmem,
|
||||
Serialize,
|
||||
Deserialize,
|
||||
)]
|
||||
/// A list of SingleFontFamily
|
||||
pub struct FontFamilyList(Box<[SingleFontFamily]>);
|
||||
|
|
|
@ -498,6 +498,8 @@ impl ToComputedValue for FontStretch {
|
|||
ToCss,
|
||||
ToResolvedValue,
|
||||
ToShmem,
|
||||
Serialize,
|
||||
Deserialize,
|
||||
)]
|
||||
#[allow(missing_docs)]
|
||||
#[repr(u8)]
|
||||
|
@ -545,6 +547,8 @@ impl Default for FontSizeKeyword {
|
|||
ToCss,
|
||||
ToResolvedValue,
|
||||
ToShmem,
|
||||
Serialize,
|
||||
Deserialize,
|
||||
)]
|
||||
/// Additional information for keyword-derived font sizes.
|
||||
pub struct KeywordInfo {
|
||||
|
|
Загрузка…
Ссылка в новой задаче