mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-08 22:35:03 -06:00
Merge remote-tracking branch 'origin/4.0'
This commit is contained in:
commit
efa26c8323
11 changed files with 333 additions and 75 deletions
|
@ -12,45 +12,85 @@ import Cura 1.0 as Cura
|
|||
// This element hold all the elements needed for the user to trigger the slicing process, and later
|
||||
// to get information about the printing times, material consumption and the output process (such as
|
||||
// saving to a file, printing over network, ...
|
||||
Rectangle
|
||||
Item
|
||||
{
|
||||
id: actionPanelWidget
|
||||
id: base
|
||||
width: childrenRect.width
|
||||
height: childrenRect.height
|
||||
|
||||
width: UM.Theme.getSize("action_panel_widget").width
|
||||
height: childrenRect.height + 2 * UM.Theme.getSize("thick_margin").height
|
||||
|
||||
color: UM.Theme.getColor("main_background")
|
||||
border.width: UM.Theme.getSize("default_lining").width
|
||||
border.color: UM.Theme.getColor("lining")
|
||||
radius: UM.Theme.getSize("default_radius").width
|
||||
z: 10
|
||||
|
||||
property bool outputAvailable: UM.Backend.state == UM.Backend.Done || UM.Backend.state == UM.Backend.Disabled
|
||||
|
||||
Loader
|
||||
Rectangle
|
||||
{
|
||||
id: loader
|
||||
anchors
|
||||
id: actionPanelWidget
|
||||
|
||||
width: UM.Theme.getSize("action_panel_widget").width
|
||||
height: childrenRect.height + 2 * UM.Theme.getSize("thick_margin").height
|
||||
anchors. right: parent.right
|
||||
color: UM.Theme.getColor("main_background")
|
||||
border.width: UM.Theme.getSize("default_lining").width
|
||||
border.color: UM.Theme.getColor("lining")
|
||||
radius: UM.Theme.getSize("default_radius").width
|
||||
z: 10
|
||||
|
||||
property bool outputAvailable: UM.Backend.state == UM.Backend.Done || UM.Backend.state == UM.Backend.Disabled
|
||||
|
||||
Loader
|
||||
{
|
||||
top: parent.top
|
||||
topMargin: UM.Theme.getSize("thick_margin").height
|
||||
left: parent.left
|
||||
leftMargin: UM.Theme.getSize("thick_margin").width
|
||||
right: parent.right
|
||||
rightMargin: UM.Theme.getSize("thick_margin").width
|
||||
id: loader
|
||||
anchors
|
||||
{
|
||||
top: parent.top
|
||||
topMargin: UM.Theme.getSize("thick_margin").height
|
||||
left: parent.left
|
||||
leftMargin: UM.Theme.getSize("thick_margin").width
|
||||
right: parent.right
|
||||
rightMargin: UM.Theme.getSize("thick_margin").width
|
||||
}
|
||||
sourceComponent: actionPanelWidget.outputAvailable ? outputProcessWidget : sliceProcessWidget
|
||||
}
|
||||
|
||||
Component
|
||||
{
|
||||
id: sliceProcessWidget
|
||||
SliceProcessWidget { }
|
||||
}
|
||||
|
||||
Component
|
||||
{
|
||||
id: outputProcessWidget
|
||||
OutputProcessWidget { }
|
||||
}
|
||||
sourceComponent: outputAvailable ? outputProcessWidget : sliceProcessWidget
|
||||
}
|
||||
|
||||
Component
|
||||
Item
|
||||
{
|
||||
id: sliceProcessWidget
|
||||
SliceProcessWidget { }
|
||||
id: additionalComponents
|
||||
width: childrenRect.width
|
||||
anchors.right: actionPanelWidget.left
|
||||
anchors.rightMargin: UM.Theme.getSize("default_margin").width
|
||||
anchors.bottom: actionPanelWidget.bottom
|
||||
anchors.bottomMargin: UM.Theme.getSize("thick_margin").height * 2
|
||||
visible: actionPanelWidget.visible
|
||||
Row
|
||||
{
|
||||
id: additionalComponentsRow
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
spacing: UM.Theme.getSize("default_margin").width
|
||||
}
|
||||
}
|
||||
|
||||
Component
|
||||
Component.onCompleted: base.addAdditionalComponents()
|
||||
|
||||
Connections
|
||||
{
|
||||
id: outputProcessWidget
|
||||
OutputProcessWidget { }
|
||||
target: CuraApplication
|
||||
onAdditionalComponentsChanged: base.addAdditionalComponents()
|
||||
}
|
||||
|
||||
function addAdditionalComponents()
|
||||
{
|
||||
for (var component in CuraApplication.additionalComponents["saveButton"])
|
||||
{
|
||||
CuraApplication.additionalComponents["saveButton"][component].parent = additionalComponentsRow
|
||||
}
|
||||
}
|
||||
}
|
|
@ -270,39 +270,6 @@ UM.MainWindow
|
|||
visible: CuraApplication.platformActivity && (main.item == null || !qmlTypeOf(main.item, "QQuickRectangle"))
|
||||
}
|
||||
|
||||
Item
|
||||
{
|
||||
id: additionalComponents
|
||||
width: childrenRect.width
|
||||
anchors.right: actionPanelWidget.left
|
||||
anchors.rightMargin: UM.Theme.getSize("default_margin").width
|
||||
anchors.bottom: actionPanelWidget.bottom
|
||||
anchors.bottomMargin: UM.Theme.getSize("thick_margin").height * 2
|
||||
visible: actionPanelWidget.visible
|
||||
Row
|
||||
{
|
||||
id: additionalComponentsRow
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
spacing: UM.Theme.getSize("default_margin").width
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: contentItem.addAdditionalComponents()
|
||||
|
||||
Connections
|
||||
{
|
||||
target: CuraApplication
|
||||
onAdditionalComponentsChanged: contentItem.addAdditionalComponents("saveButton")
|
||||
}
|
||||
|
||||
function addAdditionalComponents()
|
||||
{
|
||||
for (var component in CuraApplication.additionalComponents["saveButton"])
|
||||
{
|
||||
CuraApplication.additionalComponents["saveButton"][component].parent = additionalComponentsRow
|
||||
}
|
||||
}
|
||||
|
||||
Loader
|
||||
{
|
||||
// A stage can control this area. If nothing is set, it will therefore show the 3D view.
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
"wide_lining": [31, 36, 39, 255],
|
||||
"thick_lining": [255, 255, 255, 30],
|
||||
"lining": [64, 69, 72, 255],
|
||||
"viewport_overlay": [0, 6, 9, 222],
|
||||
"viewport_overlay": [30, 36, 39, 255],
|
||||
|
||||
"primary": [12, 169, 227, 255],
|
||||
"primary_hover": [48, 182, 231, 255],
|
||||
|
|
|
@ -146,7 +146,7 @@
|
|||
"wide_lining": [245, 245, 245, 255],
|
||||
"thick_lining": [127, 127, 127, 255],
|
||||
"lining": [192, 193, 194, 255],
|
||||
"viewport_overlay": [0, 0, 0, 192],
|
||||
"viewport_overlay": [246, 246, 246, 255],
|
||||
|
||||
"primary": [50, 130, 255, 255],
|
||||
"primary_shadow": [64, 47, 205, 255],
|
||||
|
@ -598,10 +598,14 @@
|
|||
|
||||
"monitor_config_override_box": [1.0, 14.0],
|
||||
"monitor_extruder_circle": [2.75, 2.75],
|
||||
"monitor_text_line": [1.16, 1.16],
|
||||
"monitor_text_line": [1.5, 1.5],
|
||||
"monitor_text_line_large": [2.33, 2.33],
|
||||
"monitor_thick_lining": [0.16, 0.16],
|
||||
"monitor_corner_radius": [0.3, 0.3],
|
||||
"monitor_shadow_radius": [0.4, 0.4],
|
||||
"monitor_shadow_offset": [0.15, 0.15]
|
||||
"monitor_shadow_offset": [0.15, 0.15],
|
||||
"monitor_empty_state_offset": [5.6, 5.6],
|
||||
"monitor_empty_state_size": [35.0, 25.0],
|
||||
"monitor_external_link_icon": [1.16, 1.16]
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue