Merge branch 'feature_intent' of https://github.com/Ultimaker/Cura into feature_intent

This commit is contained in:
Remco Burema 2019-09-26 14:02:32 +02:00
commit 3c2467b6d6
6 changed files with 40 additions and 3 deletions

View File

@ -280,7 +280,7 @@ class ContainerManager(QObject):
current_quality_type = global_stack.quality.getMetaDataEntry("quality_type")
extruder_stacks = list(global_stack.extruders.values())
container_registry = cura.CuraApplication.CuraApplication.getInstance().getContainerRegistry()
machine_definition_id = ContainerTree.getInstance().definitions[global_stack.definition.getId()].quality_definition
machine_definition_id = ContainerTree.getInstance().machines[global_stack.definition.getId()].quality_definition
for stack in [global_stack] + extruder_stacks:
# Find the quality_changes container for this stack and merge the contents of the top container into it.
quality_changes = stack.qualityChanges

View File

@ -67,6 +67,8 @@ Item
{
id: textLabel
text: intentSelection.text
font: UM.Theme.getFont("default")
color: UM.Theme.getColor("text")
anchors.left: parent.left
anchors.leftMargin: UM.Theme.getSize("default_margin").width
anchors.verticalCenter: intentSelection.verticalCenter

View File

@ -48,5 +48,7 @@ Button
anchors.left: button.left
anchors.leftMargin: UM.Theme.getSize("wide_margin").width
renderType: Text.NativeRendering
font: UM.Theme.getFont("default")
color: UM.Theme.getColor("text")
}
}

View File

@ -111,7 +111,6 @@ Popup
return Cura.MachineManager.activeQualityType == model.quality_type && Cura.MachineManager.activeIntentCategory == model.intent_category;
}
ButtonGroup.group: buttonGroup
}
}
}
@ -271,6 +270,8 @@ Popup
anchors.leftMargin: UM.Theme.getSize("default_margin").width + UM.Theme.getSize("narrow_margin").width
verticalAlignment: Text.AlignVCenter
renderType: Text.NativeRendering
font: UM.Theme.getFont("default")
color: UM.Theme.getColor("text")
}
Label
{
@ -281,6 +282,8 @@ Popup
anchors.rightMargin: UM.Theme.getSize("default_margin").width
verticalAlignment: Text.AlignVCenter
renderType: Text.NativeRendering
font: UM.Theme.getFont("default")
color: UM.Theme.getColor("text")
}
}
onClicked:

View File

@ -52,6 +52,36 @@ Item
font: UM.Theme.getFont("medium")
width: labelColumnWidth
}
UM.SimpleButton
{
id: customisedSettings
visible: Cura.SimpleModeSettingsManager.isProfileCustomized || Cura.MachineManager.hasCustomQuality
height: visible ? UM.Theme.getSize("print_setup_icon").height : 0
width: height
anchors
{
right: profileLabel.right
rightMargin: UM.Theme.getSize("default_margin").width
leftMargin: UM.Theme.getSize("default_margin").width
verticalCenter: parent.verticalCenter
}
color: hovered ? UM.Theme.getColor("setting_control_button_hover") : UM.Theme.getColor("setting_control_button")
iconSource: UM.Theme.getIcon("reset")
onClicked:
{
// if the current profile is user-created, switch to a built-in quality
Cura.MachineManager.resetToUseDefaultQuality()
}
onEntered:
{
var tooltipContent = catalog.i18nc("@tooltip","You have modified some profile settings. If you want to change these go to custom mode.")
base.showTooltip(qualityRow, Qt.point(-UM.Theme.getSize("thick_margin").width, 0), tooltipContent)
}
onExited: base.hideTooltip()
}
Cura.LabelBar
{

View File

@ -88,7 +88,7 @@
"action_button": [39, 44, 48, 255],
"action_button_text": [255, 255, 255, 200],
"action_button_border": [255, 255, 255, 30],
"action_button_hovered": [39, 44, 48, 255],
"action_button_hovered": [79, 85, 89, 255],
"action_button_hovered_text": [255, 255, 255, 255],
"action_button_hovered_border": [255, 255, 255, 30],
"action_button_active": [39, 44, 48, 30],