forked from 1b-agent/opencadstudio-upstream
CCONSTRAINTFORM system variable
Reads and sets the form new dimensional constraints take (0 dynamic, 1 annotational), the same state DCFORM sets. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
b435af64cd
commit
2db393155f
1 file changed
+8
@@ -1054,6 +1054,7 @@ impl OpenCADStudio {
|
|||||||
| "CONSTRAINTBARMODE"
|
| "CONSTRAINTBARMODE"
|
||||||
| "CONSTRAINTNAMEFORMAT"
|
| "CONSTRAINTNAMEFORMAT"
|
||||||
| "DYNCONSTRAINTDISPLAY"
|
| "DYNCONSTRAINTDISPLAY"
|
||||||
|
| "CCONSTRAINTFORM"
|
||||||
) =>
|
) =>
|
||||||
{
|
{
|
||||||
return self.dispatch_styleprops(&format!("SETVAR {cmd}"), i);
|
return self.dispatch_styleprops(&format!("SETVAR {cmd}"), i);
|
||||||
@@ -1279,6 +1280,7 @@ impl OpenCADStudio {
|
|||||||
| "CONSTRAINTBARMODE"
|
| "CONSTRAINTBARMODE"
|
||||||
| "CONSTRAINTNAMEFORMAT"
|
| "CONSTRAINTNAMEFORMAT"
|
||||||
| "DYNCONSTRAINTDISPLAY"
|
| "DYNCONSTRAINTDISPLAY"
|
||||||
|
| "CCONSTRAINTFORM"
|
||||||
) {
|
) {
|
||||||
let current = match name.as_str() {
|
let current = match name.as_str() {
|
||||||
"CONSTRAINTSOLVEMODE" => i16::from(self.constraint_solve_mode),
|
"CONSTRAINTSOLVEMODE" => i16::from(self.constraint_solve_mode),
|
||||||
@@ -1291,6 +1293,7 @@ impl OpenCADStudio {
|
|||||||
"DYNCONSTRAINTDISPLAY" => {
|
"DYNCONSTRAINTDISPLAY" => {
|
||||||
i16::from(self.tabs[i].scene.dynamic_constraint_display)
|
i16::from(self.tabs[i].scene.dynamic_constraint_display)
|
||||||
}
|
}
|
||||||
|
"CCONSTRAINTFORM" => i16::from(self.constraint_form_annotational),
|
||||||
_ => unreachable!(),
|
_ => unreachable!(),
|
||||||
};
|
};
|
||||||
let maximum = match name.as_str() {
|
let maximum = match name.as_str() {
|
||||||
@@ -1325,6 +1328,11 @@ impl OpenCADStudio {
|
|||||||
mode != 0;
|
mode != 0;
|
||||||
self.tabs[i].scene.refresh_hidden_dynamic_dimensions();
|
self.tabs[i].scene.refresh_hidden_dynamic_dimensions();
|
||||||
}
|
}
|
||||||
|
// The form new dimensional constraints take
|
||||||
|
// (0 dynamic, 1 annotational), as DCFORM sets.
|
||||||
|
"CCONSTRAINTFORM" => {
|
||||||
|
self.constraint_form_annotational = mode != 0
|
||||||
|
}
|
||||||
_ => unreachable!(),
|
_ => unreachable!(),
|
||||||
}
|
}
|
||||||
self.persist_settings_if_changed();
|
self.persist_settings_if_changed();
|
||||||
|
|||||||
Reference in new issue
Block a user