From 394ba50fa612c36d7443094e21430aed6f533149 Mon Sep 17 00:00:00 2001 From: Yip Coekjan <69834864+Coekjan@users.noreply.github.com> Date: Sat, 6 Jul 2024 21:44:14 +0800 Subject: [PATCH] Rename `notes.*` to `note.*` & Add some music symbols (#4488) --- crates/typst/src/symbols/sym.rs | 46 ++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) diff --git a/crates/typst/src/symbols/sym.rs b/crates/typst/src/symbols/sym.rs index 1dec0039e..802b9a7a7 100644 --- a/crates/typst/src/symbols/sym.rs +++ b/crates/typst/src/symbols/sym.rs @@ -480,7 +480,6 @@ pub(crate) const SYM: &[(&str, Symbol)] = symbols! { checkmark: ['✓', light: '🗸', heavy: '✔'], crossmark: ['✗', heavy: '✘'], floral: ['❦', l: '☙', r: '❧'], - notes: [up: '🎜', down: '🎝'], refmark: '※', servicemark: '℠', maltese: '✠', @@ -495,6 +494,51 @@ pub(crate) const SYM: &[(&str, Symbol)] = symbols! { spade.stroked: '♤', ], + // Music. + note: [ + up: '🎜', + down: '🎝', + whole: '𝅝', + half: '𝅗𝅥', + quarter: '𝅘𝅥', + quarter.alt: '♩', + eighth: '𝅘𝅥𝅮', + eighth.alt: '♪', + eighth.beamed: '♫', + sixteenth: '𝅘𝅥𝅯', + sixteenth.beamed: '♬', + grace: '𝆕', + grace.slash: '𝆔', + ], + rest: [ + whole: '𝄻', + multiple: '𝄺', + multiple.measure: '𝄩', + half: '𝄼', + quarter: '𝄽', + eighth: '𝄾', + sixteenth: '𝄿', + ], + natural: [ + '♮', + t: '𝄮', + b: '𝄯', + ], + flat: [ + '♭', + t: '𝄬', + b: '𝄭', + double: '𝄫', + quarter: '𝄳', + ], + sharp: [ + '♯', + t: '𝄰', + b: '𝄱', + double: '𝄪', + quarter: '𝄲', + ], + // Shapes. bullet: '•', circle: [