diff options
| author | Laurenz <laurmaedje@gmail.com> | 2020-02-03 10:37:50 +0100 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2020-02-03 10:37:50 +0100 |
| commit | 40ea35cbe7482ce04096c4d63a848c8601cc1848 (patch) | |
| tree | 080a5727ba552ee4b2bf750208e5c243c1e195ef /src/syntax/func | |
| parent | 20fb4e7c379b79b84d9884d5f2c89d781c5793e2 (diff) | |
Upgrade to new toddle interface 🐳
Diffstat (limited to 'src/syntax/func')
| -rw-r--r-- | src/syntax/func/values.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/syntax/func/values.rs b/src/syntax/func/values.rs index 515d6a43..e4a0b2ad 100644 --- a/src/syntax/func/values.rs +++ b/src/syntax/func/values.rs @@ -145,7 +145,7 @@ impl Value for FontStyle { type Output = Self; fn parse(expr: Spanned<Expr>) -> Result<Self::Output, Error> { - FontStyle::from_str(Ident::parse(expr)?.as_str()) + FontStyle::from_name(Ident::parse(expr)?.as_str()) .ok_or_else(|| err!("invalid font style")) } } @@ -166,7 +166,7 @@ impl Value for FontWeight { } } Expr::Ident(id) => { - FontWeight::from_str(id.as_str()) + FontWeight::from_name(id.as_str()) .ok_or_else(|| err!("invalid font weight")) .map(|weight| (weight, false)) } @@ -180,7 +180,7 @@ impl Value for Paper { type Output = Self; fn parse(expr: Spanned<Expr>) -> Result<Self::Output, Error> { - Paper::from_str(Ident::parse(expr)?.as_str()) + Paper::from_name(Ident::parse(expr)?.as_str()) .ok_or_else(|| err!("invalid paper type")) } } |
