mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-04-29 15:25:02 +08:00
Merge remote-tracking branch 'origin/4.1'
This commit is contained in:
commit
3ca272ff72
@ -66,6 +66,10 @@ class ConvexHullDecorator(SceneNodeDecorator):
|
||||
|
||||
node.boundingBoxChanged.connect(self._onChanged)
|
||||
|
||||
per_object_stack = node.callDecoration("getStack")
|
||||
if per_object_stack:
|
||||
per_object_stack.propertyChanged.connect(self._onSettingValueChanged)
|
||||
|
||||
self._onChanged()
|
||||
|
||||
## Force that a new (empty) object is created upon copy.
|
||||
@ -76,7 +80,8 @@ class ConvexHullDecorator(SceneNodeDecorator):
|
||||
def getConvexHull(self) -> Optional[Polygon]:
|
||||
if self._node is None:
|
||||
return None
|
||||
|
||||
if self._node.callDecoration("isNonPrintingMesh"):
|
||||
return None
|
||||
hull = self._compute2DConvexHull()
|
||||
|
||||
if self._global_stack and self._node is not None and hull is not None:
|
||||
@ -106,7 +111,8 @@ class ConvexHullDecorator(SceneNodeDecorator):
|
||||
def getConvexHullHead(self) -> Optional[Polygon]:
|
||||
if self._node is None:
|
||||
return None
|
||||
|
||||
if self._node.callDecoration("isNonPrintingMesh"):
|
||||
return None
|
||||
if self._global_stack:
|
||||
if self._global_stack.getProperty("print_sequence", "value") == "one_at_a_time" and not self.hasGroupAsParent(self._node):
|
||||
head_with_fans = self._compute2DConvexHeadMin()
|
||||
@ -123,6 +129,9 @@ class ConvexHullDecorator(SceneNodeDecorator):
|
||||
if self._node is None:
|
||||
return None
|
||||
|
||||
if self._node.callDecoration("isNonPrintingMesh"):
|
||||
return None
|
||||
|
||||
if self._global_stack:
|
||||
if self._global_stack.getProperty("print_sequence", "value") == "one_at_a_time" and not self.hasGroupAsParent(self._node):
|
||||
# Printing one at a time and it's not an object in a group
|
||||
@ -398,4 +407,4 @@ class ConvexHullDecorator(SceneNodeDecorator):
|
||||
## Settings that change the convex hull.
|
||||
#
|
||||
# If these settings change, the convex hull should be recalculated.
|
||||
_influencing_settings = {"xy_offset", "xy_offset_layer_0", "mold_enabled", "mold_width"}
|
||||
_influencing_settings = {"xy_offset", "xy_offset_layer_0", "mold_enabled", "mold_width", "anti_overhang_mesh", "infill_mesh", "cutting_mesh"}
|
||||
|
@ -51,7 +51,7 @@ Item
|
||||
{
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: 18 * screenScaleFactor // TODO: Theme!
|
||||
width: 216 * screenScaleFactor // TODO: Theme! (Should match column size)
|
||||
width: UM.Theme.getSize("monitor_column").width
|
||||
Rectangle
|
||||
{
|
||||
color: UM.Theme.getColor("monitor_skeleton_loading")
|
||||
@ -79,7 +79,7 @@ Item
|
||||
{
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: 18 * screenScaleFactor // TODO: Theme!
|
||||
width: 216 * screenScaleFactor // TODO: Theme! (Should match column size)
|
||||
width: UM.Theme.getSize("monitor_column").width
|
||||
Rectangle
|
||||
{
|
||||
color: UM.Theme.getColor("monitor_skeleton_loading")
|
||||
|
@ -28,9 +28,12 @@ Item
|
||||
anchors
|
||||
{
|
||||
verticalCenter: parent.verticalCenter
|
||||
left: parent.left
|
||||
}
|
||||
value: printJob ? printJob.progress : 0
|
||||
width: UM.Theme.getSize("monitor_column").width
|
||||
}
|
||||
|
||||
Label
|
||||
{
|
||||
id: percentLabel
|
||||
@ -38,6 +41,7 @@ Item
|
||||
{
|
||||
left: progressBar.right
|
||||
leftMargin: 18 * screenScaleFactor // TODO: Theme!
|
||||
verticalCenter: parent.verticalCenter
|
||||
}
|
||||
text: printJob ? Math.round(printJob.progress * 100) + "%" : "0%"
|
||||
color: printJob && printJob.isActive ? UM.Theme.getColor("monitor_text_primary") : UM.Theme.getColor("monitor_text_disabled")
|
||||
@ -56,6 +60,7 @@ Item
|
||||
{
|
||||
left: percentLabel.right
|
||||
leftMargin: 18 * screenScaleFactor // TODO: Theme!
|
||||
verticalCenter: parent.verticalCenter
|
||||
}
|
||||
color: UM.Theme.getColor("monitor_text_primary")
|
||||
font: UM.Theme.getFont("medium") // 14pt, regular
|
||||
|
@ -120,7 +120,7 @@ Item
|
||||
elide: Text.ElideRight
|
||||
font: UM.Theme.getFont("medium") // 14pt, regular
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
width: 216 * screenScaleFactor // TODO: Theme! (Should match column size)
|
||||
width: UM.Theme.getSize("monitor_column").width
|
||||
|
||||
// FIXED-LINE-HEIGHT:
|
||||
height: 18 * screenScaleFactor // TODO: Theme!
|
||||
@ -135,7 +135,7 @@ Item
|
||||
elide: Text.ElideRight
|
||||
font: UM.Theme.getFont("medium") // 14pt, regular
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
width: 216 * screenScaleFactor // TODO: Theme! (Should match column size)
|
||||
width: UM.Theme.getSize("monitor_column").width
|
||||
|
||||
// FIXED-LINE-HEIGHT:
|
||||
height: 18 * screenScaleFactor // TODO: Theme!
|
||||
|
@ -618,6 +618,7 @@
|
||||
"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]
|
||||
"monitor_external_link_icon": [1.16, 1.16],
|
||||
"monitor_column": [18.0, 1.0]
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user