From 264a7dedd42e27cd9e604037640cf0594b2ec46b Mon Sep 17 00:00:00 2001 From: Laurenz Date: Fri, 19 Mar 2021 17:57:31 +0100 Subject: =?UTF-8?q?Scheduled=20maintenance=20=F0=9F=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - New naming scheme - TextNode instead of NodeText - CallExpr instead of ExprCall - ... - Less glob imports - Removes Value::Args variant - Removes prelude - Renames Layouted to Fragment - Moves font into env - Moves shaping into layout - Moves frame into separate module --- src/library/font.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/library/font.rs') diff --git a/src/library/font.rs b/src/library/font.rs index ecc15d96..00fd0e81 100644 --- a/src/library/font.rs +++ b/src/library/font.rs @@ -1,7 +1,6 @@ use fontdock::{FontStretch, FontStyle, FontWeight}; use super::*; -use crate::shaping::VerticalFontMetric; /// `font`: Configure the font. /// @@ -55,7 +54,7 @@ use crate::shaping::VerticalFontMetric; /// - `x-height` /// - `baseline` /// - `descender` -pub fn font(ctx: &mut EvalContext, args: &mut ValueArgs) -> Value { +pub fn font(ctx: &mut EvalContext, args: &mut FuncArgs) -> Value { let size = args.find::(ctx); let list: Vec<_> = args.filter::(ctx).map(|f| f.to_string()).collect(); let style = args.get(ctx, "style"); @@ -66,7 +65,7 @@ pub fn font(ctx: &mut EvalContext, args: &mut ValueArgs) -> Value { let serif = args.get(ctx, "serif"); let sans_serif = args.get(ctx, "sans-serif"); let monospace = args.get(ctx, "monospace"); - let body = args.find::(ctx); + let body = args.find::(ctx); Value::template("font", move |ctx| { let snapshot = ctx.state.clone(); -- cgit v1.2.3