Fix merge: Shape::math for WordArt, fmt

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
vangel76andClaude Sonnet 5.5 committed 2026-11-02 20:07:54 +01:00
1 parent 0d1296e532
commit f8a764f20c
2 files changed
+4 -1

No files matched your search

+1
View File
@@ -190,6 +190,7 @@ fn insert_word_art(s: &mut Session, p: &Json) -> Result<Json> {
line: Color::Auto,
text: text.clone(),
format: ShapeFormat { no_line: true, align: Some(ShapeTextAlign::Center), anchor: Some(ShapeTextAnchor::Middle), ..Default::default() },
math: Default::default(),
};
apply("insert.wordArt", &mut shape, Some(style), p)?;
// Default box: the longest line at the font size (about 0.62 em per character) plus padding.
+3 -1
View File
@@ -126,7 +126,9 @@ pub fn open_action(sh: &Sheet, o: ObjRef) -> OpenAction {
match o.kind {
ObjKind::Chart => OpenAction::FormatChart(o.id),
ObjKind::Equation => OpenAction::EditEquation(o.id),
ObjKind::Shape if sh.shapes.iter().any(|s| s.id == o.id && matches!(s.kind, ShapeKind::TextBox | ShapeKind::WordArt)) => OpenAction::EditText(o.id),
ObjKind::Shape if sh.shapes.iter().any(|s| s.id == o.id && matches!(s.kind, ShapeKind::TextBox | ShapeKind::WordArt)) => {
OpenAction::EditText(o.id)
}
ObjKind::Shape | ObjKind::Image | ObjKind::Slicer => OpenAction::Select,
}
}