Draft: improve handling of anno DisplayMode and LineSpacing

* DisplayMode controlled by new pref DefaultAnnoDisplayMode. This replaces the old dimstyle pref.
* LineSpacing pref is now used when creating annotations. Will be added to prefs ui later.
* format_object no longer changes FontSize as this conflicted with the height parameter in the make_text function.
* make_text function updated.
This commit is contained in:
Roy-043
2023-11-27 12:50:11 +01:00
committed by Yorik van Havre
parent 5a4a358f13
commit 484bbf3807
9 changed files with 39 additions and 38 deletions

View File

@@ -173,7 +173,7 @@ def get_param_type(param):
"precision", "defaultWP", "snapRange", "gridEvery",
"linewidth", "modconstrain", "modsnap",
"maxSnapEdges", "modalt", "HatchPatternResolution",
"snapStyle", "dimstyle", "gridSize", "gridTransparency"):
"snapStyle", "DefaultAnnoDisplayMode", "gridSize", "gridTransparency"):
return "int"
elif param in ("constructiongroupname", "textfont",
"patternFile", "snapModes",
@@ -181,7 +181,8 @@ def get_param_type(param):
"labeltype", "gridSpacing") or "inCommandShortcut" in param:
return "string"
elif param in ("textheight", "arrowsize", "extlines", "dimspacing",
"dimovershoot", "extovershoot", "HatchPatternSize"):
"dimovershoot", "extovershoot", "HatchPatternSize",
"LineSpacing"):
return "float"
elif param in ("selectBaseObjects", "alwaysSnap", "grid",
"fillmode", "maxSnap", "DimShowLine",