forked from 1b-agent/opencadstudio-upstream
fix(commands): JUSTIFYTEXT sets vertical alignment for single-line TEXT
The Text branch only set horizontal_alignment, so TL/BL/MC etc. never moved the text box vertically. Map the T*/M*/B* codes to Top/Middle/Bottom and re-sync the alignment point. (#246) Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
1 parent
3d761bdcd3
commit
2bc5c2a686
2 files changed
+23
-2
No files matched your search
@@ -33,7 +33,7 @@ fn text_valign_str(a: &acadrust::entities::TextVerticalAlignment) -> &'static st
|
||||
}
|
||||
}
|
||||
|
||||
fn sync_text_alignment_point(t: &mut Text) {
|
||||
pub(crate) fn sync_text_alignment_point(t: &mut Text) {
|
||||
let needs_alignment_point = !matches!(
|
||||
(t.horizontal_alignment, t.vertical_alignment),
|
||||
(HA::Left, VA::Baseline)
|
||||
|
||||
Reference in new issue
Block a user