forked from 1b-agent/opencadstudio-upstream
Merge main into codex/graphic-attributes-cleanup
Resolve conflicts from main's rustfmt pass by taking main's versions of command.rs, style.rs, view/mod.rs, scene/mod.rs, ui/window/mod.rs and ui/properties.rs and re-applying this branch's Graphic Attributes changes. Add the Graphic Attributes strings to the new lo-LA catalog. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E1QnME6WJbD5iGFae1eeCb
This commit is contained in:
596 files changed
+69069
-34120
No files matched your search
@@ -2470,6 +2470,32 @@ pub struct PointPickContext {
|
||||
pub aperture_px: f32,
|
||||
}
|
||||
|
||||
/// One context-sensitive command-line autocomplete entry.
|
||||
///
|
||||
/// Normal command-name autocomplete only needs `value`. Interactive commands
|
||||
/// may optionally attach CAD display metadata, allowing the shared suggestion
|
||||
/// popup to render richer rows without knowing which command supplied them.
|
||||
#[derive(Clone, Debug)]
|
||||
pub struct CommandSuggestion {
|
||||
pub value: String,
|
||||
pub color: Option<codec::types::Color>,
|
||||
pub visible: Option<bool>,
|
||||
pub frozen: Option<bool>,
|
||||
pub locked: Option<bool>,
|
||||
}
|
||||
|
||||
impl CommandSuggestion {
|
||||
pub fn plain(value: impl Into<String>) -> Self {
|
||||
Self {
|
||||
value: value.into(),
|
||||
color: None,
|
||||
visible: None,
|
||||
frozen: None,
|
||||
locked: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
pub trait CadCommand: Send {
|
||||
/// Preserve source appearance for commands that extract existing entities.
|
||||
fn preserve_commit_style(&self) -> bool {
|
||||
@@ -2511,6 +2537,15 @@ pub trait CadCommand: Send {
|
||||
false
|
||||
}
|
||||
|
||||
/// Context-sensitive autocomplete entries for the command line while this
|
||||
/// command is active. Unlike normal command-name completion these entries
|
||||
/// may be drawing data such as layer, block or style names.
|
||||
///
|
||||
/// Commands that do not provide contextual completion leave this empty.
|
||||
fn text_suggestions(&self, _input: &str) -> Vec<CommandSuggestion> {
|
||||
Vec::new()
|
||||
}
|
||||
|
||||
/// Push the active coordinate frame in full precision. Geometry commands
|
||||
/// use it for plane-local construction; inquiry and modify commands use it
|
||||
/// for local deltas, angles and transformation axes.
|
||||
|
||||
Reference in new issue
Block a user