mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-06-04 11:14:21 +08:00
commit
6e35936ab9
@ -28,12 +28,17 @@ function(cura_add_test)
|
|||||||
string(REPLACE "|" ":" _PYTHONPATH ${_PYTHONPATH})
|
string(REPLACE "|" ":" _PYTHONPATH ${_PYTHONPATH})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_test(
|
get_test_property(${_NAME} ENVIRONMENT test_exists) #Find out if the test exists by getting a property from it that always exists (such as ENVIRONMENT because we set that ourselves).
|
||||||
NAME ${_NAME}
|
if (${test_exists} EQUAL "NOTFOUND")
|
||||||
COMMAND ${PYTHON_EXECUTABLE} -m pytest --junitxml=${CMAKE_BINARY_DIR}/junit-${_NAME}.xml ${_DIRECTORY}
|
add_test(
|
||||||
)
|
NAME ${_NAME}
|
||||||
set_tests_properties(${_NAME} PROPERTIES ENVIRONMENT LANG=C)
|
COMMAND ${PYTHON_EXECUTABLE} -m pytest --junitxml=${CMAKE_BINARY_DIR}/junit-${_NAME}.xml ${_DIRECTORY}
|
||||||
set_tests_properties(${_NAME} PROPERTIES ENVIRONMENT "PYTHONPATH=${_PYTHONPATH}")
|
)
|
||||||
|
set_tests_properties(${_NAME} PROPERTIES ENVIRONMENT LANG=C)
|
||||||
|
set_tests_properties(${_NAME} PROPERTIES ENVIRONMENT "PYTHONPATH=${_PYTHONPATH}")
|
||||||
|
else()
|
||||||
|
message(WARNING "Duplicate test ${_NAME}!")
|
||||||
|
endif()
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
cura_add_test(NAME pytest-main DIRECTORY ${CMAKE_SOURCE_DIR}/tests PYTHONPATH "${CMAKE_SOURCE_DIR}|${URANIUM_DIR}")
|
cura_add_test(NAME pytest-main DIRECTORY ${CMAKE_SOURCE_DIR}/tests PYTHONPATH "${CMAKE_SOURCE_DIR}|${URANIUM_DIR}")
|
||||||
|
@ -1387,7 +1387,7 @@ class CuraApplication(QtApplication):
|
|||||||
|
|
||||||
if node.callDecoration("isSliceable"):
|
if node.callDecoration("isSliceable"):
|
||||||
# Only check position if it's not already blatantly obvious that it won't fit.
|
# Only check position if it's not already blatantly obvious that it won't fit.
|
||||||
if node.getBoundingBox().width < self._volume.getBoundingBox().width or node.getBoundingBox().depth < self._volume.getBoundingBox().depth:
|
if node.getBoundingBox() is None or self._volume.getBoundingBox() is None or node.getBoundingBox().width < self._volume.getBoundingBox().width or node.getBoundingBox().depth < self._volume.getBoundingBox().depth:
|
||||||
# Find node location
|
# Find node location
|
||||||
offset_shape_arr, hull_shape_arr = ShapeArray.fromNode(node, min_offset = min_offset)
|
offset_shape_arr, hull_shape_arr = ShapeArray.fromNode(node, min_offset = min_offset)
|
||||||
|
|
||||||
|
@ -43,13 +43,12 @@ class ShapeArray:
|
|||||||
transform_x = transform._data[0][3]
|
transform_x = transform._data[0][3]
|
||||||
transform_y = transform._data[2][3]
|
transform_y = transform._data[2][3]
|
||||||
hull_verts = node.callDecoration("getConvexHull")
|
hull_verts = node.callDecoration("getConvexHull")
|
||||||
|
# If a model is too small then it will not contain any points
|
||||||
|
if hull_verts is None or not hull_verts.getPoints().any():
|
||||||
|
return None, None
|
||||||
# For one_at_a_time printing you need the convex hull head.
|
# For one_at_a_time printing you need the convex hull head.
|
||||||
hull_head_verts = node.callDecoration("getConvexHullHead") or hull_verts
|
hull_head_verts = node.callDecoration("getConvexHullHead") or hull_verts
|
||||||
|
|
||||||
# If a model is to small then it will not contain any points
|
|
||||||
if not hull_verts.getPoints().any():
|
|
||||||
return None, None
|
|
||||||
|
|
||||||
offset_verts = hull_head_verts.getMinkowskiHull(Polygon.approximatedCircle(min_offset))
|
offset_verts = hull_head_verts.getMinkowskiHull(Polygon.approximatedCircle(min_offset))
|
||||||
offset_points = copy.deepcopy(offset_verts._points) # x, y
|
offset_points = copy.deepcopy(offset_verts._points) # x, y
|
||||||
offset_points[:, 0] = numpy.add(offset_points[:, 0], -transform_x)
|
offset_points[:, 0] = numpy.add(offset_points[:, 0], -transform_x)
|
||||||
|
@ -143,7 +143,7 @@ class StartSliceJob(Job):
|
|||||||
if per_object_stack:
|
if per_object_stack:
|
||||||
is_non_printing_mesh = any(per_object_stack.getProperty(key, "value") for key in NON_PRINTING_MESH_SETTINGS)
|
is_non_printing_mesh = any(per_object_stack.getProperty(key, "value") for key in NON_PRINTING_MESH_SETTINGS)
|
||||||
|
|
||||||
if not getattr(node, "_outside_buildarea", False):
|
if not getattr(node, "_outside_buildarea", False) or is_non_printing_mesh:
|
||||||
temp_list.append(node)
|
temp_list.append(node)
|
||||||
if not is_non_printing_mesh:
|
if not is_non_printing_mesh:
|
||||||
has_printing_mesh = True
|
has_printing_mesh = True
|
||||||
|
@ -1614,7 +1614,7 @@
|
|||||||
"infill_overlap":
|
"infill_overlap":
|
||||||
{
|
{
|
||||||
"label": "Infill Overlap Percentage",
|
"label": "Infill Overlap Percentage",
|
||||||
"description": "The amount of overlap between the infill and the walls. A slight overlap allows the walls to connect firmly to the infill.",
|
"description": "The amount of overlap between the infill and the walls as a percentage of the infill line width. A slight overlap allows the walls to connect firmly to the infill.",
|
||||||
"unit": "%",
|
"unit": "%",
|
||||||
"type": "float",
|
"type": "float",
|
||||||
"default_value": 10,
|
"default_value": 10,
|
||||||
@ -1635,7 +1635,7 @@
|
|||||||
"default_value": 0.04,
|
"default_value": 0.04,
|
||||||
"minimum_value_warning": "-0.5 * machine_nozzle_size",
|
"minimum_value_warning": "-0.5 * machine_nozzle_size",
|
||||||
"maximum_value_warning": "machine_nozzle_size",
|
"maximum_value_warning": "machine_nozzle_size",
|
||||||
"value": "0.5 * ( infill_line_width + (wall_line_width_x if wall_line_count > 1 else wall_line_width_0) ) * infill_overlap / 100 if infill_sparse_density < 95 and infill_pattern != 'concentric' else 0",
|
"value": "0.5 * (infill_line_width + (wall_line_width_x if wall_line_count > 1 else wall_line_width_0)) * infill_overlap / 100 if infill_sparse_density < 95 and infill_pattern != 'concentric' else 0",
|
||||||
"enabled": "infill_sparse_density > 0 and infill_pattern != 'concentric'",
|
"enabled": "infill_sparse_density > 0 and infill_pattern != 'concentric'",
|
||||||
"settable_per_mesh": true
|
"settable_per_mesh": true
|
||||||
}
|
}
|
||||||
@ -1644,7 +1644,7 @@
|
|||||||
"skin_overlap":
|
"skin_overlap":
|
||||||
{
|
{
|
||||||
"label": "Skin Overlap Percentage",
|
"label": "Skin Overlap Percentage",
|
||||||
"description": "The amount of overlap between the skin and the walls as a percentage of the line width. A slight overlap allows the walls to connect firmly to the skin. This is a percentage of the average line widths of the skin lines and the innermost wall.",
|
"description": "The amount of overlap between the skin and the walls as a percentage of the skin line width. A slight overlap allows the walls to connect firmly to the skin. This is a percentage of the average line widths of the skin lines and the innermost wall.",
|
||||||
"unit": "%",
|
"unit": "%",
|
||||||
"type": "float",
|
"type": "float",
|
||||||
"default_value": 5,
|
"default_value": 5,
|
||||||
@ -1665,7 +1665,7 @@
|
|||||||
"default_value": 0.02,
|
"default_value": 0.02,
|
||||||
"minimum_value_warning": "-0.5 * machine_nozzle_size",
|
"minimum_value_warning": "-0.5 * machine_nozzle_size",
|
||||||
"maximum_value_warning": "machine_nozzle_size",
|
"maximum_value_warning": "machine_nozzle_size",
|
||||||
"value": "0.5 * ( skin_line_width + (wall_line_width_x if wall_line_count > 1 else wall_line_width_0) ) * skin_overlap / 100 if top_bottom_pattern != 'concentric' else 0",
|
"value": "0.5 * (skin_line_width + (wall_line_width_x if wall_line_count > 1 else wall_line_width_0)) * skin_overlap / 100 if top_bottom_pattern != 'concentric' else 0",
|
||||||
"enabled": "top_bottom_pattern != 'concentric'",
|
"enabled": "top_bottom_pattern != 'concentric'",
|
||||||
"settable_per_mesh": true
|
"settable_per_mesh": true
|
||||||
}
|
}
|
||||||
|
4595
resources/i18n/pt_PT/cura.po
Normal file
4595
resources/i18n/pt_PT/cura.po
Normal file
File diff suppressed because it is too large
Load Diff
210
resources/i18n/pt_PT/fdmextruder.def.json.po
Normal file
210
resources/i18n/pt_PT/fdmextruder.def.json.po
Normal file
@ -0,0 +1,210 @@
|
|||||||
|
# Cura JSON setting files
|
||||||
|
# Copyright (C) 2017 Ultimaker
|
||||||
|
# This file is distributed under the same license as the Cura package.
|
||||||
|
# Ruben Dulek <r.dulek@ultimaker.com>, 2017.
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: Cura 3.1\n"
|
||||||
|
"Report-Msgid-Bugs-To: r.dulek@ultimaker.com\n"
|
||||||
|
"POT-Creation-Date: 2017-08-02 16:53+0000\n"
|
||||||
|
"PO-Revision-Date: 2017-12-07 13:41+0100\n"
|
||||||
|
"Last-Translator: Bothof <info@bothof.nl>\n"
|
||||||
|
"Language-Team: Bothof\n"
|
||||||
|
"Language: pt_PT\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_settings label"
|
||||||
|
msgid "Machine"
|
||||||
|
msgstr "Máquina"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_settings description"
|
||||||
|
msgid "Machine specific settings"
|
||||||
|
msgstr "Definições específicas da máquina"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_nr label"
|
||||||
|
msgid "Extruder"
|
||||||
|
msgstr "Extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_nr description"
|
||||||
|
msgid "The extruder train used for printing. This is used in multi-extrusion."
|
||||||
|
msgstr "A máquina extrusora utilizada para imprimir. Esta é utilizada em extrusões múltiplas."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_id label"
|
||||||
|
msgid "Nozzle ID"
|
||||||
|
msgstr "ID do bocal"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_id description"
|
||||||
|
msgid "The nozzle ID for an extruder train, such as \"AA 0.4\" and \"BB 0.8\"."
|
||||||
|
msgstr "A ID do bocal para uma máquina de extrusão, tal como \"AA 0.4\" e \"BB 0.8\"."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_size label"
|
||||||
|
msgid "Nozzle Diameter"
|
||||||
|
msgstr "Diâmetro do bocal"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_size description"
|
||||||
|
msgid ""
|
||||||
|
"The inner diameter of the nozzle. Change this setting when using a non-"
|
||||||
|
"standard nozzle size."
|
||||||
|
msgstr "O diâmetro interno do bocal. Altere esta definição ao utilizar um tamanho de bocal não convencional."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_offset_x label"
|
||||||
|
msgid "Nozzle X Offset"
|
||||||
|
msgstr "Desvio X do bocal"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_offset_x description"
|
||||||
|
msgid "The x-coordinate of the offset of the nozzle."
|
||||||
|
msgstr "A coordenada X do desvio do bocal."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_offset_y label"
|
||||||
|
msgid "Nozzle Y Offset"
|
||||||
|
msgstr "Desvio Y do bocal"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_nozzle_offset_y description"
|
||||||
|
msgid "The y-coordinate of the offset of the nozzle."
|
||||||
|
msgstr "A coordenada Y do desvio do bocal."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_code label"
|
||||||
|
msgid "Extruder Start G-Code"
|
||||||
|
msgstr "G-Code inicial da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_code description"
|
||||||
|
msgid "Start g-code to execute whenever turning the extruder on."
|
||||||
|
msgstr "G-Code inicial a ser executado sempre que a extrusora for ligada."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_abs label"
|
||||||
|
msgid "Extruder Start Position Absolute"
|
||||||
|
msgstr "Posição inicial absoluta da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_abs description"
|
||||||
|
msgid ""
|
||||||
|
"Make the extruder starting position absolute rather than relative to the "
|
||||||
|
"last-known location of the head."
|
||||||
|
msgstr "Torne a posição inicial da extrusora absoluta em vez de relativa à última posição conhecida da cabeça."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_x label"
|
||||||
|
msgid "Extruder Start Position X"
|
||||||
|
msgstr "X da posição inicial da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_x description"
|
||||||
|
msgid "The x-coordinate of the starting position when turning the extruder on."
|
||||||
|
msgstr "A coordenada X da posição inicial ao ligar a extrusora."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_y label"
|
||||||
|
msgid "Extruder Start Position Y"
|
||||||
|
msgstr "Y da posição inicial da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_start_pos_y description"
|
||||||
|
msgid "The y-coordinate of the starting position when turning the extruder on."
|
||||||
|
msgstr "A coordenada Y da posição inicial ao ligar a extrusora."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_code label"
|
||||||
|
msgid "Extruder End G-Code"
|
||||||
|
msgstr "G-Code final da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_code description"
|
||||||
|
msgid "End g-code to execute whenever turning the extruder off."
|
||||||
|
msgstr "G-Code final a ser executado sempre que a extrusora for desligada."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_abs label"
|
||||||
|
msgid "Extruder End Position Absolute"
|
||||||
|
msgstr "Posição final absoluta da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_abs description"
|
||||||
|
msgid ""
|
||||||
|
"Make the extruder ending position absolute rather than relative to the last-"
|
||||||
|
"known location of the head."
|
||||||
|
msgstr "Torne a posição final da extrusora absoluta em vez de relativa à última localização conhecida da cabeça."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_x label"
|
||||||
|
msgid "Extruder End Position X"
|
||||||
|
msgstr "X da posição final da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_x description"
|
||||||
|
msgid "The x-coordinate of the ending position when turning the extruder off."
|
||||||
|
msgstr "A coordenada X da posição final ao desligar a extrusora."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_y label"
|
||||||
|
msgid "Extruder End Position Y"
|
||||||
|
msgstr "Y da posição final da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "machine_extruder_end_pos_y description"
|
||||||
|
msgid "The y-coordinate of the ending position when turning the extruder off."
|
||||||
|
msgstr "A coordenada Y da posição final ao desligar a extrusora."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_z label"
|
||||||
|
msgid "Extruder Prime Z Position"
|
||||||
|
msgstr "Posição Z de preparação da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_z description"
|
||||||
|
msgid ""
|
||||||
|
"The Z coordinate of the position where the nozzle primes at the start of "
|
||||||
|
"printing."
|
||||||
|
msgstr "A coordenada Z da posição de preparação do bocal ao iniciar a impressão."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "platform_adhesion label"
|
||||||
|
msgid "Build Plate Adhesion"
|
||||||
|
msgstr "Aderência à placa de construção"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "platform_adhesion description"
|
||||||
|
msgid "Adhesion"
|
||||||
|
msgstr "Aderência"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_x label"
|
||||||
|
msgid "Extruder Prime X Position"
|
||||||
|
msgstr "Posição X de preparação da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_x description"
|
||||||
|
msgid ""
|
||||||
|
"The X coordinate of the position where the nozzle primes at the start of "
|
||||||
|
"printing."
|
||||||
|
msgstr "A coordenada X da posição de preparação do bocal ao iniciar a impressão."
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_y label"
|
||||||
|
msgid "Extruder Prime Y Position"
|
||||||
|
msgstr "Posição Y de preparação da extrusora"
|
||||||
|
|
||||||
|
#: fdmextruder.def.json
|
||||||
|
msgctxt "extruder_prime_pos_y description"
|
||||||
|
msgid ""
|
||||||
|
"The Y coordinate of the position where the nozzle primes at the start of "
|
||||||
|
"printing."
|
||||||
|
msgstr "A coordenada Y da posição de preparação do bocal ao iniciar a impressão."
|
5814
resources/i18n/pt_PT/fdmprinter.def.json.po
Normal file
5814
resources/i18n/pt_PT/fdmprinter.def.json.po
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
|||||||
// Copyright (c) 2016 Ultimaker B.V.
|
// Copyright (c) 2017 Ultimaker B.V.
|
||||||
// Cura is released under the terms of the LGPLv3 or higher.
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.2
|
import QtQuick 2.2
|
||||||
@ -25,6 +25,15 @@ UM.Dialog
|
|||||||
width: minimumWidth
|
width: minimumWidth
|
||||||
height: minimumHeight
|
height: minimumHeight
|
||||||
|
|
||||||
|
flags: {
|
||||||
|
var window_flags = Qt.Dialog | Qt.CustomizeWindowHint | Qt.WindowTitleHint;
|
||||||
|
if (Cura.MachineManager.activeDefinitionId !== "") //Disallow closing the window if we have no active printer yet. You MUST add a printer.
|
||||||
|
{
|
||||||
|
window_flags |= Qt.WindowCloseButtonHint;
|
||||||
|
}
|
||||||
|
return window_flags;
|
||||||
|
}
|
||||||
|
|
||||||
onVisibilityChanged:
|
onVisibilityChanged:
|
||||||
{
|
{
|
||||||
// Reset selection and machine name
|
// Reset selection and machine name
|
||||||
|
@ -204,7 +204,7 @@ Item
|
|||||||
|
|
||||||
Connections {
|
Connections {
|
||||||
target: CuraApplication
|
target: CuraApplication
|
||||||
onAdditionalComponentsChanged: buttonsRow.updateAdditionalComponents
|
onAdditionalComponentsChanged: buttonsRow.updateAdditionalComponents("monitorButtons")
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateAdditionalComponents (areaId) {
|
function updateAdditionalComponents (areaId) {
|
||||||
|
@ -159,6 +159,7 @@ UM.PreferencesPage
|
|||||||
append({ text: "Nederlands", code: "nl_NL" })
|
append({ text: "Nederlands", code: "nl_NL" })
|
||||||
append({ text: "Polski", code: "pl_PL" })
|
append({ text: "Polski", code: "pl_PL" })
|
||||||
append({ text: "Português do Brasil", code: "pt_BR" })
|
append({ text: "Português do Brasil", code: "pt_BR" })
|
||||||
|
append({ text: "Português", code: "pt_PT" })
|
||||||
append({ text: "Русский", code: "ru_RU" })
|
append({ text: "Русский", code: "ru_RU" })
|
||||||
append({ text: "Türkçe", code: "tr_TR" })
|
append({ text: "Türkçe", code: "tr_TR" })
|
||||||
append({ text: "简体中文", code: "zh_CN" })
|
append({ text: "简体中文", code: "zh_CN" })
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
// Copyright (c) 2015 Ultimaker B.V.
|
// Copyright (c) 2017 Ultimaker B.V.
|
||||||
// Uranium is released under the terms of the LGPLv3 or higher.
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.2
|
import QtQuick 2.2
|
||||||
import QtQuick.Controls 1.1
|
import QtQuick.Controls 1.1
|
||||||
@ -31,13 +31,17 @@ Button {
|
|||||||
|
|
||||||
onClicked:
|
onClicked:
|
||||||
{
|
{
|
||||||
forceActiveFocus();
|
|
||||||
if(definition.expanded)
|
if(definition.expanded)
|
||||||
{
|
{
|
||||||
settingDefinitionsModel.collapse(definition.key);
|
settingDefinitionsModel.collapse(definition.key);
|
||||||
} else {
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
settingDefinitionsModel.expandAll(definition.key);
|
settingDefinitionsModel.expandAll(definition.key);
|
||||||
}
|
}
|
||||||
|
//Set focus so that tab navigation continues from this point on.
|
||||||
|
//NB: This must be set AFTER collapsing/expanding the category so that the scroll position is correct.
|
||||||
|
forceActiveFocus();
|
||||||
}
|
}
|
||||||
onActiveFocusChanged:
|
onActiveFocusChanged:
|
||||||
{
|
{
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
// Copyright (c) 2015 Ultimaker B.V.
|
// Copyright (c) 2017 Ultimaker B.V.
|
||||||
// Uranium is released under the terms of the LGPLv3 or higher.
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.1
|
import QtQuick 2.1
|
||||||
import QtQuick.Layouts 1.1
|
import QtQuick.Layouts 1.1
|
||||||
@ -154,7 +154,7 @@ Item {
|
|||||||
|
|
||||||
onEntered: {
|
onEntered: {
|
||||||
hoverTimer.stop();
|
hoverTimer.stop();
|
||||||
var tooltipText = catalog.i18nc("@label", "This setting is always shared between all extruders. Changing it here will change the value for all extruders") + ".";
|
var tooltipText = catalog.i18nc("@label", "This setting is always shared between all extruders. Changing it here will change the value for all extruders.");
|
||||||
if ((resolve != "None") && (stackLevel != 0)) {
|
if ((resolve != "None") && (stackLevel != 0)) {
|
||||||
// We come here if a setting has a resolve and the setting is not manually edited.
|
// We come here if a setting has a resolve and the setting is not manually edited.
|
||||||
tooltipText += " " + catalog.i18nc("@label", "The value is resolved from per-extruder values ") + "[" + Cura.ExtruderManager.getInstanceExtruderValues(definition.key) + "].";
|
tooltipText += " " + catalog.i18nc("@label", "The value is resolved from per-extruder values ") + "[" + Cura.ExtruderManager.getInstanceExtruderValues(definition.key) + "].";
|
||||||
|
@ -202,9 +202,8 @@ QtObject {
|
|||||||
height: Theme.getSize("topbar_button_icon").height
|
height: Theme.getSize("topbar_button_icon").height
|
||||||
Label
|
Label
|
||||||
{
|
{
|
||||||
|
id: button_label
|
||||||
text: control.text;
|
text: control.text;
|
||||||
anchors.right: (icon.visible || overlayIcon.visible) ? icon.left : parent.right
|
|
||||||
anchors.rightMargin: (icon.visible || overlayIcon.visible) ? Theme.getSize("default_margin").width : 0
|
|
||||||
anchors.verticalCenter: parent.verticalCenter;
|
anchors.verticalCenter: parent.verticalCenter;
|
||||||
font: control.checked ? UM.Theme.getFont("large") : UM.Theme.getFont("large_nonbold")
|
font: control.checked ? UM.Theme.getFont("large") : UM.Theme.getFont("large_nonbold")
|
||||||
color:
|
color:
|
||||||
@ -227,6 +226,8 @@ QtObject {
|
|||||||
{
|
{
|
||||||
visible: control.iconSource != ""
|
visible: control.iconSource != ""
|
||||||
id: icon
|
id: icon
|
||||||
|
anchors.left: button_label.right
|
||||||
|
anchors.leftMargin: (icon.visible || overlayIcon.visible) ? Theme.getSize("default_margin").width : 0
|
||||||
color: UM.Theme.getColor("text_emphasis")
|
color: UM.Theme.getColor("text_emphasis")
|
||||||
opacity: !control.enabled ? 0.2 : 1.0
|
opacity: !control.enabled ? 0.2 : 1.0
|
||||||
source: control.iconSource
|
source: control.iconSource
|
||||||
@ -238,6 +239,8 @@ QtObject {
|
|||||||
UM.RecolorImage
|
UM.RecolorImage
|
||||||
{
|
{
|
||||||
id: overlayIcon
|
id: overlayIcon
|
||||||
|
anchors.left: button_label.right
|
||||||
|
anchors.leftMargin: (icon.visible || overlayIcon.visible) ? Theme.getSize("default_margin").width : 0
|
||||||
visible: control.overlayIconSource != "" && control.iconSource != ""
|
visible: control.overlayIconSource != "" && control.iconSource != ""
|
||||||
color: control.overlayColor
|
color: control.overlayColor
|
||||||
opacity: !control.enabled ? 0.2 : 1.0
|
opacity: !control.enabled ? 0.2 : 1.0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user