summaryrefslogtreecommitdiff
path: root/src/library/math
diff options
context:
space:
mode:
Diffstat (limited to 'src/library/math')
-rw-r--r--src/library/math/mod.rs10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/library/math/mod.rs b/src/library/math/mod.rs
index ad01f28a..5656890d 100644
--- a/src/library/math/mod.rs
+++ b/src/library/math/mod.rs
@@ -15,11 +15,9 @@ pub struct MathNode {
#[node(showable)]
impl MathNode {
- /// The raw text's font family. Just the normal text family if `auto`.
+ /// The math font family.
#[property(referenced)]
- pub const FAMILY: Smart<FontFamily> =
- Smart::Custom(FontFamily::new("Latin Modern Math"));
-
+ pub const FAMILY: FontFamily = FontFamily::new("Latin Modern Math");
/// The spacing above display math.
#[property(resolve, shorthand(around))]
pub const ABOVE: Option<BlockSpacing> = Some(Ratio::one().into());
@@ -62,9 +60,7 @@ impl Show for MathNode {
mut realized: Content,
) -> TypResult<Content> {
let mut map = StyleMap::new();
- if let Smart::Custom(family) = styles.get(Self::FAMILY) {
- map.set_family(family.clone(), styles);
- }
+ map.set_family(styles.get(Self::FAMILY).clone(), styles);
if self.display {
realized = realized.spaced(styles.get(Self::ABOVE), styles.get(Self::BELOW));