forked from 1b-agent/opencadstudio-upstream
Complete application localization across all supported languages
This commit is contained in:
1 parent
96c794c072
commit
d66e89ca19
78 files changed
+26043
-877
No files matched your search
@@ -280,14 +280,14 @@ impl CadCommand for ArcLengthDimensionCommand {
|
||||
|
||||
fn prompt(&self) -> String {
|
||||
if self.awaiting_text {
|
||||
return "DIMARC Enter dimension text (blank = measured value):".to_string();
|
||||
return crate::t!("DIMARC Enter dimension text (blank = measured value):").into_owned();
|
||||
}
|
||||
if self.awaiting_angle {
|
||||
return "DIMARC Specify text angle (degrees):".to_string();
|
||||
return crate::t!("DIMARC Specify text angle (degrees):").into_owned();
|
||||
}
|
||||
match self.step {
|
||||
Step::SelectObject => {
|
||||
"DIMARC Select arc or polyline arc segment:".to_string()
|
||||
crate::t!("DIMARC Select arc or polyline arc segment:").into_owned()
|
||||
}
|
||||
Step::DimLine(selection) => {
|
||||
let leader_option = if selection.sweep() > std::f64::consts::FRAC_PI_2 {
|
||||
@@ -295,15 +295,15 @@ impl CadCommand for ArcLengthDimensionCommand {
|
||||
} else {
|
||||
""
|
||||
};
|
||||
format!(
|
||||
crate::tf!(
|
||||
"DIMARC Specify arc length dimension location [Mtext/Text/Angle/Partial{leader_option}]:"
|
||||
)
|
||||
).into_owned()
|
||||
}
|
||||
Step::PartialFirst(_) => {
|
||||
"DIMARC Specify first point of partial arc:".to_string()
|
||||
crate::t!("DIMARC Specify first point of partial arc:").into_owned()
|
||||
}
|
||||
Step::PartialSecond { .. } => {
|
||||
"DIMARC Specify second point of partial arc:".to_string()
|
||||
crate::t!("DIMARC Specify second point of partial arc:").into_owned()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -385,16 +385,15 @@ impl CadCommand for DimBaselineCommand {
|
||||
|
||||
fn prompt(&self) -> String {
|
||||
if self.base.is_none() {
|
||||
"DIMBASELINE Select base dimension:".to_string()
|
||||
crate::t!("DIMBASELINE Select base dimension:").into_owned()
|
||||
} else if self
|
||||
.base
|
||||
.as_ref()
|
||||
.is_some_and(|base| matches!(&base.kind, BaselineKind::Ordinate { .. }))
|
||||
{
|
||||
"DIMBASELINE Specify feature location [Undo/Select] <Select>:".to_string()
|
||||
crate::t!("DIMBASELINE Specify feature location [Undo/Select] <Select>:").into_owned()
|
||||
} else {
|
||||
"DIMBASELINE Specify second extension line origin [Select/Undo] <Select>:"
|
||||
.to_string()
|
||||
crate::t!("DIMBASELINE Specify second extension line origin [Select/Undo] <Select>:").into_owned()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -322,16 +322,15 @@ impl CadCommand for DimContinueCommand {
|
||||
|
||||
fn prompt(&self) -> String {
|
||||
if self.base.is_none() {
|
||||
"DIMCONTINUE Select continued dimension:".to_string()
|
||||
crate::t!("DIMCONTINUE Select continued dimension:").into_owned()
|
||||
} else if self
|
||||
.base
|
||||
.as_ref()
|
||||
.is_some_and(|base| matches!(&base.kind, ContinueKind::Ordinate { .. }))
|
||||
{
|
||||
"DIMCONTINUE Specify feature location [Undo/Select] <Select>:".to_string()
|
||||
crate::t!("DIMCONTINUE Specify feature location [Undo/Select] <Select>:").into_owned()
|
||||
} else {
|
||||
"DIMCONTINUE Specify second extension line origin [Select/Undo] <Select>:"
|
||||
.to_string()
|
||||
crate::t!("DIMCONTINUE Specify second extension line origin [Select/Undo] <Select>:").into_owned()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -249,7 +249,7 @@ impl CadCommand for TextCommand {
|
||||
"TEXT Current style: {}, Height: {}, Annotative: {}",
|
||||
self.style_name,
|
||||
self.height,
|
||||
if self.annotative { "Yes" } else { "No" }
|
||||
if self.annotative { t!("Yes") } else { t!("No") }
|
||||
),
|
||||
t!("TEXT Specify start point or [Justify/Style]:")
|
||||
),
|
||||
|
||||
Reference in new issue
Block a user