mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-12 09:17:50 -06:00
Add missing translation calls and contexts
This commit is contained in:
parent
db74d4016e
commit
ca2d2f4cb2
4 changed files with 64 additions and 31 deletions
|
@ -28,7 +28,8 @@ Rectangle {
|
||||||
anchors.fill: parent;
|
anchors.fill: parent;
|
||||||
anchors.margins: UM.Theme.defaultMargin;
|
anchors.margins: UM.Theme.defaultMargin;
|
||||||
|
|
||||||
Button { text: "Open File"; iconSource: UM.Resources.getIcon("open.png"); Layout.fillWidth: true; onClicked: base.requestOpenFile(); }
|
//: Open file button
|
||||||
|
Button { text: qsTr("Open File"); iconSource: UM.Resources.getIcon("open.png"); Layout.fillWidth: true; onClicked: base.requestOpenFile(); }
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.fillWidth: true;
|
Layout.fillWidth: true;
|
||||||
|
|
|
@ -23,7 +23,8 @@ Rectangle {
|
||||||
font.pointSize: UM.Theme.largeTextSize;
|
font.pointSize: UM.Theme.largeTextSize;
|
||||||
color: "white";
|
color: "white";
|
||||||
|
|
||||||
text: "Save";
|
//: Save file to disk button
|
||||||
|
text: qsTr("Save");
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -68,12 +69,14 @@ Rectangle {
|
||||||
states: [
|
states: [
|
||||||
State {
|
State {
|
||||||
name: 'sdcard';
|
name: 'sdcard';
|
||||||
PropertyChanges { target: label; text: 'Write to SD'; }
|
//: Write to SD card button
|
||||||
|
PropertyChanges { target: label; text: qsTr("Write to SD"); }
|
||||||
PropertyChanges { target: iconImage; source: UM.Resources.getIcon('sdcard.png'); }
|
PropertyChanges { target: iconImage; source: UM.Resources.getIcon('sdcard.png'); }
|
||||||
},
|
},
|
||||||
State {
|
State {
|
||||||
name: 'usb';
|
name: 'usb';
|
||||||
PropertyChanges { target: label; text: 'Send over USB'; }
|
//: Send print over USB button
|
||||||
|
PropertyChanges { target: label; text: qsTr("Send over USB"); }
|
||||||
PropertyChanges { target: iconImage; source: UM.Resources.getIcon('usb.png'); }
|
PropertyChanges { target: iconImage; source: UM.Resources.getIcon('usb.png'); }
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
68
Printer.qml
68
Printer.qml
|
@ -13,7 +13,7 @@ UM.MainWindow {
|
||||||
width: 1280
|
width: 1280
|
||||||
height: 720
|
height: 720
|
||||||
|
|
||||||
title: "Cura";
|
title: qsTr("Cura");
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: backgroundItem;
|
id: backgroundItem;
|
||||||
|
@ -24,7 +24,8 @@ UM.MainWindow {
|
||||||
window: base
|
window: base
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
title: '&File';
|
//: File menu
|
||||||
|
title: qsTr("&File");
|
||||||
|
|
||||||
MenuItem { action: openAction; }
|
MenuItem { action: openAction; }
|
||||||
MenuItem { action: saveAction; }
|
MenuItem { action: saveAction; }
|
||||||
|
@ -35,7 +36,8 @@ UM.MainWindow {
|
||||||
}
|
}
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
title: '&Edit';
|
//: Edit menu
|
||||||
|
title: qsTr("&Edit");
|
||||||
|
|
||||||
MenuItem { action: undoAction; }
|
MenuItem { action: undoAction; }
|
||||||
MenuItem { action: redoAction; }
|
MenuItem { action: redoAction; }
|
||||||
|
@ -46,7 +48,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
id: machineMenu;
|
id: machineMenu;
|
||||||
title: "&Machine";
|
//: Machine menu
|
||||||
|
title: qsTr("&Machine");
|
||||||
|
|
||||||
Instantiator {
|
Instantiator {
|
||||||
model: UM.Models.machinesModel
|
model: UM.Models.machinesModel
|
||||||
|
@ -62,24 +65,32 @@ UM.MainWindow {
|
||||||
}
|
}
|
||||||
|
|
||||||
ExclusiveGroup { id: machineMenuGroup; }
|
ExclusiveGroup { id: machineMenuGroup; }
|
||||||
|
|
||||||
MenuSeparator { }
|
MenuSeparator { }
|
||||||
MenuItem { text: "Add new machine..."; enabled: false; }
|
|
||||||
|
|
||||||
|
MenuItem { action: addMachineAction; }
|
||||||
|
MenuItem { action: settingsAction; }
|
||||||
}
|
}
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
title: 'E&xtensions';
|
//: Extensions menu
|
||||||
|
title: qsTr("E&xtensions");
|
||||||
|
|
||||||
MenuItem { text: "No extensions loaded"; enabled: false; }
|
//: Empty extensions menu
|
||||||
|
MenuItem { text: qsTr("No extensions loaded"); enabled: false; }
|
||||||
}
|
}
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
title: '&Settings';
|
//: Settings menu
|
||||||
|
title: qsTr("&Settings");
|
||||||
|
|
||||||
MenuItem { action: preferencesAction; }
|
MenuItem { action: preferencesAction; }
|
||||||
}
|
}
|
||||||
|
|
||||||
Menu {
|
Menu {
|
||||||
title: '&Help';
|
//: Help menu
|
||||||
|
title: qsTr("&Help");
|
||||||
|
|
||||||
MenuItem { action: helpAction; enabled: false; }
|
MenuItem { action: helpAction; enabled: false; }
|
||||||
MenuItem { action: aboutAction; enabled: false; }
|
MenuItem { action: aboutAction; enabled: false; }
|
||||||
|
@ -180,7 +191,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: undoAction;
|
id: undoAction;
|
||||||
text: "Undo";
|
//: Undo action
|
||||||
|
text: qsTr("Undo");
|
||||||
iconName: "edit-undo";
|
iconName: "edit-undo";
|
||||||
shortcut: StandardKey.Undo;
|
shortcut: StandardKey.Undo;
|
||||||
onTriggered: UM.OperationStack.undo();
|
onTriggered: UM.OperationStack.undo();
|
||||||
|
@ -189,7 +201,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: redoAction;
|
id: redoAction;
|
||||||
text: "Redo";
|
//: Redo action
|
||||||
|
text: qsTr("Redo");
|
||||||
iconName: "edit-redo";
|
iconName: "edit-redo";
|
||||||
shortcut: StandardKey.Redo;
|
shortcut: StandardKey.Redo;
|
||||||
onTriggered: UM.OperationStack.redo();
|
onTriggered: UM.OperationStack.redo();
|
||||||
|
@ -198,7 +211,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: quitAction;
|
id: quitAction;
|
||||||
text: "Quit";
|
//: Quit action
|
||||||
|
text: qsTr("Quit");
|
||||||
iconName: "application-exit";
|
iconName: "application-exit";
|
||||||
shortcut: StandardKey.Quit;
|
shortcut: StandardKey.Quit;
|
||||||
onTriggered: Qt.quit();
|
onTriggered: Qt.quit();
|
||||||
|
@ -206,34 +220,39 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: preferencesAction;
|
id: preferencesAction;
|
||||||
text: "Preferences";
|
//: Preferences action
|
||||||
|
text: qsTr("Preferences");
|
||||||
iconName: "configure";
|
iconName: "configure";
|
||||||
onTriggered: preferences.visible = true;
|
onTriggered: preferences.visible = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: settingsAction;
|
id: settingsAction;
|
||||||
text: "Configure Printers";
|
//: Manage Printers action
|
||||||
|
text: qsTr("Configure Printers");
|
||||||
iconSource: UM.Resources.getIcon("settings.png");
|
iconSource: UM.Resources.getIcon("settings.png");
|
||||||
onTriggered: preferences.visible = true;
|
onTriggered: preferences.visible = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: helpAction;
|
id: helpAction;
|
||||||
text: "Show Manual";
|
//: Show Manual action
|
||||||
|
text: qsTr("Show Manual");
|
||||||
iconName: "help-contents";
|
iconName: "help-contents";
|
||||||
shortcut: StandardKey.Help;
|
shortcut: StandardKey.Help;
|
||||||
}
|
}
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: aboutAction;
|
id: aboutAction;
|
||||||
text: "About...";
|
//: About action
|
||||||
|
text: qsTr("About...");
|
||||||
iconName: "help-about";
|
iconName: "help-about";
|
||||||
}
|
}
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: deleteAction;
|
id: deleteAction;
|
||||||
text: "Delete Selection";
|
//: Delete selection action
|
||||||
|
text: qsTr("Delete Selection");
|
||||||
iconName: "edit-delete";
|
iconName: "edit-delete";
|
||||||
shortcut: StandardKey.Delete;
|
shortcut: StandardKey.Delete;
|
||||||
onTriggered: UM.Controller.removeSelection();
|
onTriggered: UM.Controller.removeSelection();
|
||||||
|
@ -241,14 +260,16 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: deleteAllAction;
|
id: deleteAllAction;
|
||||||
text: "Clear Build Platform";
|
//: Clear build platform action
|
||||||
|
text: qsTr("Clear Build Platform");
|
||||||
iconName: "edit-clear";
|
iconName: "edit-clear";
|
||||||
enabled: false;
|
enabled: false;
|
||||||
}
|
}
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: openAction;
|
id: openAction;
|
||||||
text: "Open...";
|
//: Open file action
|
||||||
|
text: qsTr("Open...");
|
||||||
iconName: "document-open";
|
iconName: "document-open";
|
||||||
shortcut: StandardKey.Open;
|
shortcut: StandardKey.Open;
|
||||||
onTriggered: openDialog.open();
|
onTriggered: openDialog.open();
|
||||||
|
@ -256,7 +277,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
Action {
|
Action {
|
||||||
id: saveAction;
|
id: saveAction;
|
||||||
text: "Save...";
|
//: Save file action
|
||||||
|
text: qsTr("Save...");
|
||||||
iconName: "document-save";
|
iconName: "document-save";
|
||||||
shortcut: StandardKey.Save;
|
shortcut: StandardKey.Save;
|
||||||
onTriggered: saveDialog.open();
|
onTriggered: saveDialog.open();
|
||||||
|
@ -271,7 +293,8 @@ UM.MainWindow {
|
||||||
FileDialog {
|
FileDialog {
|
||||||
id: openDialog;
|
id: openDialog;
|
||||||
|
|
||||||
title: "Choose files"
|
//: File open dialog title
|
||||||
|
title: qsTr("Open File")
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
//TODO: Support multiple file selection, workaround bug in KDE file dialog
|
//TODO: Support multiple file selection, workaround bug in KDE file dialog
|
||||||
//selectMultiple: true
|
//selectMultiple: true
|
||||||
|
@ -285,7 +308,8 @@ UM.MainWindow {
|
||||||
|
|
||||||
FileDialog {
|
FileDialog {
|
||||||
id: saveDialog;
|
id: saveDialog;
|
||||||
title: "Choose Filename";
|
//: File save dialog title
|
||||||
|
title: qsTr("Save File");
|
||||||
selectExisting: false;
|
selectExisting: false;
|
||||||
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
|
|
|
@ -37,7 +37,8 @@ Rectangle {
|
||||||
rightMargin: UM.Theme.defaultMargin;
|
rightMargin: UM.Theme.defaultMargin;
|
||||||
}
|
}
|
||||||
|
|
||||||
Label { text: "Print Settings"; width: parent.width; font.capitalization: Font.AllUppercase; font.pointSize: UM.Theme.smallTextSize; }
|
//: Print Settings panel title
|
||||||
|
Label { text: qsTr("Print Settings"); width: parent.width; font.capitalization: Font.AllUppercase; font.pointSize: UM.Theme.smallTextSize; }
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
width: parent.width;
|
width: parent.width;
|
||||||
|
@ -47,7 +48,8 @@ Rectangle {
|
||||||
anchors.fill: parent;
|
anchors.fill: parent;
|
||||||
spacing: UM.Theme.defaultMargin;
|
spacing: UM.Theme.defaultMargin;
|
||||||
|
|
||||||
Label { text: "Material"; horizontalAlignment: Text.AlignRight; width: base.width * 0.5; }
|
//: Material selection combo box label
|
||||||
|
Label { text: qsTr("Material"); horizontalAlignment: Text.AlignRight; width: base.width * 0.5; }
|
||||||
ComboBox {
|
ComboBox {
|
||||||
width: parent.width * 0.35;
|
width: parent.width * 0.35;
|
||||||
model: ListModel {
|
model: ListModel {
|
||||||
|
@ -66,7 +68,8 @@ Rectangle {
|
||||||
Row {
|
Row {
|
||||||
anchors.fill: parent;
|
anchors.fill: parent;
|
||||||
spacing: UM.Theme.defaultMargin;
|
spacing: UM.Theme.defaultMargin;
|
||||||
Label { text: "Time"; width: base.width * 0.5; horizontalAlignment: Text.AlignRight; }
|
//: Time display label
|
||||||
|
Label { text: qsTr("Time"); width: base.width * 0.5; horizontalAlignment: Text.AlignRight; }
|
||||||
Label { text: Qt.formatTime(new Date(timeSlider.value * 60000)); width: base.width * 0.35; horizontalAlignment: Text.AlignLeft; }
|
Label { text: Qt.formatTime(new Date(timeSlider.value * 60000)); width: base.width * 0.35; horizontalAlignment: Text.AlignLeft; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -118,7 +121,8 @@ Rectangle {
|
||||||
anchors.bottom: parent.bottom;
|
anchors.bottom: parent.bottom;
|
||||||
|
|
||||||
Label { text: Qt.formatTime(new Date(timeSlider.minimumValue * 60000)); }
|
Label { text: Qt.formatTime(new Date(timeSlider.minimumValue * 60000)); }
|
||||||
Label { text: "Low Quality"; }
|
//: Low quality display label
|
||||||
|
Label { text: qsTr("Low Quality"); }
|
||||||
}
|
}
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
|
@ -126,7 +130,8 @@ Rectangle {
|
||||||
anchors.bottom: parent.bottom;
|
anchors.bottom: parent.bottom;
|
||||||
|
|
||||||
Label { text: Qt.formatTime(new Date(timeSlider.maximumValue * 60000)); anchors.right: parent.right; }
|
Label { text: Qt.formatTime(new Date(timeSlider.maximumValue * 60000)); anchors.right: parent.right; }
|
||||||
Label { text: "High Quality"; }
|
//: High quality display label
|
||||||
|
Label { text: qsTr("High Quality"); }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue