mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-12-02 15:21:15 -07:00
Merge branch 'master' of github.com:Ultimaker/Cura into network_rewrite
This commit is contained in:
commit
219e285b20
112 changed files with 30880 additions and 14277 deletions
|
|
@ -159,7 +159,7 @@ UM.PreferencesPage
|
|||
append({ text: "Nederlands", code: "nl_NL" })
|
||||
append({ text: "Polski", code: "pl_PL" })
|
||||
append({ text: "Português do Brasil", code: "pt_BR" })
|
||||
append({ text: "Русский", code: "ru_RU" })
|
||||
//Russian is disabled for being incomplete: append({ text: "Русский", code: "ru_RU" })
|
||||
append({ text: "Türkçe", code: "tr_TR" })
|
||||
append({ text: "简体中文", code: "zh_CN" })
|
||||
|
||||
|
|
|
|||
|
|
@ -45,6 +45,14 @@ Item {
|
|||
}
|
||||
}
|
||||
|
||||
function sliceOrStopSlicing() {
|
||||
if ([1, 5].indexOf(UM.Backend.state) != -1) {
|
||||
backend.forceSlice();
|
||||
} else {
|
||||
backend.stopSlicing();
|
||||
}
|
||||
}
|
||||
|
||||
Label {
|
||||
id: statusLabel
|
||||
width: parent.width - 2 * UM.Theme.getSize("sidebar_margin").width
|
||||
|
|
@ -86,6 +94,10 @@ Item {
|
|||
if (saveToButton.enabled) {
|
||||
saveToButton.clicked();
|
||||
}
|
||||
// prepare button
|
||||
if (prepareButton.enabled) {
|
||||
sliceOrStopSlicing();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -145,7 +157,7 @@ Item {
|
|||
Button {
|
||||
id: prepareButton
|
||||
|
||||
tooltip: UM.OutputDeviceManager.activeDeviceDescription;
|
||||
tooltip: catalog.i18nc("@info:tooltip","Slice");
|
||||
// 1 = not started, 2 = Processing
|
||||
enabled: (base.backendState == 1 || base.backendState == 2) && base.activity == true
|
||||
visible: {
|
||||
|
|
@ -162,11 +174,7 @@ Item {
|
|||
text: [1, 5].indexOf(UM.Backend.state) != -1 ? catalog.i18nc("@label:Printjob", "Prepare") : catalog.i18nc("@label:Printjob", "Cancel")
|
||||
onClicked:
|
||||
{
|
||||
if ([1, 5].indexOf(UM.Backend.state) != -1) {
|
||||
backend.forceSlice();
|
||||
} else {
|
||||
backend.stopSlicing();
|
||||
}
|
||||
sliceOrStopSlicing();
|
||||
}
|
||||
|
||||
style: ButtonStyle {
|
||||
|
|
|
|||
|
|
@ -343,7 +343,6 @@ Rectangle
|
|||
|
||||
onEntered:
|
||||
{
|
||||
|
||||
if(base.printDuration.valid && !base.printDuration.isTotalDurationZero)
|
||||
{
|
||||
// All the time information for the different features is achieved
|
||||
|
|
@ -356,20 +355,10 @@ Rectangle
|
|||
{
|
||||
if(!print_time[feature].isTotalDurationZero)
|
||||
{
|
||||
var feature_name = "";
|
||||
|
||||
if (feature.length <= 11)
|
||||
{
|
||||
feature_name = feature
|
||||
}
|
||||
else{
|
||||
feature_name = feature.substring(0, 8) + "..."
|
||||
}
|
||||
|
||||
|
||||
content += "<tr><td>" + feature_name + ":" +
|
||||
" </td><td>" + print_time[feature].getDisplayString(UM.DurationFormat.Short) +
|
||||
" </td><td>" + Math.round(100 * parseInt(print_time[feature].getDisplayString(UM.DurationFormat.Seconds)) / total_seconds) + "%" +
|
||||
content += "<tr><td colspan='2'>" + feature + "</td></tr>" +
|
||||
"<tr>" +
|
||||
"<td width='60%'>" + print_time[feature].getDisplayString(UM.DurationFormat.Short) + "</td>" +
|
||||
"<td width='40%'> " + Math.round(100 * parseInt(print_time[feature].getDisplayString(UM.DurationFormat.Seconds)) / total_seconds) + "%" +
|
||||
"</td></tr>";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -346,7 +346,7 @@ Column
|
|||
Label {
|
||||
id: materialInfoLabel
|
||||
wrapMode: Text.WordWrap
|
||||
text: catalog.i18nc("@label", "<a href='%1'>Check material compatibility</a>")
|
||||
text: catalog.i18nc("@label", "<a href='%1'>Check compatibility</a>")
|
||||
font: UM.Theme.getFont("default")
|
||||
color: UM.Theme.getColor("text")
|
||||
linkColor: UM.Theme.getColor("text_link")
|
||||
|
|
|
|||
|
|
@ -220,6 +220,83 @@ Rectangle
|
|||
menu: PrinterMenu { }
|
||||
}
|
||||
|
||||
//View orientation Item
|
||||
Row
|
||||
{
|
||||
id: viewOrientationControl
|
||||
height: 30
|
||||
|
||||
spacing: 2
|
||||
|
||||
visible: !base.monitoringPrint
|
||||
|
||||
anchors {
|
||||
verticalCenter: base.verticalCenter
|
||||
right: viewModeButton.right
|
||||
rightMargin: UM.Theme.getSize("default_margin").width + viewModeButton.width
|
||||
}
|
||||
|
||||
// #1 3d view
|
||||
Button
|
||||
{
|
||||
iconSource: UM.Theme.getIcon("view_3d")
|
||||
style: UM.Theme.styles.orientation_button
|
||||
anchors.verticalCenter: viewOrientationControl.verticalCenter
|
||||
onClicked:{
|
||||
UM.Controller.rotateView("3d", 0);
|
||||
}
|
||||
visible: base.width > 1100
|
||||
}
|
||||
|
||||
// #2 Front view
|
||||
Button
|
||||
{
|
||||
iconSource: UM.Theme.getIcon("view_front")
|
||||
style: UM.Theme.styles.orientation_button
|
||||
anchors.verticalCenter: viewOrientationControl.verticalCenter
|
||||
onClicked:{
|
||||
UM.Controller.rotateView("home", 0);
|
||||
}
|
||||
visible: base.width > 1130
|
||||
}
|
||||
|
||||
// #3 Top view
|
||||
Button
|
||||
{
|
||||
iconSource: UM.Theme.getIcon("view_top")
|
||||
style: UM.Theme.styles.orientation_button
|
||||
anchors.verticalCenter: viewOrientationControl.verticalCenter
|
||||
onClicked:{
|
||||
UM.Controller.rotateView("y", 90);
|
||||
}
|
||||
visible: base.width > 1160
|
||||
}
|
||||
|
||||
// #4 Left view
|
||||
Button
|
||||
{
|
||||
iconSource: UM.Theme.getIcon("view_left")
|
||||
style: UM.Theme.styles.orientation_button
|
||||
anchors.verticalCenter: viewOrientationControl.verticalCenter
|
||||
onClicked:{
|
||||
UM.Controller.rotateView("x", 90);
|
||||
}
|
||||
visible: base.width > 1190
|
||||
}
|
||||
|
||||
// #5 Left view
|
||||
Button
|
||||
{
|
||||
iconSource: UM.Theme.getIcon("view_right")
|
||||
style: UM.Theme.styles.orientation_button
|
||||
anchors.verticalCenter: viewOrientationControl.verticalCenter
|
||||
onClicked:{
|
||||
UM.Controller.rotateView("x", -90);
|
||||
}
|
||||
visible: base.width > 1210
|
||||
}
|
||||
}
|
||||
|
||||
ComboBox
|
||||
{
|
||||
id: viewModeButton
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue