From 6f9855a8c39bea36a06496a34a9083a12c93308b Mon Sep 17 00:00:00 2001 From: Yip Coekjan <69834864+Coekjan@users.noreply.github.com> Date: Fri, 14 Jun 2024 00:57:34 +0800 Subject: Make symbols callable like functions & migrate callable accents to callable symbols (#4299) Co-authored-by: Laurenz --- docs/src/lib.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs') diff --git a/docs/src/lib.rs b/docs/src/lib.rs index 8af7dc0d..231fe97c 100644 --- a/docs/src/lib.rs +++ b/docs/src/lib.rs @@ -661,15 +661,15 @@ fn symbols_model(resolver: &dyn Resolver, group: &GroupData) -> SymbolsModel { for (variant, c) in symbol.variants() { let shorthand = |list: &[(&'static str, char)]| { - list.iter().copied().find(|&(_, x)| x == c).map(|(s, _)| s) + list.iter().copied().find(|&(_, x)| x == c.char()).map(|(s, _)| s) }; list.push(SymbolModel { name: complete(variant), markup_shorthand: shorthand(typst::syntax::ast::Shorthand::MARKUP_LIST), math_shorthand: shorthand(typst::syntax::ast::Shorthand::MATH_LIST), - codepoint: c as u32, - accent: typst::symbols::Symbol::combining_accent(c).is_some(), + codepoint: c.char() as _, + accent: typst::math::Accent::combine(c.char()).is_some(), alternates: symbol .variants() .filter(|(other, _)| other != &variant) -- cgit v1.2.3