mirror of
https://github.com/servo/servo.git
synced 2025-10-04 02:29:12 +01:00
style: Remove StyleFontSize enum from nsStyleConsts.h.
Differential Revision: https://phabricator.services.mozilla.com/D77511
This commit is contained in:
parent
60f4fedcbf
commit
5af0d7ca7c
6 changed files with 56 additions and 79 deletions
|
@ -101,7 +101,7 @@ pub struct FontSize {
|
|||
pub size: NonNegativeLength,
|
||||
/// If derived from a keyword, the keyword and additional transformations applied to it
|
||||
#[css(skip)]
|
||||
pub keyword_info: Option<KeywordInfo>,
|
||||
pub keyword_info: KeywordInfo,
|
||||
}
|
||||
|
||||
impl FontWeight {
|
||||
|
@ -170,7 +170,7 @@ impl FontSize {
|
|||
pub fn medium() -> Self {
|
||||
Self {
|
||||
size: NonNegative(Length::new(specified::FONT_MEDIUM_PX as CSSFloat)),
|
||||
keyword_info: Some(KeywordInfo::medium()),
|
||||
keyword_info: KeywordInfo::medium(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -187,7 +187,7 @@ impl ToAnimatedValue for FontSize {
|
|||
fn from_animated_value(animated: Self::AnimatedValue) -> Self {
|
||||
FontSize {
|
||||
size: NonNegative(animated.clamp_to_non_negative()),
|
||||
keyword_info: None,
|
||||
keyword_info: KeywordInfo::none(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue