Navigation bar: Look At (selected face or plane, else the active sketch) and visual style (shaded with edges, shaded, wireframe; kept between runs); F6 fits the view

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AS5Tn3xieewUSg3uxrMVdL
This commit is contained in:
bherbruckandClaude Opus 5.5 committed 2026-10-08 02:22:43 +00:00
1 parent 9c03f4bf32
commit 888ac0f5c4
4 files changed
+50 -5

No files matched your search

+7
View File
@@ -61,6 +61,8 @@ pub struct UiState {
pub pick_off: Vec<String>,
/// A click on a face picks its whole body.
pub pick_bodies: bool,
/// 0: shaded with edges, 1: shaded, 2: wireframe.
pub visual_style: u8,
/// Sketches hidden one by one, and finished sketches shown although a feature uses them.
pub hidden_sketches: Vec<u64>,
pub shown_sketches: Vec<u64>,
@@ -86,6 +88,7 @@ impl Default for UiState {
dark: true,
pick_off: Vec::new(),
pick_bodies: false,
visual_style: 0,
hidden_sketches: Vec::new(),
shown_sketches: Vec::new(),
hidden_profiles: Vec::new(),
@@ -184,6 +187,7 @@ impl SolveApp {
"perspective": self.ui.perspective,
"pick_bodies": self.ui.pick_bodies,
"auto_project": self.session.auto_project,
"visual_style": self.ui.visual_style,
})
.to_string()
}
@@ -207,6 +211,9 @@ impl SolveApp {
if let Some(a) = flag("auto_project") {
self.session.auto_project = a;
}
if let Some(s) = v.get("visual_style").and_then(Value::as_u64) {
self.ui.visual_style = u8::try_from(s.min(2)).unwrap_or(0);
}
}
pub fn with_control(mut self, rx: Receiver<ControlRequest>) -> Self {