diff --git a/cura/Settings/SettingOverrideDecorator.py b/cura/Settings/SettingOverrideDecorator.py index 2fa5234ec3..03b4c181dd 100644 --- a/cura/Settings/SettingOverrideDecorator.py +++ b/cura/Settings/SettingOverrideDecorator.py @@ -94,6 +94,12 @@ class SettingOverrideDecorator(SceneNodeDecorator): # # \return An extruder's position, or None if no position info is available. def getActiveExtruderPosition(self): + # for support_meshes, always use the support_extruder + if self.getStack().getProperty("support_mesh", "value"): + global_container_stack = Application.getInstance().getGlobalContainerStack() + if global_container_stack: + return str(global_container_stack.getProperty("support_extruder_nr", "value")) + containers = ContainerRegistry.getInstance().findContainers(id = self.getActiveExtruder()) if containers: container_stack = containers[0] diff --git a/cura/UI/ObjectsModel.py b/cura/UI/ObjectsModel.py index 6378ebcd1b..659732e895 100644 --- a/cura/UI/ObjectsModel.py +++ b/cura/UI/ObjectsModel.py @@ -1,4 +1,4 @@ -# Copyright (c) 2019 Ultimaker B.V. +# Copyright (c) 2020 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. from UM.Logger import Logger import re @@ -38,6 +38,9 @@ class ObjectsModel(ListModel): OutsideAreaRole = Qt.UserRole + 3 BuilplateNumberRole = Qt.UserRole + 4 NodeRole = Qt.UserRole + 5 + PerObjectSettingsCountRole = Qt.UserRole + 6 + MeshTypeRole = Qt.UserRole + 7 + ExtruderNumberRole = Qt.UserRole + 8 def __init__(self, parent = None) -> None: super().__init__(parent) @@ -46,6 +49,9 @@ class ObjectsModel(ListModel): self.addRoleName(self.SelectedRole, "selected") self.addRoleName(self.OutsideAreaRole, "outside_build_area") self.addRoleName(self.BuilplateNumberRole, "buildplate_number") + self.addRoleName(self.ExtruderNumberRole, "extruder_number") + self.addRoleName(self.PerObjectSettingsCountRole, "per_object_settings_count") + self.addRoleName(self.MeshTypeRole, "mesh_type") self.addRoleName(self.NodeRole, "node") Application.getInstance().getController().getScene().sceneChanged.connect(self._updateSceneDelayed) @@ -172,11 +178,47 @@ class ObjectsModel(ListModel): node_build_plate_number = node.callDecoration("getBuildPlateNumber") + node_mesh_type = "" + per_object_settings_count = 0 + + per_object_stack = node.callDecoration("getStack") + if per_object_stack: + per_object_settings_count = per_object_stack.getTop().getNumInstances() + + for mesh_type in ["anti_overhang_mesh", "infill_mesh", "cutting_mesh", "support_mesh"]: + if per_object_stack.getProperty(mesh_type, "value"): + node_mesh_type = mesh_type + per_object_settings_count -= 1 # do not count this mesh type setting + break + + if per_object_settings_count > 0: + if node_mesh_type == "support_mesh": + # support meshes only allow support settings + per_object_settings_count = 0 + for key in per_object_stack.getTop().getAllKeys(): + if per_object_stack.getTop().getInstance(key).definition.isAncestor("support"): + per_object_settings_count += 1 + elif node_mesh_type == "anti_overhang_mesh": + # anti overhang meshes ignore per model settings + per_object_settings_count = 0 + + extruder_position = node.callDecoration("getActiveExtruderPosition") + if extruder_position is None: + extruder_number = -1 + else: + extruder_number = int(extruder_position) + if node_mesh_type == "anti_overhang_mesh" or node.callDecoration("isGroup"): + # for anti overhang meshes and groups the extruder nr is irrelevant + extruder_number = -1 + nodes.append({ "name": node.getName(), "selected": Selection.isSelected(node), "outside_build_area": is_outside_build_area, "buildplate_number": node_build_plate_number, + "extruder_number": extruder_number, + "per_object_settings_count": per_object_settings_count, + "mesh_type": node_mesh_type, "node": node }) diff --git a/docs/Cura_Data_Model.odg b/docs/Cura_Data_Model.odg deleted file mode 100644 index b4a6dd548b..0000000000 Binary files a/docs/Cura_Data_Model.odg and /dev/null differ diff --git a/docs/Profile Stack.drawio b/docs/Profile Stack.drawio deleted file mode 100644 index ed942c09db..0000000000 --- a/docs/Profile Stack.drawio +++ /dev/null @@ -1 +0,0 @@ -7ZtNb9s4EIZ/jY+70LftY+NkuwskQFrvts2pYCRaIkqLBkXXcn79Di3Ssk3ZTR195EDAB82IpIZ8ZgzxBTXyZ8vyI0er7IElmI48JylH/u3I89zA80by5yTbyjOOxpUj5SRRjWrHnLxg5XSUd00SXBw1FIxRQVbHzpjlOY7FkQ9xzjbHzRaMHj91hVJsOOYxoqb3K0lEVnkn3rj2/41Jmuknu9G0urNEurGaSZGhhG0OXP7dyJ9xxkR1tSxnmMrF0+tS9fvrzN19YBzn4jUdvnDvJQzwv+sXOp0/lfHk+3fxh1+N8hPRtZrwXSn4OsF8LlD8Q0Uutno5ig1ZUpSDdbNguZirOw7YcUZoco+2bC3DKWR3bd1kjJMXaI8o3HLBAbe5ULS9SI5GKJ0xyjg4crZ7QN2piqV6DMcFdHvU03ZPXA+oPGp4jwqhA2SUolVBnnchy45LxFOS3zAh2FI1UuuBucDl2YV29/gg7zFbYsG30ER3mCriKuXdsbI3dQK5gfJlB8nj+YFKXJW06X7smitcKLS/gTkwMP9XYG7QhTmLHRzOfuATGg2AECVpDibFC9lNLhqByvmg3IKt5GArFJM8vd+1uQ1qz2c1celi0HdBd9WRkSTBueTHBBLoeZ9fK0ZysVuY8AZ+sH4z589wFELgM7Dd2oafbM7FjOUwF0R23DBkwgbLbHgd5PP1YpJXpCGTXwc66ohzaHD+tAZKQsY4y1Cewl+phd4u9NAbGHpkQP8nF3JGlnS7pMeTgUmPz5e3Rd0qatcJBmY9MVg/IIE5gVcoC7tl2P5rX9C6gj01YH9BgNr+h7fPOhz6HU3vbA9g3+IFyYkgLLfvad2Rnwz9oua6F8lb3u1uxpyhX9c8k/dHyp61nmG1lbdrK4GWEw8g+06v2opWOK248tZ6Psf+vLrSjLqzejbVUiuvdI69QV/pGbupnlqBpRvWDQpLz6wvKKgWdruwmzSWnmmb0qkVWTrD3aCy9Izb1E+tzNIV7QadpWfapoJqdZZe0DcILT2jN/VUK7R0uDFrUFr6Be6ae3B7juWtWosfvrtzLK65A7day1UlXVXM+z3J4pqbbqu1dI598LMsrrn/tlpLN6wHP83imrtvq7V0BHv48yyuufm2WktnuAc/0eKau2+rtXRFe/gzLZc33PaFrTP0gx9q0Z+3WK2ln43Z4KdafBO4gRnnyQf58RVYMUVFQWKpg4illk1gCfj2m1x2WE9lPikKO+O2PLK22iqJOOgG1pMeEa7rTtLQfargcGJ853Wig8AE2JrH+NLUq3YC8RRfo5cdMAsbkGkfxxQJ8vM43iaO6gmPMm9H58/I6BLVQ1TzVL3qbDAG8oLjgaLpyUDVQhgDAXq0PWim6upswF50ErDvXIzLDy62h4sqgjrH9wzekPbmYa7fT/sr0lcaj/CaDPFjflgUV5RPi6Wgc+qd10LknaTK+MpaiMa/KKqWaiE4DbjfWgCz/iK1al5/1+vf/Q8= \ No newline at end of file diff --git a/docs/Profile Stack.png b/docs/Profile Stack.png deleted file mode 100644 index 0bcc9266b3..0000000000 Binary files a/docs/Profile Stack.png and /dev/null differ diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000000..0165e3d741 --- /dev/null +++ b/docs/index.md @@ -0,0 +1,21 @@ +Cura Documentation +==== +Welcome to the Cura documentation pages. + +Objective +---- +The goal of this documentation is to give an overview of the architecture of Cura's source code. The purpose of this overview is to make programmers familiar with Cura's source code so that they may contribute more easily, write plug-ins more easily or get started within the Cura team more quickly. + +There are some caveats though. These are *not* within the scope of this documentation: +* There is no documentation on individual functions or classes of the code here. For that, refer to the Doxygen documentation and Python Docstrings in the source code itself, or generate the documentation locally using Doxygen. +* It's virtually impossible and indeed not worth the effort or money to keep this 100% up to date. +* There are no example plug-ins here. There are a number of example plug-ins in the Ultimaker organisation on Github.com to draw from. +* The slicing process is not documented here. Refer to CuraEngine for that. + +This documentation will touch on the inner workings of Uranium as well though, due to the nature of the architecture. + +Index +---- +The following chapters are available in this documentation: +* [Repositories](repositories.md): An overview of the repositories that together make up the Cura application. +* [Profiles](profiles/profiles.md): About the setting and profile system of Cura. \ No newline at end of file diff --git a/docs/profiles/container_stacks.md b/docs/profiles/container_stacks.md new file mode 100644 index 0000000000..05fa5ba1d2 --- /dev/null +++ b/docs/profiles/container_stacks.md @@ -0,0 +1,33 @@ +Container Stacks +==== +When the user selects the profiles and settings to print with, he can swap out a number of profiles. The profiles that are currently in use are stored in several container stacks. These container stacks always have a definition container at the bottom, which defines all available settings and all available properties for each setting. The profiles on top of that definition can then override the `value` property of some of those settings. + +When deriving a setting value, a container stack starts looking at the top-most profile to see if it contains an override for that setting. If it does, it returns that override. Otherwise, it looks into the second profile. If that also doesn't have an override for this setting, it looks into the third profile, and so on. The last profile is always a definition container which always contains an value for all settings. This way, the profiles at the top will always win over the profiles at the bottom. There is a clear precedence order for which profile wins over which other profile. + +A Machine Instance +---- +A machine instance is a printer that the user has added to his configuration. It consists of multiple container stacks: One for global settings and one for each of the available extruders. This way, different extruders can contain different materials and quality profiles, for instance. The global stack contains a different set of profiles than the extruder stacks. + +While Uranium defines no specific roles for the entries in a container stack, Cura defines rigid roles for each slot in a container stack. These are the layouts for the container stacks of an example printer with 2 extruders. + +![Three container stacks](../resources/machine_instance.svg) + +To expand on this a bit further, each extruder stack contains the following profiles: +* A user profile, where extruder-specific setting changes are stored that are not (yet) saved to a custom profile. If the user changes a setting that can be adjusted per extruder (such as infill density) then it gets stored here. If the user adjusts a setting that is global it will immediately be stored in the user profile of the global stack. +* A custom profile. If the user saves his setting changes to a custom profile, it gets moved from the user profile to here. Actually a "custom profile" as the user sees it consists of multiple profiles: one for each extruder and one for the global settings. +* An intent profile. The user can select between several intents for his print, such as precision, strength, visual quality, etc. This may be empty as well, which indicates the "default" intent. +* A quality profile. The user can select between several quality levels. +* A material profile, where the user selects which material is loaded in this extruder. +* A nozzle profile, where the user selects which nozzle is installed in this extruder. +* Definition changes, which stores the changes that the user made for this extruder in the Printer Settings dialogue. +* Extruder. The user is not able to swap this out. This is a definition that lists the extruder number for this extruder and optionally things that are fixed in the printer, such as the nozzle offset. + +The global container stack contains the following profiles: +* A user profile, where global setting changes are stored that are not (yet) saved to a custom profile. If the user changes for instance the layer height, the new value for the layer height gets stored here. +* A custom profile. If the user saves his setting changes to a custom profile, the global settings that were in the global user profile get moved here. +* An intent profile. Currently this must ALWAYS be empty. There are no global intent profiles. This is there for historical reasons. +* A quality profile. This contains global settings that match with the quality level that the user selected. This global quality profile cannot be specific to a material or nozzle. +* A material profile. Currently this must ALWAYS be empty. There are no global material profiles. This is there for historical reasons. +* A variant profile. Currently this must ALWAYS be empty. There are no global variant profiles. This is there for historical reasons. +* Definition changes, which stores the changes that the user made to the printer in the Printer Settings dialogue. +* Printer. This specifies the currently used printer model, such as Ultimaker 3, Ultimaker S5, etc. \ No newline at end of file diff --git a/docs/profiles/getting_a_setting_value.md b/docs/profiles/getting_a_setting_value.md new file mode 100644 index 0000000000..49b8c18ed2 --- /dev/null +++ b/docs/profiles/getting_a_setting_value.md @@ -0,0 +1,66 @@ +Getting a Setting Value +==== +How Cura gets a setting's value is a complex endeavour that requires some explanation. The `value` property gets special treatment for this because there are a few other properties that influence the value. In this page we explain the algorithm to getting a setting value. + +This page explains all possible cases for a setting, but not all of them may apply. For instance, a global setting will not evaluate the per-object settings to get its value. Exceptions to the rules for other types of settings will be written down. + +Per Object Settings +---- +Per-object settings, which are added to an object using the per-object settings tool, will always prevail over other setting values. They are not evaluated with the rest of the settings system because Cura's front-end doesn't need to send all setting values for all objects to CuraEngine separately. It only sends over the per-object settings that get overridden. CuraEngine then evaluates settings that can be changed per-object using the list of settings for that object but if the object doesn't have the setting attached falls back on the settings in the object's extruder. Refer to the [CuraEngine](#CuraEngine) chapter to see how this works. + +Settings where the `settable_per_mesh` property is false will not be shown in Cura's interface in the list of available settings in the per-object settings panel. They cannot be adjusted per object then. CuraEngine will also not evaluate those settings for each object separately. There is (or should always be) a good reason why each of these settings are not evaluated per object: Simply because CuraEngine is not processing one particular mesh at that moment. For instance, when writing the move to change to the next layer, CuraEngine hasn't processed any of the meshes on that layer yet and so the layer change movement speed, or indeed the layer height, can't change for each object. + +The per-object settings are stored in a separate container stack that is particular to the object. The container stack is added to the object via a scene decorator. It has just a single container in it, which contains all of the settings that the user changed. + +Resolve +---- +If the setting is not listed in the per-object settings, it needs to be evaluated from the main settings list. However before evaluating it from a particular extruder, Cura will check if the setting has the `resolve` property. If it does, it returns the output of the `resolve` property and that's everything. + +The `resolve` property is intended for settings which are global in nature, but still need to be influenced by extruder-specific settings. A good example is the Build Plate Temperature, which is very dependent on the material(s) used by the printer, but there can only be a single bed temperature at a time. + +Cura will simply evaluate the `resolve` setting if present, which is an arbitrary Python expression, and return its result as the setting's value. However typically the `resolve` property is a function that takes the values of this setting for all extruders in use and then computes a result based on those. There is a built-in function for that called `extruderValues()`, which returns a list of setting values, one for each extruder. The function can then for instance take the average of those. In the case of the build plate temperature it will take the highest of those. In the case of the adhesion type it will choose "raft" if any extruder uses a raft, or "brim" as second choice, "skirt" as third choice and "none" only if all extruders use "none". Each setting with a `resolve` property has its own way of resolving the setting. The `extruderValues()` function continues with the algorithm as written below, but repeats it for each extruder. + +Limit To Extruder +---- +If a setting is evaluated from a particular extruder stack, it normally gets evaluated from the extruder that the object is assigned to. However there are some exceptions. Some groups of settings belong to a particular "extruder setting", like the Infill Extruder setting, or the Support Extruder setting. Which extruder a setting belongs to is stored in the `limit_to_extruder` property. Settings which have their `limit_to_extruder` property set to `adhesion_extruder_nr`, for instance, belong to the build plate adhesion settings. + +If the `limit_to_extruder` property evaluates to a positive number, instead of getting the setting from the object's extruder it will be obtained from the extruder written in the `limit_to_extruder` property. So even if an object is set to be printed with extruder 0, if the infill extruder is set to extruder 1 any infill setting will be obtained from extruder 1. If `limit_to_extruder` is negative (in particular -1, which is the default), then the setting will be obtained from the object's own extruder. + +This property is communicated to CuraEngine separately. CuraEngine makes sure that the setting is evaluated from the correct extruder. Refer to the [CuraEngine](#CuraEngine) chapter to see how this works. + +Evaluating a Stack +---- +After the resolve and limit to extruder properties have been checked, the setting value needs to be evaluated from an extruder stack. + +This is explained in more detail in the [Container Stacks](container_stacks.md) documentation. In brief, Cura will check the highest container in the extruder stack first to see whether that container overrides the setting. If it does, it returns that as the setting value. Otherwise, it checks the second container on the stack to see if that one overrides it. If it does it returns that value, and otherwise it checks the third container, and so on. If a setting is not overridden by any container in the extruder stack, it continues downward in the global stack. If it is also not overridden there, it eventually arrives at the definition in the bottom of the global stack. + +Evaluating a Definition +---- +If the evaluation for a setting reaches the last entry of the global stack, its definition, a few more things can happen. + +Definition containers have an inheritance structure. For instance, the `ultimaker3` definition container specifies in its metadata that it inherits from `ultimaker`, which in turn inherits from `fdmprinter`. So again here, when evaluating a property from the `ultimaker3` definition it will first look to see if the property is overridden by the `ultimaker3` definition itself, and otherwise refer on to the `ultimaker` definition or otherwise finally to the `fdmprinter` definition. `fdmprinter` is the last line of defence, and it contains *all* properties for *all* settings. + +But even in `fdmprinter`, not all settings have a `value` property. It is not a required property. If the setting doesn't have a `value` property, the `default_value` property is returned, which is a required property. The distinction between `value` and `default_value` is made in order to allow CuraEngine to load a definition file as well when running from the command line (a debugging technique for CuraEngine). It then won't have all of the correct setting values but it at least doesn't need to evaluate all of the Python expressions and you'll be able to make some debugging slices. + +Evaluating a Value Property +---- +The `value` property may contain a formula, which is an arbitrary Python expression that will be executed by Cura to arrive at a setting value. All containers may set the `value` property. Instance containers can only set the `value`, while definitions can set all properties. + +While the value could be any sort of formula, some functions of Python are restricted for security reasons. Since Cura 4.6, profiles are no longer a "trusted" resource and are therefore subject to heavy restrictions. It can use Python's built in mathematical functions and list functions as well as a few basic other ones, but things like writing to a file are prohibited. + +There are also a few extra things that can be used in these expressions: +* Any setting key can be used as a variable that contains the setting's value. +* As explained before, `extruderValues(key)` is a function that returns a list of setting values for a particular setting for all used extruders. +* The function `extruderValue(extruder, key)` will evaluate a particular setting for a particular extruder. +* The function `resolveOrValue(key)` will perform the full setting evaluation as described in this document for the current context (so if this setting is being evaluated for the second extruder it would perform it as if coming from the second extruder). +* The function `defaultExtruderPosition()` will get the first extruder that is not disabled. For instance, if a printer has three extruders but the first is disabled, this would return `1` to indicate the second extruder (0-indexed). +* The function `valueFromContainer(key, index)` will get a setting value from the global stack, but skip the first few containers in that stack. It will skip until it reaches a particular index in the container stack. +* The function `valueFromExtruderContainer(key, index)` will get a setting value from the current extruder stack, but skip the first few containers in that stack. It will skip until it reaches a particular index in the container stack. + +CuraEngine +---- +When starting a slice, Cura will send the scene to CuraEngine and with each model send over the per-object settings that belong to it. It also sends all setting values over, as evaluated from each extruder and from the global stack, and sends the `limit_to_extruder` property along as well. CuraEngine stores this and then starts its slicing process. CuraEngine also has a hierarchical structure for its settings with fallbacks. This is explained in detail in [the documentation of CuraEngine](https://github.com/Ultimaker/CuraEngine/blob/master/docs/settings.md) and shortly again here. + +Each model gets a setting container assigned. The per-object settings are stored in those. The fallback for this container is set to be the extruder with which the object is printed. The extruder uses the current *mesh group* as fallback (which is a concept that Cura's front-end doesn't have). Each mesh group uses the global settings container as fallback. + +During the slicing process CuraEngine will evaluate the settings from its current context as it goes. For instance, when processing the walls for a particular mesh, it will request the Outer Wall Line Width setting from the settings container of that mesh. When it's not processing a particular mesh but for instance the travel moves between two meshes, it uses the currently applicable extruder. So this business logic defines actually how a setting can be configured per mesh, per extruder or only globally. The `settable_per_extruder`, and related properties of settings are only used in the front-end to determine how the settings are shown to the user. \ No newline at end of file diff --git a/docs/profiles/profiles.md b/docs/profiles/profiles.md new file mode 100644 index 0000000000..544184d480 --- /dev/null +++ b/docs/profiles/profiles.md @@ -0,0 +1,30 @@ +Profiles +==== +Cura's profile system is very advanced and has gotten pretty complex. This chapter is an attempt to document how it is structured. + +Index +---- +The following pages describe the profile and setting system of Cura: +* [Container Stacks](container_stacks.md): Which profiles can be swapped out and how they are ordered when evaluating a setting. +* [Setting Properties](setting_properties.md): What properties can each setting have? +* [Getting a Setting Value](getting_a_setting_value.md): How Cura arrives at a value for a certain setting. + +Glossary +---- +The terminology for these profiles is not always obvious. Here is a glossary of the terms that we'll use in this chapter. +* **Profile:** Either an *instance container* or a *definition container*. +* **Definition container:** Profile that's stored as .def.json file, defining new settings and all of their properties. In Cura these represent printer models and extruder trains. +* **Instance container:** Profile that's stored as .inst.cfg file or .xml.fdm_material file, which override some setting values. In Cura these represent the other profiles. +* **[Container] stack:** A list of profiles, with one definition container at the bottom and instance containers for the rest. All settings are defined in the definition container. The rest of the profiles each specify a set of value overrides. The profiles at the top always override the profiles at the bottom. +* **Machine instance:** An instance of a printer that the user has added. The list of all machine instances is shown in a drop-down in Cura's interface. +* **Material:** A type of filament that's being sold by a vendor as a product. +* **Filament spool:** A single spool of material. +* **Quality profile:** A profile that is one of the options when the user selects which quality level they want to print with. +* **Intent profile:** A profile that is one of the options when the user selects what his intent is. +* **Custom profile:** A user-made profile that is stored when the user selects to "create a profile from the current settings/overrides". +* **Quality-changes profile:** Alternative name for *custom profile*. This name is used in the code more often, but it's a bit misleading so this documentation prefers the term "custom profile". +* **User profile:** A profile containing the settings that the user has changed, but not yet saved to a profile. +* **Variant profile:** A profile containing some overrides that allow the user to select variants of the definition. As of this writing this is only used for the nozzles. +* **Quality level:** A measure of quality where the user can select from, for instance "normal", "fast", "high". When selecting a quality level, Cura will select a matching quality profile for each extruder. +* **Quality type:** Alternative name for *quality level*. This name is used in the code more often, but this documentation prefers the term "quality level". +* **Inheritance function:** A function through which the `value` of a setting is calculated. This may depend on other settings. \ No newline at end of file diff --git a/docs/profiles/setting_properties.md b/docs/profiles/setting_properties.md new file mode 100644 index 0000000000..84fb458c63 --- /dev/null +++ b/docs/profiles/setting_properties.md @@ -0,0 +1,33 @@ +Setting Properties +==== +Each setting in Cura has a number of properties. It's not just a key and a value. This page lists the properties that a setting can define. + +* `key` (string): The identifier by which the setting is referenced. This is not a human-readable name, but just a reference string, such as `layer_height_0`. Typically these are named with the most significant category first, in order to sort them better, such as `material_print_temperature`. This is not actually a real property but just an identifier; it can't be changed. +* `value` (optional): The current value of the setting. This can be a function, an arbitrary Python expression that depends on the values of other settings. If it's not present, the `default_value` is used. +* `default_value`: A default value for the setting if `value` is undefined. This property is required however. It can't be a Python expression, but it can be any JSON type. This is made separate so that CuraEngine can read it out as well for its debugging mode via the command line, without needing a complete Python interpreter. +* `label` (string): The human-readable name for the setting. This label is translated. +* `description` (string): A longer description of what the setting does when you change it. This description is translated as well. +* `type` (string): The type of value that this setting contains. Allowed types are: `bool`, `str`, `float`, `int`, `enum`, `category`, `[int]`, `vec3`, `polygon` and `polygons`. +* `unit` (optional string): A unit that is displayed at the right-hand side of the text field where the user enters the setting value. +* `resolve` (optional string): A Python expression that resolves disagreements for global settings if multiple per-extruder profiles define different values for a setting. Typically this takes the values for the setting from all stacks and computes one final value for it that will be used for the global setting. For instance, the `resolve` function for the build plate temperature is `max(extruderValues('material_bed_temperature')`, meaning that it will use the hottest bed temperature of all materials of the extruders in use. +* `limit_to_extruder` (optional): A Python expression that indicates which extruder a setting will be obtained from. This is used for settings that may be extruder-specific but the extruder is not necessarily the current extruder. For instance, support settings need to be evaluated for the support extruder. Infill settings need to be evaluated for the infill extruder if the infill extruder is changed. +* `enabled` (optional string or boolean): Whether the setting can currently be made visible for the user. This can be a simple true/false, or a Python expression that depends on other settings. Typically used for settings that don't apply when another setting is disabled, such as to hide the support settings if support is disabled. +* `minimum_value` (optional): The lowest acceptable value for this setting. If it's any lower, Cura will not allow the user to slice. By convention this is used to prevent setting values that are technically or physically impossible, such as a layer height of 0mm. This property only applies to numerical settings. +* `maximum_value` (optional): The highest acceptable value for this setting. If it's any higher, Cura will not allow the user to slice. By convention this is used to prevent setting values that are technically or physically impossible, such as a support overhang angle of more than 90 degrees. This property only applies to numerical settings. +* `minimum_value_warning` (optional): The threshold under which a warning is displayed to the user. By convention this is used to indicate that it will probably not print very nicely with such a low setting value. This property only applies to numerical settings. +* `maximum_value_warning` (optional): The threshold above which a warning is displayed to the user. By convention this is used to indicate that it will probably not print very nicely with such a high setting value. This property only applies to numerical settings. +* `settable_globally` (optional boolean): Whether the setting can be changed globally. For some mesh-type settings such as `support_mesh` this doesn't make sense, so those can't be changed globally. They are not displayed in the main settings list then. +* `settable_per_meshgroup` (optional boolean): Whether a setting can be changed per group of meshes. Currently unused in Cura. +* `settable_per_extruder` (optional boolean): Whether a setting can be changed per extruder. Some settings, like the build plate temperature, can't be adjusted separately for each extruder. An icon is shown in the interface to indicate this. If the user changes these settings they are stored in the global stack. +* `settable_per_mesh` (optional boolean): Whether a setting can be changed per mesh. The settings that can be changed per mesh are shown in the list of available settings in the per-object settings tool. +* `children` (optional list): A list of child settings. These are displayed with an indentation. If all child settings are overridden by the user, the parent setting gets greyed out to indicate that the parent setting has no effect any more. This is not strictly always the case though, because that would depend on the inheritance functions in the `value`. +* `icon` (optional string): A path to an icon to be displayed. Only applies to setting categories. +* `allow_empty` (optional bool): Whether the setting is allowed to be empty. If it's not, this will be treated as a setting error and Cura will not allow the user to slice. Only applies to string-type settings. +* `warning_description` (optional string): A warning message to display when the setting has a warning value. This is currently unused by Cura. +* `error_description` (optional string): An error message to display when the setting has an error value. This is currently unused by Cura. +* `options` (dictionary): A list of values that the user can choose from. The keys of this dictionary are keys that CuraEngine identifies the option with. The values are human-readable strings and will be translated. Only applies to (and only required for) enum-type settings. +* `comments` (optional string): Comments to other programmers about the setting. This is not used by Cura. +* `is_uuid` (optional boolean): Whether or not this setting indicates a UUID-4. If it is, the setting will indicate an error if it's not in the correct format. Only applies to string-type settings. +* `regex_blacklist_pattern` (optional string): A regular expression, where if the setting value matches with this regular expression, it gets an error state. Only applies to string-type settings. +* `error_value` (optional): If the setting value is equal to this value, it will show a setting error. This is used to display errors for non-numerical settings such as checkboxes. +* `warning_value` (optional): If the setting value is equal to this value, it will show a setting warning. This is used to display warnings for non-numerical settings such as checkboxes. \ No newline at end of file diff --git a/docs/repositories.md b/docs/repositories.md new file mode 100644 index 0000000000..3b4c4bc317 --- /dev/null +++ b/docs/repositories.md @@ -0,0 +1,21 @@ +Repositories +==== +Cura uses a number of repositories where parts of our source code are separated, in order to get a cleaner architecture. Those repositories are: +* [Cura](https://github.com/Ultimaker/Cura), the main repository for the front-end of Cura. This contains all of the business logic for the front-end, including the specific types of profiles that are available, the concept of 3D printers and materials, specific tools for handling 3D printed models, pretty much all of the GUI, as well as Ultimaker services such as the Marketplace and accounts. +* The Cura repository is built on [Uranium](https://github.com/Ultimaker/Uranium), a framework for desktop applications that handle 3D models and have a separate back-end. This provides Cura with a basic GUI framework ([Qt](https://www.qt.io/)), a 3D scene, a rendering system, a plug-in system and a system for stacked profiles that change settings. +* In order to slice, Cura starts [CuraEngine](https://github.com/Ultimaker/CuraEngine) in the background. This does the actual process that converts 3D models into a toolpath for the printer. +* Communication to CuraEngine goes via [libArcus](https://github.com/Ultimaker/libArcus), a small library that wraps around [Protobuf](https://developers.google.com/protocol-buffers/) in order to make it run over a local socket. +* Cura's build scripts are in [cura-build](https://github.com/Ultimaker/cura-build) and build scripts for building dependencies are in [cura-build-environment](https://github.com/Ultimaker/cura-build-environment). + +There are also a number of repositories under our control that are not integral parts of Cura's architecture, but more like separated side-gigs: +* Loading and writing 3MF files is done through [libSavitar](https://github.com/Ultimaker/libSavitar). +* Loading and writing UFP files is done through [libCharon](https://github.com/Ultimaker/libCharon). +* To make the build system a bit simpler, some parts are pre-compiled in [cura-binary-data](https://github.com/Ultimaker/cura-binary-data). This holds things like the machine-readable translation files and the Marlin builds for firmware updates, which would require considerable tooling to build automatically. +* There are automated GUI tests in [Cura-squish-tests](https://github.com/Ultimaker/Cura-squish-tests). +* Material profiles are stored in [fdm_materials](https://github.com/Ultimaker/fdm_materials). This is separated out and combined in our build process, so that the firmware for Ultimaker's printers can use the same set of profiles too. + +Interplay +---- +At a very high level, Cura's repositories interconnect as follows: + +![Overview of interplay between repositories](resources/repositories.svg) \ No newline at end of file diff --git a/docs/resources/machine_instance.svg b/docs/resources/machine_instance.svg new file mode 100644 index 0000000000..a215a7b5a4 --- /dev/null +++ b/docs/resources/machine_instance.svg @@ -0,0 +1,55 @@ + + + + + + + + + + + + + + + + + + + + + Global stack + User + Custom + Intent + Quality + Material + Variant + Definition changes + Printer + + Left extruder + User + Custom + Intent + Quality + Material + Nozzle + Definition changes + Extruder + + Right extruder + User + Custom + Intent + Quality + Material + Nozzle + Definition changes + Extruder + + + + + + \ No newline at end of file diff --git a/docs/resources/repositories.svg b/docs/resources/repositories.svg new file mode 100644 index 0000000000..4f4ad740f3 --- /dev/null +++ b/docs/resources/repositories.svg @@ -0,0 +1,70 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Cura + Uranium + CuraEngine + + + libSavitar + fdm_materials + libArcus + libCharon + + + G-code + UFP + G-code + Model + Built upon + + + Scene + 3MF + + + + \ No newline at end of file diff --git a/plugins/Toolbox/resources/images/logobot.svg b/plugins/Toolbox/resources/images/logobot.svg deleted file mode 100644 index 8234f66887..0000000000 --- a/plugins/Toolbox/resources/images/logobot.svg +++ /dev/null @@ -1,161 +0,0 @@ - - - - -logo -Created with Sketch. - - - - - - - - - - - - diff --git a/plugins/Toolbox/resources/qml/pages/WelcomePage.qml b/plugins/Toolbox/resources/qml/pages/WelcomePage.qml index cbfdf8f402..04110cbc0f 100644 --- a/plugins/Toolbox/resources/qml/pages/WelcomePage.qml +++ b/plugins/Toolbox/resources/qml/pages/WelcomePage.qml @@ -16,19 +16,10 @@ Column height: childrenRect.height anchors.centerIn: parent - Image - { - id: profileImage - fillMode: Image.PreserveAspectFit - source: "../../images/logobot.svg" - anchors.horizontalCenter: parent.horizontalCenter - width: Math.round(parent.width / 4) - } - Label { id: welcomeTextLabel - text: catalog.i18nc("@description", "Get plugins and materials verified by Ultimaker") + text: catalog.i18nc("@description", "Please sign in to get verified plugins and materials for Ultimaker Cura Enterprise") width: Math.round(parent.width / 2) font: UM.Theme.getFont("default") color: UM.Theme.getColor("text") diff --git a/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py b/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py index 536385b19d..c66f61596a 100644 --- a/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py +++ b/plugins/VersionUpgrade/VersionUpgrade21to22/VersionUpgrade21to22.py @@ -236,23 +236,11 @@ _variant_translations_materials = { } } # type: Dict[str, Dict[str, str]] + ## Converts configuration from Cura 2.1's file formats to Cura 2.2's. # # It converts the machine instances and profiles. class VersionUpgrade21to22(VersionUpgrade): - ## Gets the version number from a config file. - # - # In all config files that concern this version upgrade, the version - # number is stored in general/version, so get the data from that key. - # - # \param serialised The contents of a config file. - # \return The version number of that config file. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version ## Gets the fallback quality to use for a specific machine-variant-material # combination. diff --git a/plugins/VersionUpgrade/VersionUpgrade25to26/VersionUpgrade25to26.py b/plugins/VersionUpgrade/VersionUpgrade25to26/VersionUpgrade25to26.py index 6dbcfebc46..2cb0cf3ba4 100644 --- a/plugins/VersionUpgrade/VersionUpgrade25to26/VersionUpgrade25to26.py +++ b/plugins/VersionUpgrade/VersionUpgrade25to26/VersionUpgrade25to26.py @@ -19,6 +19,7 @@ _split_settings = { #These settings should be copied to all settings it was spli "support_interface_line_distance": {"support_roof_line_distance", "support_bottom_line_distance"} } # type: Dict[str, Set[str]] + ## A collection of functions that convert the configuration of the user in Cura # 2.5 to a configuration for Cura 2.6. # @@ -28,24 +29,6 @@ class VersionUpgrade25to26(VersionUpgrade): super().__init__() self._current_fdm_printer_count = 2 - ## Gets the version number from a CFG file in Uranium's 2.5 format. - # - # Since the format may change, this is implemented for the 2.5 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades the preferences file from version 2.5 to 2.6. # # \param serialised The serialised form of a preferences file. diff --git a/plugins/VersionUpgrade/VersionUpgrade25to26/tests/TestVersionUpgrade25to26.py b/plugins/VersionUpgrade/VersionUpgrade25to26/tests/TestVersionUpgrade25to26.py index 45cdaebe87..0c5b983b14 100644 --- a/plugins/VersionUpgrade/VersionUpgrade25to26/tests/TestVersionUpgrade25to26.py +++ b/plugins/VersionUpgrade/VersionUpgrade25to26/tests/TestVersionUpgrade25to26.py @@ -63,74 +63,6 @@ setting_version = -3 } ] -## Tests the technique that gets the version number from CFG files. -# -# \param data The parametrised data to test with. It contains a test name -# to debug with, the serialised contents of a CFG file and the correct -# version number in that CFG file. -# \param upgrader The instance of the upgrade class to test. -@pytest.mark.parametrize("data", test_cfg_version_good_data) -def test_cfgVersionGood(data, upgrader): - version = upgrader.getCfgVersion(data["file_data"]) - assert version == data["version"] - -test_cfg_version_bad_data = [ - { - "test_name": "Empty", - "file_data": "", - "exception": configparser.Error #Explicitly not specified further which specific error we're getting, because that depends on the implementation of configparser. - }, - { - "test_name": "No General", - "file_data": """[values] -layer_height = 0.1337 -""", - "exception": configparser.Error - }, - { - "test_name": "No Version", - "file_data": """[general] -true = false -""", - "exception": configparser.Error - }, - { - "test_name": "Not a Number", - "file_data": """[general] -version = not-a-text-version-number -""", - "exception": ValueError - }, - { - "test_name": "Setting Value NaN", - "file_data": """[general] -version = 4 -[metadata] -setting_version = latest_or_something -""", - "exception": ValueError - }, - { - "test_name": "Major-Minor", - "file_data": """[general] -version = 1.2 -""", - "exception": ValueError - } -] - -## Tests whether getting a version number from bad CFG files gives an -# exception. -# -# \param data The parametrised data to test with. It contains a test name -# to debug with, the serialised contents of a CFG file and the class of -# exception it needs to throw. -# \param upgrader The instance of the upgrader to test. -@pytest.mark.parametrize("data", test_cfg_version_bad_data) -def test_cfgVersionBad(data, upgrader): - with pytest.raises(data["exception"]): - upgrader.getCfgVersion(data["file_data"]) - test_upgrade_preferences_removed_settings_data = [ { "test_name": "Removed Setting", diff --git a/plugins/VersionUpgrade/VersionUpgrade26to27/VersionUpgrade26to27.py b/plugins/VersionUpgrade/VersionUpgrade26to27/VersionUpgrade26to27.py index 39e3dea4ed..a4a6182ea0 100644 --- a/plugins/VersionUpgrade/VersionUpgrade26to27/VersionUpgrade26to27.py +++ b/plugins/VersionUpgrade/VersionUpgrade26to27/VersionUpgrade26to27.py @@ -64,29 +64,12 @@ _renamed_quality_profiles = { "um3_bb0.8_TPU_Not_Supported_Superdraft_Quality": "um3_bb0.8_TPU_Superdraft_Print", } # type: Dict[str, str] + ## A collection of functions that convert the configuration of the user in Cura # 2.6 to a configuration for Cura 2.7. # # All of these methods are essentially stateless. class VersionUpgrade26to27(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 2.6 format. - # - # Since the format may change, this is implemented for the 2.6 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades a preferences file from version 2.6 to 2.7. # # \param serialised The serialised form of a preferences file. diff --git a/plugins/VersionUpgrade/VersionUpgrade26to27/tests/TestVersionUpgrade26to27.py b/plugins/VersionUpgrade/VersionUpgrade26to27/tests/TestVersionUpgrade26to27.py index 6235578238..1465df01e7 100644 --- a/plugins/VersionUpgrade/VersionUpgrade26to27/tests/TestVersionUpgrade26to27.py +++ b/plugins/VersionUpgrade/VersionUpgrade26to27/tests/TestVersionUpgrade26to27.py @@ -35,13 +35,6 @@ infill_sparse_density = 42 """, "version": 3000000 }, - { - "test_name": "Negative Version", #Why not? - "file_data": """[general] -version = -20 -""", - "version": -20000000 - }, { "test_name": "Setting Version", "file_data": """[general] @@ -50,15 +43,6 @@ version = 1 setting_version = 1 """, "version": 1000001 - }, - { - "test_name": "Negative Setting Version", - "file_data": """[general] -version = 1 -[metadata] -setting_version = -3 -""", - "version": 999997 } ] @@ -73,62 +57,6 @@ def test_cfgVersionGood(data, upgrader): version = upgrader.getCfgVersion(data["file_data"]) assert version == data["version"] -test_cfg_version_bad_data = [ - { - "test_name": "Empty", - "file_data": "", - "exception": configparser.Error #Explicitly not specified further which specific error we're getting, because that depends on the implementation of configparser. - }, - { - "test_name": "No General", - "file_data": """[values] -layer_height = 0.1337 -""", - "exception": configparser.Error - }, - { - "test_name": "No Version", - "file_data": """[general] -true = false -""", - "exception": configparser.Error - }, - { - "test_name": "Not a Number", - "file_data": """[general] -version = not-a-text-version-number -""", - "exception": ValueError - }, - { - "test_name": "Setting Value NaN", - "file_data": """[general] -version = 4 -[metadata] -setting_version = latest_or_something -""", - "exception": ValueError - }, - { - "test_name": "Major-Minor", - "file_data": """[general] -version = 1.2 -""", - "exception": ValueError - } -] - -## Tests whether getting a version number from bad CFG files gives an -# exception. -# -# \param data The parametrised data to test with. It contains a test name -# to debug with, the serialised contents of a CFG file and the class of -# exception it needs to throw. -# \param upgrader The instance of the upgrader to test. -@pytest.mark.parametrize("data", test_cfg_version_bad_data) -def test_cfgVersionBad(data, upgrader): - with pytest.raises(data["exception"]): - upgrader.getCfgVersion(data["file_data"]) test_upgrade_stacks_with_not_supported_data = [ { diff --git a/plugins/VersionUpgrade/VersionUpgrade30to31/VersionUpgrade30to31.py b/plugins/VersionUpgrade/VersionUpgrade30to31/VersionUpgrade30to31.py index f0b2e939b9..0b2e1d83f7 100644 --- a/plugins/VersionUpgrade/VersionUpgrade30to31/VersionUpgrade30to31.py +++ b/plugins/VersionUpgrade/VersionUpgrade30to31/VersionUpgrade30to31.py @@ -62,24 +62,6 @@ _RENAMED_DEFINITION_DICT = { class VersionUpgrade30to31(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 3.0 format. - # - # Since the format may change, this is implemented for the 3.0 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades a preferences file from version 3.0 to 3.1. # # \param serialised The serialised form of a preferences file. diff --git a/plugins/VersionUpgrade/VersionUpgrade32to33/VersionUpgrade32to33.py b/plugins/VersionUpgrade/VersionUpgrade32to33/VersionUpgrade32to33.py index 83cb15c864..68854041ae 100644 --- a/plugins/VersionUpgrade/VersionUpgrade32to33/VersionUpgrade32to33.py +++ b/plugins/VersionUpgrade/VersionUpgrade32to33/VersionUpgrade32to33.py @@ -68,24 +68,6 @@ _RENAMED_QUALITY_TYPES = { class VersionUpgrade32to33(VersionUpgrade): temporary_group_name_counter = 1 - ## Gets the version number from a CFG file in Uranium's 3.2 format. - # - # Since the format may change, this is implemented for the 3.2 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades a preferences file from version 3.2 to 3.3. # # \param serialised The serialised form of a preferences file. diff --git a/plugins/VersionUpgrade/VersionUpgrade33to34/VersionUpgrade33to34.py b/plugins/VersionUpgrade/VersionUpgrade33to34/VersionUpgrade33to34.py index 704ede02d6..acca39942d 100644 --- a/plugins/VersionUpgrade/VersionUpgrade33to34/VersionUpgrade33to34.py +++ b/plugins/VersionUpgrade/VersionUpgrade33to34/VersionUpgrade33to34.py @@ -14,24 +14,6 @@ _renamed_settings = { ## Upgrades configurations from the state they were in at version 3.3 to the # state they should be in at version 3.4. class VersionUpgrade33to34(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 3.3 format. - # - # Since the format may change, this is implemented for the 3.3 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades instance containers to have the new version # number. def upgradeInstanceContainer(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: diff --git a/plugins/VersionUpgrade/VersionUpgrade34to35/VersionUpgrade34to35.py b/plugins/VersionUpgrade/VersionUpgrade34to35/VersionUpgrade34to35.py index 8e45d7cf73..30dae3883f 100644 --- a/plugins/VersionUpgrade/VersionUpgrade34to35/VersionUpgrade34to35.py +++ b/plugins/VersionUpgrade/VersionUpgrade34to35/VersionUpgrade34to35.py @@ -63,24 +63,6 @@ _RENAMED_MATERIAL_PROFILES = { ## Upgrades configurations from the state they were in at version 3.4 to the # state they should be in at version 3.5. class VersionUpgrade34to35(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 3.4 format. - # - # Since the format may change, this is implemented for the 3.4 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades Preferences to have the new version number. def upgradePreferences(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: parser = configparser.ConfigParser(interpolation = None) diff --git a/plugins/VersionUpgrade/VersionUpgrade35to40/VersionUpgrade35to40.py b/plugins/VersionUpgrade/VersionUpgrade35to40/VersionUpgrade35to40.py index 71ce2e4fd0..fdca7d15df 100644 --- a/plugins/VersionUpgrade/VersionUpgrade35to40/VersionUpgrade35to40.py +++ b/plugins/VersionUpgrade/VersionUpgrade35to40/VersionUpgrade35to40.py @@ -34,13 +34,6 @@ class VersionUpgrade35to40(VersionUpgrade): parser.write(result) return [filename], [result.getvalue()] - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades Preferences to have the new version number. def upgradePreferences(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: parser = configparser.ConfigParser(interpolation=None) diff --git a/plugins/VersionUpgrade/VersionUpgrade40to41/VersionUpgrade40to41.py b/plugins/VersionUpgrade/VersionUpgrade40to41/VersionUpgrade40to41.py index b63d1842b7..1cccbef7da 100644 --- a/plugins/VersionUpgrade/VersionUpgrade40to41/VersionUpgrade40to41.py +++ b/plugins/VersionUpgrade/VersionUpgrade40to41/VersionUpgrade40to41.py @@ -23,24 +23,6 @@ _renamed_quality_profiles = { ## Upgrades configurations from the state they were in at version 4.0 to the # state they should be in at version 4.1. class VersionUpgrade40to41(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 4.0 format. - # - # Since the format may change, this is implemented for the 4.0 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) #Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades instance containers to have the new version # number. def upgradeInstanceContainer(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: diff --git a/plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py b/plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py index 4b7e291482..43d8561567 100644 --- a/plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py +++ b/plugins/VersionUpgrade/VersionUpgrade41to42/VersionUpgrade41to42.py @@ -213,27 +213,10 @@ _creality_limited_quality_type = { "extra_coarse": "draft" } + ## Upgrades configurations from the state they were in at version 4.1 to the # state they should be in at version 4.2. class VersionUpgrade41to42(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 4.1 format. - # - # Since the format may change, this is implemented for the 4.1 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades instance containers to have the new version # number. # diff --git a/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py b/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py index 4142053047..b139ede83c 100644 --- a/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py +++ b/plugins/VersionUpgrade/VersionUpgrade42to43/VersionUpgrade42to43.py @@ -56,27 +56,10 @@ _renamed_settings = { "support_infill_angle": "support_infill_angles" } # type: Dict[str, str] + ## Upgrades configurations from the state they were in at version 4.2 to the # state they should be in at version 4.3. class VersionUpgrade42to43(VersionUpgrade): - ## Gets the version number from a CFG file in Uranium's 4.2 format. - # - # Since the format may change, this is implemented for the 4.2 format only - # and needs to be included in the version upgrade system rather than - # globally in Uranium. - # - # \param serialised The serialised form of a CFG file. - # \return The version number stored in the CFG file. - # \raises ValueError The format of the version number in the file is - # incorrect. - # \raises KeyError The format of the file is incorrect. - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - def upgradePreferences(self, serialized: str, filename: str): parser = configparser.ConfigParser(interpolation = None) parser.read_string(serialized) diff --git a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py index f3453527bc..b5825af62e 100644 --- a/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py +++ b/plugins/VersionUpgrade/VersionUpgrade43to44/VersionUpgrade43to44.py @@ -26,12 +26,6 @@ _renamed_container_id_map = { class VersionUpgrade43to44(VersionUpgrade): - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version ## Upgrades Preferences to have the new version number. # diff --git a/plugins/VersionUpgrade/VersionUpgrade44to45/VersionUpgrade44to45.py b/plugins/VersionUpgrade/VersionUpgrade44to45/VersionUpgrade44to45.py index f300cb1c2d..0747ad280b 100644 --- a/plugins/VersionUpgrade/VersionUpgrade44to45/VersionUpgrade44to45.py +++ b/plugins/VersionUpgrade/VersionUpgrade44to45/VersionUpgrade44to45.py @@ -122,13 +122,6 @@ class VersionUpgrade44to45(VersionUpgrade): except OSError: # Is a directory, file not found, or insufficient rights. continue - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version - ## Upgrades Preferences to have the new version number. # # This renames the renamed settings in the list of visible settings. diff --git a/plugins/VersionUpgrade/VersionUpgrade45to46/VersionUpgrade45to46.py b/plugins/VersionUpgrade/VersionUpgrade45to46/VersionUpgrade45to46.py index 2234dd35f5..f62264c3e7 100644 --- a/plugins/VersionUpgrade/VersionUpgrade45to46/VersionUpgrade45to46.py +++ b/plugins/VersionUpgrade/VersionUpgrade45to46/VersionUpgrade45to46.py @@ -10,14 +10,8 @@ _removed_settings = { "machine_filament_park_distance", } -class VersionUpgrade45to46(VersionUpgrade): - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version +class VersionUpgrade45to46(VersionUpgrade): def upgradePreferences(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: """ Upgrades preferences to have the new version number. diff --git a/plugins/VersionUpgrade/VersionUpgrade46to47/VersionUpgrade46to47.py b/plugins/VersionUpgrade/VersionUpgrade46to47/VersionUpgrade46to47.py index a8a4142dfc..52ae10a122 100644 --- a/plugins/VersionUpgrade/VersionUpgrade46to47/VersionUpgrade46to47.py +++ b/plugins/VersionUpgrade/VersionUpgrade46to47/VersionUpgrade46to47.py @@ -6,14 +6,8 @@ from typing import Tuple, List import io from UM.VersionUpgrade import VersionUpgrade -class VersionUpgrade46to47(VersionUpgrade): - def getCfgVersion(self, serialised: str) -> int: - parser = configparser.ConfigParser(interpolation = None) - parser.read_string(serialised) - format_version = int(parser.get("general", "version")) # Explicitly give an exception when this fails. That means that the file format is not recognised. - setting_version = int(parser.get("metadata", "setting_version", fallback = "0")) - return format_version * 1000000 + setting_version +class VersionUpgrade46to47(VersionUpgrade): def upgradePreferences(self, serialized: str, filename: str) -> Tuple[List[str], List[str]]: """ Upgrades preferences to have the new version number. diff --git a/resources/definitions/Mark2_for_Ultimaker2.def.json b/resources/definitions/Mark2_for_Ultimaker2.def.json index 6867183081..55f2f1611e 100644 --- a/resources/definitions/Mark2_for_Ultimaker2.def.json +++ b/resources/definitions/Mark2_for_Ultimaker2.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "TheUltimakerCommunity", "manufacturer": "Foehnsturm", - "category": "Other", "weight": 0, "has_variants": true, "has_materials": true, diff --git a/resources/definitions/alya3dp.def.json b/resources/definitions/alya3dp.def.json index 8de7c79641..937cc7d6fa 100644 --- a/resources/definitions/alya3dp.def.json +++ b/resources/definitions/alya3dp.def.json @@ -7,7 +7,6 @@ "visible": true, "author": "ALYA", "manufacturer": "Kati Hal ARGE", - "category": "Other", "file_formats": "text/x-gcode", "platform": "alya_platform.stl", "platform_offset": [-60, -45, 75 ], diff --git a/resources/definitions/alyanx3dp.def.json b/resources/definitions/alyanx3dp.def.json index 07e0a090a9..9e9f013ba2 100644 --- a/resources/definitions/alyanx3dp.def.json +++ b/resources/definitions/alyanx3dp.def.json @@ -7,7 +7,6 @@ "visible": true, "author": "ALYA", "manufacturer": "Kati Hal ARGE", - "category": "Other", "file_formats": "text/x-gcode", "platform": "alya_nx_platform.stl", "platform_offset": [-104, 0, 93 ], diff --git a/resources/definitions/anet3d.def.json b/resources/definitions/anet3d.def.json index 1381a6c6ee..990be55463 100644 --- a/resources/definitions/anet3d.def.json +++ b/resources/definitions/anet3d.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Tiger.He", "manufacturer": "Anet", - "category": "anet3d", "visible": false, "file_formats": "text/x-gcode", "first_start_actions": ["MachineSettingsAction"], diff --git a/resources/definitions/anycubic_4max.def.json b/resources/definitions/anycubic_4max.def.json index 05fffcb206..1be7dc0cab 100644 --- a/resources/definitions/anycubic_4max.def.json +++ b/resources/definitions/anycubic_4max.def.json @@ -7,7 +7,6 @@ "visible": true, "author": "Jason Scurtu", "manufacturer": "Anycubic", - "category": "Other", "file_formats": "text/x-gcode", "icon": "icon_ultimaker2", "platform": "anycubic_4max_platform.stl", diff --git a/resources/definitions/anycubic_chiron.def.json b/resources/definitions/anycubic_chiron.def.json index 1b18a936a7..97d39b439c 100644 --- a/resources/definitions/anycubic_chiron.def.json +++ b/resources/definitions/anycubic_chiron.def.json @@ -7,7 +7,6 @@ "visible": true, "author": "Patrick Glatt", "manufacturer": "Anycubic", - "category": "Other", "file_formats": "text/x-gcode", "icon": "icon_ultimaker2", "platform": "anycubic_chiron_platform.obj", diff --git a/resources/definitions/bibo2_dual.def.json b/resources/definitions/bibo2_dual.def.json index a644185915..b9b1164e9d 100644 --- a/resources/definitions/bibo2_dual.def.json +++ b/resources/definitions/bibo2_dual.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "unknown", "manufacturer": "BIBO", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": { diff --git a/resources/definitions/builder_premium_large.def.json b/resources/definitions/builder_premium_large.def.json index d19382a591..cf880ec63a 100644 --- a/resources/definitions/builder_premium_large.def.json +++ b/resources/definitions/builder_premium_large.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Builder SZ", "manufacturer": "Builder", - "category": "Other", "quality_definition": "builder_premium_small", "file_formats": "text/x-gcode", "platform": "builder_premium_platform.stl", diff --git a/resources/definitions/builder_premium_medium.def.json b/resources/definitions/builder_premium_medium.def.json index e5b8f1785c..28d9f04a67 100644 --- a/resources/definitions/builder_premium_medium.def.json +++ b/resources/definitions/builder_premium_medium.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Builder SZ", "manufacturer": "Builder", - "category": "Other", "quality_definition": "builder_premium_small", "file_formats": "text/x-gcode", "platform": "builder_premium_platform.stl", diff --git a/resources/definitions/builder_premium_small.def.json b/resources/definitions/builder_premium_small.def.json index 4bcbd7d526..867b6ceff6 100644 --- a/resources/definitions/builder_premium_small.def.json +++ b/resources/definitions/builder_premium_small.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Builder SZ", "manufacturer": "Builder", - "category": "Other", "file_formats": "text/x-gcode", "platform": "builder_premium_platform.stl", "platform_offset": [-126, -36, 117], diff --git a/resources/definitions/creality_cr-x.def.json b/resources/definitions/creality_cr-x.def.json index 3d13c0f703..71a50051da 100644 --- a/resources/definitions/creality_cr-x.def.json +++ b/resources/definitions/creality_cr-x.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "SRC", "manufacturer": "Creality3D", - "category": "Other", "file_formats": "text/x-gcode", "platform": "cr-x.stl", "has_variants": false, diff --git a/resources/definitions/creality_ender3pro.def.json b/resources/definitions/creality_ender3pro.def.json index d2d538bc6e..54bdd1c64f 100644 --- a/resources/definitions/creality_ender3pro.def.json +++ b/resources/definitions/creality_ender3pro.def.json @@ -9,8 +9,8 @@ }, "overrides": { "machine_name": { "default_value": "Creality Ender-3 Pro" }, - "machine_width": { "default_value": 235 }, - "machine_depth": { "default_value": 235 }, + "machine_width": { "default_value": 220 }, + "machine_depth": { "default_value": 220 }, "machine_height": { "default_value": 250 }, "machine_head_with_fans_polygon": { "default_value": [ [-26, 34], diff --git a/resources/definitions/custom.def.json b/resources/definitions/custom.def.json index d0d9e904c5..88cc3c8821 100644 --- a/resources/definitions/custom.def.json +++ b/resources/definitions/custom.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Ultimaker", "manufacturer": "Custom", - "category": "Custom", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": diff --git a/resources/definitions/deltacomb.def.json b/resources/definitions/deltacomb.def.json index ac2ea5abe1..d044858827 100644 --- a/resources/definitions/deltacomb.def.json +++ b/resources/definitions/deltacomb.def.json @@ -7,7 +7,6 @@ "author": "Gabriele Rossetti", "visible": true, "manufacturer": "Deltacomb 3D", - "category": "Other", "file_formats": "text/x-gcode", "icon": "icon_ultimaker2", "platform": "deltacomb.stl", diff --git a/resources/definitions/dxu.def.json b/resources/definitions/dxu.def.json index e39cbba126..e911a8eed6 100644 --- a/resources/definitions/dxu.def.json +++ b/resources/definitions/dxu.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "TheUltimakerCommunity", "manufacturer": "DXU", - "category": "Other", "has_variants": true, "has_materials": true, "has_machine_materials": false, diff --git a/resources/definitions/erzay3d.def.json b/resources/definitions/erzay3d.def.json index 875aea708e..1fe777091f 100644 --- a/resources/definitions/erzay3d.def.json +++ b/resources/definitions/erzay3d.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Alexander Kirsanov", "manufacturer": "Robokinetika", - "category": "Other", "file_formats": "text/x-gcode", "machine_extruder_trains": { diff --git a/resources/definitions/fabtotum.def.json b/resources/definitions/fabtotum.def.json index 355f6a1434..16dac74a3b 100644 --- a/resources/definitions/fabtotum.def.json +++ b/resources/definitions/fabtotum.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "FABtotum", "manufacturer": "FABtotum", - "category": "Other", "file_formats": "text/x-gcode", "platform": "fabtotum_platform.stl", "has_machine_quality": true, diff --git a/resources/definitions/fdmprinter.def.json b/resources/definitions/fdmprinter.def.json index 3077089f8e..afaa39f648 100644 --- a/resources/definitions/fdmprinter.def.json +++ b/resources/definitions/fdmprinter.def.json @@ -5,7 +5,6 @@ { "type": "machine", "author": "Ultimaker", - "category": "Other", "manufacturer": "Unknown", "setting_version": 13, "file_formats": "text/x-gcode;application/x-stl-ascii;application/x-stl-binary;application/x-wavefront-obj;application/x3g", diff --git a/resources/definitions/flsun_qq_s.def.json b/resources/definitions/flsun_qq_s.def.json index a0c424d768..70be206f8b 100644 --- a/resources/definitions/flsun_qq_s.def.json +++ b/resources/definitions/flsun_qq_s.def.json @@ -4,8 +4,9 @@ "inherits": "fdmprinter", "metadata": { "visible": true, - "author": "Cataldo URSO", + "author": "Cataldo URSO & Eddy Emck ", "manufacturer": "FLSUN", + "platform": "FLSUN-QQ-S.stl", "file_formats": "text/x-gcode", "has_materials": true, "preferred_quality_type": "draft", diff --git a/resources/definitions/gmax15plus.def.json b/resources/definitions/gmax15plus.def.json index 7cafa09727..56b1111d58 100644 --- a/resources/definitions/gmax15plus.def.json +++ b/resources/definitions/gmax15plus.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "gcreate", "manufacturer": "gcreate", - "category": "Other", "file_formats": "text/x-gcode", "platform": "gmax_1-5_xt-plus_s3d_full model_150707.stl", "has_machine_quality": true, diff --git a/resources/definitions/gmax15plus_dual.def.json b/resources/definitions/gmax15plus_dual.def.json index 8bfadfc4ba..0060ee0ddc 100644 --- a/resources/definitions/gmax15plus_dual.def.json +++ b/resources/definitions/gmax15plus_dual.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "GTL_180109", "manufacturer": "gCreate", - "category": "Other", "file_formats": "text/x-gcode", "platform": "gmax_1-5_xt-plus_s3d_full model_150707.stl", "has_variants": true, diff --git a/resources/definitions/imade3d_jellybox_root.def.json b/resources/definitions/imade3d_jellybox_root.def.json index 52f541f1d4..f631fcb673 100644 --- a/resources/definitions/imade3d_jellybox_root.def.json +++ b/resources/definitions/imade3d_jellybox_root.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "IMADE3D", "manufacturer": "IMADE3D", - "category": "Ultimaker", "visible": false, "file_formats": "text/x-gcode", "exclude_materials": [ diff --git a/resources/definitions/kupido.def.json b/resources/definitions/kupido.def.json index ad0182a5f6..bee92ac282 100644 --- a/resources/definitions/kupido.def.json +++ b/resources/definitions/kupido.def.json @@ -7,7 +7,6 @@ "visible": true, "author": "ALYA", "manufacturer": "Kati Hal ARGE", - "category": "Other", "file_formats": "text/x-gcode", "platform_offset": [ 0, 0, 0], "exclude_materials": ["chromatik_pla", "dsm_arnitel2045_175", "dsm_novamid1070_175", "fabtotum_abs", "fabtotum_nylon", "fabtotum_pla", "fabtotum_tpu", "fiberlogy_hd_pla", "filo3d_pla", "filo3d_pla_green", "filo3d_pla_red", "generic_bam", "generic_cpe", "generic_cpe_175", "generic_cpe_plus", "generic_hips", "generic_hips_175", "generic_nylon", "generic_nylon_175", "generic_pc", "generic_pc_175", "generic_petg", "generic_petg_175", "generic_pp", "generic_pva", "generic_pva_175", "generic_tough_pla", "generic_tpu", "generic_tpu_175", "imade3d_petg_green", "imade3d_petg_pink", "imade3d_pla_green", "imade3d_pla_pink", "innofill_innoflex60_175", "octofiber_pla", "polyflex_pla", "polymax_pla", "polyplus_pla", "polywood_pla", "ultimaker_abs_black", "ultimaker_abs_blue", "ultimaker_abs_green", "ultimaker_abs_grey", "ultimaker_abs_orange", "ultimaker_abs_pearl-gold", "ultimaker_abs_red", "ultimaker_abs_silver-metallic", "ultimaker_abs_white", "ultimaker_abs_yellow", "ultimaker_bam", "ultimaker_cpe_black", "ultimaker_cpe_blue", "ultimaker_cpe_dark-grey", "ultimaker_cpe_green", "ultimaker_cpe_light-grey", "ultimaker_cpe_plus_black", "ultimaker_cpe_plus_transparent", "ultimaker_cpe_plus_white", "ultimaker_cpe_red", "ultimaker_cpe_transparent", "ultimaker_cpe_white", "ultimaker_cpe_yellow", "ultimaker_nylon_black", "ultimaker_nylon_transparent", "ultimaker_pc_black", "ultimaker_pc_transparent", "ultimaker_pc_white", "ultimaker_pla_black", "ultimaker_pla_blue", "ultimaker_pla_green", "ultimaker_pla_magenta", "ultimaker_pla_orange", "ultimaker_pla_pearl-white", "ultimaker_pla_red", "ultimaker_pla_silver-metallic", "ultimaker_pla_transparent", "ultimaker_pla_white", "ultimaker_pla_yellow", "ultimaker_pp_transparent", "ultimaker_pva", "ultimaker_tough_pla_black", "ultimaker_tough_pla_green", "ultimaker_tough_pla_red", "ultimaker_tough_pla_white", "ultimaker_tpu_black", "ultimaker_tpu_blue", "ultimaker_tpu_red", "ultimaker_tpu_white", "verbatim_bvoh_175", "Vertex_Delta_ABS", "Vertex_Delta_PET", "Vertex_Delta_PLA", "Vertex_Delta_TPU", "zyyx_pro_flex", "zyyx_pro_pla","tizyx_pla","tizyx_abs","tizyx_pla_bois" ], diff --git a/resources/definitions/leapfrog_bolt_pro.def.json b/resources/definitions/leapfrog_bolt_pro.def.json index 09b9ecded5..d6cc30e792 100644 --- a/resources/definitions/leapfrog_bolt_pro.def.json +++ b/resources/definitions/leapfrog_bolt_pro.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Karan and Vincent 20191104", "manufacturer": "Leapfrog B.V.", - "category": "Other", "platform": "leapfrog_bolt_pro_platform.stl", "platform_offset": [0, 0, -14], "file_formats": "text/x-gcode", diff --git a/resources/definitions/malyan_m200.def.json b/resources/definitions/malyan_m200.def.json index 2e64cd14fa..71d15cb39b 100644 --- a/resources/definitions/malyan_m200.def.json +++ b/resources/definitions/malyan_m200.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Brian Corbino, Tyler Gibson", "manufacturer": "Malyan", - "category": "Other", "file_formats": "text/x-gcode", "platform": "malyan_m200_platform.stl", "platform_offset": [0, -0.25, 0], diff --git a/resources/definitions/mbot3d_grid4.def.json b/resources/definitions/mbot3d_grid4.def.json index a895415dda..fa2deda027 100644 --- a/resources/definitions/mbot3d_grid4.def.json +++ b/resources/definitions/mbot3d_grid4.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Magicfirm", "manufacturer": "Magicfirm", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "platform_offset": [ diff --git a/resources/definitions/mbot3d_grid4_dual.def.json b/resources/definitions/mbot3d_grid4_dual.def.json index d32590ff3e..891f5dc51f 100644 --- a/resources/definitions/mbot3d_grid4_dual.def.json +++ b/resources/definitions/mbot3d_grid4_dual.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Magicfirm", "manufacturer": "Magicfirm", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "platform_offset": [ @@ -14,7 +13,7 @@ 0 ], "has_materials": true, - "machine_extruder_trains": { + "machine_extruder_trains": { "0": "mbot3d_grid4_extruder_left", "1": "mbot3d_grid4_extruder_right" } diff --git a/resources/definitions/monoprice_select_mini_v1.def.json b/resources/definitions/monoprice_select_mini_v1.def.json index 4fe67fc92e..21497b13bc 100644 --- a/resources/definitions/monoprice_select_mini_v1.def.json +++ b/resources/definitions/monoprice_select_mini_v1.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Brian Corbino, Tyler Gibson", "manufacturer": "Monoprice", - "category": "Other", "file_formats": "text/x-gcode", "quality_definition": "malyan_m200", "visible": true, diff --git a/resources/definitions/monoprice_select_mini_v2.def.json b/resources/definitions/monoprice_select_mini_v2.def.json index 2364e49383..d671f319ad 100644 --- a/resources/definitions/monoprice_select_mini_v2.def.json +++ b/resources/definitions/monoprice_select_mini_v2.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Tyler Gibson", "manufacturer": "Monoprice", - "category": "Other", "file_formats": "text/x-gcode", "has_machine_quality": true, "has_materials": true, diff --git a/resources/definitions/mp_mini_delta.def.json b/resources/definitions/mp_mini_delta.def.json index 5aac007b88..e73afb743b 100644 --- a/resources/definitions/mp_mini_delta.def.json +++ b/resources/definitions/mp_mini_delta.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "MPMD Facebook Group", "manufacturer": "Monoprice", - "category": "Other", "file_formats": "text/x-gcode", "platform": "mp_mini_delta_platform.stl", "supports_usb_connection": true, diff --git a/resources/definitions/predator.def.json b/resources/definitions/predator.def.json new file mode 100644 index 0000000000..a8f4e56fe1 --- /dev/null +++ b/resources/definitions/predator.def.json @@ -0,0 +1,72 @@ +{ + "version": 2, + "name": "Anycubic Predator", + "inherits": "fdmprinter", + "metadata": { + "author": "ksihota", + "manufacturer": "Anycubic", + "file_formats": "text/x-gcode", + "platform": "predator_platform.stl", + "platform_texture": "anycubic_predator.png", + "supports_usb_connection": true, + "visible": true, + "platform_offset": [0, 0, 0], + "has_materials": true, + "has_variants": false, + "has_machine_materials": false, + "has_variant_materials": false, + "has_machine_quality": true, + "quality_definition": "predator", + "preferred_quality_type": "normal", + "machine_extruder_trains": + { + "0": "predator_extruder_0" + } + }, + + "overrides": { + "machine_start_gcode": + { + "default_value": "G21 ;metric values \nG90 ;absolute positioning \nM82 ;set extruder to absolute mode \nM107 ;start with the fan off \nG28 ;Home \nG1 Z15.0 F1000;short move \nG92 E0 ;zero the extruded length \nG1 F200 E3 ;extrude 3mm of feed stock adjust so I don't have to remove any filament \nG92 E0 ;zero the extruded length again \nG1 F4000 ;move to bed \n;Put printing message on LCD screen \nM117 Printing... \n;G5; this is in order to resume on Power failure (only works on SD prints)" + }, + "machine_end_gcode": + { + "default_value": "M104 S0 ;extruder heater off \nM140 S0 ;heated bed heater off \nG91 ;relative positioning \nG92 E0 ;zero the extruded length \nG1 E-2 F300 ;retract the filament a bit before lifting the nozzle, to release some of the pressure \nG92 E0 ;zero the extruded length \n;M107 ;fan off \nG1 Z+0.5 E-5 ;move Z up a bit and retract filament even more \n;G1 X0.0 Y0.0 Z455.0 F4500 \nG28 ;Home all axes (max endstops) \nG90 ;absolute positioning \n;M109 S60 ; wait for extruder temp to drop to 60 \n;M84 ;steppers off \n;M81 ;turn off printer" + }, + "gantry_height": { + "value": 455 + }, + "machine_width": { "default_value": 370 }, + "machine_depth": { "default_value": 370 }, + "machine_height": { "default_value": 455 }, + "machine_heated_bed": { "default_value": true }, + "machine_shape": { "default_value": "elliptic" }, + "machine_center_is_zero": { "default_value": true }, + "machine_nozzle_size": { + "default_value": 0.4, + "minimum_value": 0.15, + "maximum_value": 0.80 + }, + "line_width": { "value": "round(machine_nozzle_size * 0.875, 2)" }, + "material_print_temperature_layer_0": { "value": "material_print_temperature + 5" }, + "material_bed_temperature_layer_0": { "value": "material_bed_temperature + 5" }, + "machine_gcode_flavor": { "default_value": "RepRap (Marlin/Sprinter)" }, + "machine_max_feedrate_x": { "default_value": 150 }, + "machine_max_feedrate_y": { "default_value": 150 }, + "machine_max_feedrate_z": { "default_value": 150 }, + "machine_max_feedrate_e": { "default_value": 50 }, + "machine_max_acceleration_x": { "default_value": 800 }, + "machine_max_acceleration_y": { "default_value": 800 }, + "machine_max_acceleration_z": { "default_value": 800 }, + "machine_max_acceleration_e": { "default_value": 10000 }, + "machine_acceleration": { "default_value": 3000 }, + "machine_max_jerk_xy": { "default_value": 20 }, + "machine_max_jerk_z": { "default_value": 20 }, + "machine_max_jerk_e": { "default_value": 5}, + "retraction_amount": { "default_value": 4 }, + "retraction_speed": { "default_value": 50 }, + "retraction_hop_enabled": { "default_value": false }, + "retract_at_layer_change": { "default_value": true }, + "coasting_enable": { "default_value": true } + } +} \ No newline at end of file diff --git a/resources/definitions/raise3D_N2_dual.def.json b/resources/definitions/raise3D_N2_dual.def.json index 530ad79d19..f5246f6bb6 100644 --- a/resources/definitions/raise3D_N2_dual.def.json +++ b/resources/definitions/raise3D_N2_dual.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Raise3D", "manufacturer": "Raise3D", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": diff --git a/resources/definitions/raise3D_N2_plus_dual.def.json b/resources/definitions/raise3D_N2_plus_dual.def.json index ffc4afec16..02f5fd4e11 100644 --- a/resources/definitions/raise3D_N2_plus_dual.def.json +++ b/resources/definitions/raise3D_N2_plus_dual.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Raise3D", "manufacturer": "Raise3D", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": diff --git a/resources/definitions/raise3D_N2_plus_single.def.json b/resources/definitions/raise3D_N2_plus_single.def.json index ccb169efb1..7ffdf08767 100644 --- a/resources/definitions/raise3D_N2_plus_single.def.json +++ b/resources/definitions/raise3D_N2_plus_single.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Raise3D", "manufacturer": "Raise3D", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": diff --git a/resources/definitions/raise3D_N2_single.def.json b/resources/definitions/raise3D_N2_single.def.json index f0915d1a31..c4e346ae90 100644 --- a/resources/definitions/raise3D_N2_single.def.json +++ b/resources/definitions/raise3D_N2_single.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Raise3D", "manufacturer": "Raise3D", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "machine_extruder_trains": diff --git a/resources/definitions/skriware_2.def.json b/resources/definitions/skriware_2.def.json index e8715eb079..7878a9b243 100644 --- a/resources/definitions/skriware_2.def.json +++ b/resources/definitions/skriware_2.def.json @@ -1,727 +1,726 @@ { - "name": "Skriware 2", - "version": 2, - "inherits": "fdmprinter", - "metadata": { - "visible": true, - "author": "Skriware", - "manufacturer": "Skriware", - "category": "Other", - "file_formats": "text/x-gcode", - "platform_offset": [ - 0, - 0, - 0 - ], - "supports_usb_connection": false, - "platform": "skriware_2_platform.stl", - "machine_extruder_trains": { - "0": "skriware_2_extruder_0", - "1": "skriware_2_extruder_1" - } - }, - "overrides": { - "raft_interface_thickness": { - "value": "0.2" - }, - "wipe_retraction_prime_speed": { - "value": "30" - }, - "support_skip_zag_per_mm": { - "default_value": 10 - }, - "material_bed_temperature": { - "value": "50" - }, - "raft_airgap": { - "default_value": 0.2 - }, - "top_layers": { - "value": "4" - }, - "machine_extruder_count": { - "default_value": 2 - }, - "raft_surface_acceleration": { - "value": "400" - }, - "meshfix_maximum_travel_resolution": { - "value": "0.8" - }, - "machine_end_gcode": { - "default_value": "M59\nG92 E0\nG1 E-10 F300\nM104 T0 S0\nM104 T1 S0\nM140 S0\nG28 X0 Y0\nM84\nM106 S0\nM107" - }, - "wall_material_flow": { - "value": "99" - }, - "raft_interface_jerk": { - "value": "10" - }, - "acceleration_topbottom": { - "value": "400" - }, - "prime_tower_size": { - "default_value": 1 - }, - "max_skin_angle_for_expansion": { - "default_value": 50 - }, - "raft_acceleration": { - "value": "400" - }, - "support_xy_distance": { - "default_value": 0.6 - }, - "xy_offset_layer_0": { - "value": "-0.16" - }, - "raft_interface_fan_speed": { - "value": "40" - }, - "retraction_speed": { - "default_value": 30 - }, - "speed_print": { - "default_value": 20 - }, - "travel_avoid_supports": { - "default_value": true - }, - "infill_overlap_mm": { - "value": "0.0" - }, - "support_roof_height": { - "value": "0.4" - }, - "speed_travel_layer_0": { - "value": "120" - }, - "speed_wall_0": { - "value": "20" - }, - "acceleration_wall_x": { - "value": "400" - }, - "layer_0_z_overlap": { - "value": "0.1" - }, - "switch_extruder_retraction_speed": { - "value": "30" - }, - "travel_compensate_overlapping_walls_enabled": { - "default_value": false - }, - "raft_base_acceleration": { - "value": "400" - }, - "raft_base_speed": { - "value": "60" - }, - "wall_0_material_flow": { - "value": "99" - }, - "support_infill_rate": { - "value": "20" - }, - "raft_surface_layers": { - "default_value": 1 - }, - "machine_height": { - "default_value": 210 - }, - "retraction_prime_speed": { - "value": "60" - }, - "support_interface_material_flow": { - "value": "99" - }, - "raft_surface_fan_speed": { - "value": "80" - }, - "raft_base_line_width": { - "value": "0.4" - }, - "infill_line_distance": { - "value": "5.33" - }, - "default_material_print_temperature": { - "default_value": 200 - }, - "speed_roofing": { - "value": "20" - }, - "skin_material_flow": { - "value": "99" - }, - "cool_fan_full_layer": { - "value": "1" - }, - "material_break_preparation_temperature": { - "value": "195" - }, - "support_roof_density": { - "value": "70" - }, - "support_infill_sparse_thickness": { - "value": "0.2" - }, - "retraction_retract_speed": { - "value": "30" - }, - "speed_slowdown_layers": { - "default_value": 1 - }, - "support_line_distance": { - "value": "2" - }, - "cool_lift_head": { - "default_value": true - }, - "min_skin_width_for_expansion": { - "value": "0.67" - }, - "cool_min_speed": { - "default_value": 5 - }, - "switch_extruder_retraction_speeds": { - "default_value": 30 - }, - "raft_base_line_spacing": { - "value": "0.8" - }, - "speed_support": { - "value": "50" - }, - "skirt_brim_material_flow": { - "value": "99" - }, - "speed_infill": { - "value": "80" - }, - "support_initial_layer_line_distance": { - "value": "2" - }, - "support_use_towers": { - "default_value": false - }, - "skin_no_small_gaps_heuristic": { - "default_value": true - }, - "acceleration_roofing": { - "value": "400" - }, - "material_initial_print_temperature": { - "value": "195" - }, - "material_diameter": { - "default_value": 1.75 - }, - "xy_offset": { - "default_value": -0.16 - }, - "support_extruder_nr": { - "value": "0" - }, - "support_brim_line_count": { - "value": "16" - }, - "support_interface_extruder_nr": { - "value": "0" - }, - "support_roof_extruder_nr": { - "value": "0" - }, - "material_adhesion_tendency": { - "default_value": 0 - }, - "material_standby_temperature": { - "default_value": 195 - }, - "cool_fan_speed_0": { - "default_value": 100 - }, - "brim_line_count": { - "value": "17" - }, - "adhesion_type": { - "default_value": "raft" - }, - "switch_extruder_retraction_amount": { - "value": "16" - }, - "retraction_amount": { - "default_value": 3 - }, - "acceleration_travel": { - "value": "400" - }, - "jerk_print_layer_0": { - "value": "10" - }, - "raft_surface_thickness": { - "value": "0.2" - }, - "raft_base_jerk": { - "value": "10" - }, - "bottom_thickness": { - "value": "0.8" - }, - "roofing_material_flow": { - "value": "99" - }, - "top_skin_expand_distance": { - "value": "0.8" - }, - "speed_wall_x": { - "value": "20" - }, - "support_enable": { - "default_value": true - }, - "acceleration_print_layer_0": { - "value": "400" - }, - "jerk_prime_tower": { - "value": "5" - }, - "infill_before_walls": { - "default_value": false - }, - "raft_interface_line_spacing": { - "value": "0.4" - }, - "gantry_height": { - "value": "210" - }, - "material_print_temperature_layer_0": { - "value": "195" - }, - "raft_interface_line_width": { - "value": "0.4" - }, - "skirt_brim_line_width": { - "value": "0.5" - }, - "z_seam_y": { - "value": "180" - }, - "roofing_layer_count": { - "value": "1" - }, - "raft_margin": { - "default_value": 4 - }, - "cool_fan_full_at_height": { - "value": "0" - }, - "acceleration_support_interface": { - "value": "250" - }, - "retraction_min_travel": { - "value": "1" - }, - "acceleration_layer_0": { - "value": "400" - }, - "support_z_distance": { - "default_value": 0.2 - }, - "machine_heated_bed": { - "default_value": true - }, - "raft_jerk": { - "value": "10" - }, - "raft_surface_speed": { - "value": "60" - }, - "initial_layer_line_width_factor": { - "default_value": 120 - }, - "machine_start_gcode": { - "default_value": "G90 ;absolute positioning\nM82 ;set extruder to absolute mode\nM420 S1 Z0.6 ;enable bed levelling\nG1 Z10 F250 ;move the platform down 10mm\nM107 ;fan off\nM42 P11 S255 ;turn on front fan\nM140 S{material_bed_temperature}\nM104 T0 S{material_print_temperature, 0}\nM104 T1 S{material_print_temperature, 1}\nG1 F2500 Y260 X0\nM190 S{material_bed_temperature}\nM109 T0 S{material_print_temperature, 0}\nM109 T1 S{material_print_temperature, 1}\nM60 ;enable E-FADE Algorithm\nM62 A ;filament sensor off\nG92 E0 ;zero the extruded length\nT1\nG92 E0;zero the extruded length\nG1 F300 Z0.3\nG1 F1200 X20\nG1 F1200 X180 E21 ;extrude 21 mm of feed stock\nG1 F1200 E15 ;retracting 6 mm\nG1 F2000 E21\nG1 F2000 E11\nG1 F300 Z1.5\nG92 E0 ;zero the extruded length again\nT0\nG92 E0 ;zero the extruded length\nG1 F1200 Y258\nG1 F300 Z0.3\nG1 F1200 X40 E21 ;extrude 21 mm of feed stock\nG1 F1200 E15 ;retracting 6 mm\nG1 F2000 E21\nG1 F2000 E11\nG1 Z1.5\nM61 A ;filament sensor reset\nM63 A ;filament sensor on\nG92 E0 ;zero the extruded length again\nM58 ;end of Start G-Code and signal retract management\nT{initial_extruder_nr}" - }, - "bottom_skin_preshrink": { - "value": "0.8" - }, - "ironing_inset": { - "value": "0.2" - }, - "jerk_travel": { - "value": "10" - }, - "machine_depth": { - "default_value": 260 - }, - "jerk_skirt_brim": { - "value": "5" - }, - "infill_wipe_dist": { - "value": "0" - }, - "raft_interface_acceleration": { - "value": "400" - }, - "z_seam_x": { - "value": "115" - }, - "material_print_temperature": { - "value": "195" - }, - "material_bed_temperature_layer_0": { - "value": "50" - }, - "wipe_retraction_retract_speed": { - "value": "30" - }, - "jerk_travel_layer_0": { - "value": "10" - }, - "infill_overlap": { - "value": "0" - }, - "acceleration_support_infill": { - "value": "400" - }, - "travel_compensate_overlapping_walls_0_enabled": { - "value": "False" - }, - "support_bottom_material_flow": { - "value": "99" - }, - "jerk_support_roof": { - "value": "5" - }, - "wall_x_material_flow": { - "value": "99" - }, - "speed_support_interface": { - "value": "33.33" - }, - "jerk_layer_0": { - "value": "10" - }, - "support_angle": { - "default_value": 60 - }, - "infill_sparse_thickness": { - "value": "0.2" - }, - "prime_tower_position_y": { - "value": "1" - }, - "retraction_combing": { - "default_value": "infill" - }, - "acceleration_prime_tower": { - "value": "250" - }, - "acceleration_print": { - "default_value": 400 - }, - "acceleration_infill": { - "value": "500" - }, - "bridge_wall_speed": { - "value": "10.0" - }, - "acceleration_wall_0": { - "value": "400" - }, - "support_offset": { - "default_value": 0.2 - }, - "build_volume_temperature": { - "default_value": 28 - }, - "switch_extruder_prime_speed": { - "value": "60" - }, - "speed_prime_tower": { - "value": "20" - }, - "top_skin_preshrink": { - "value": "0.8" - }, - "jerk_ironing": { - "value": "5" - }, - "skin_outline_count": { - "default_value": 0 - }, - "skirt_brim_speed": { - "value": "10.0" - }, - "raft_base_thickness": { - "value": "0.2" - }, - "infill_sparse_density": { - "default_value": 15 - }, - "support_bottom_extruder_nr": { - "value": "0" - }, - "support_material_flow": { - "value": "98" - }, - "min_infill_area": { - "default_value": 1 - }, - "jerk_support": { - "value": "10" - }, - "bottom_skin_expand_distance": { - "value": "0.8" - }, - "retract_at_layer_change": { - "default_value": true - }, - "jerk_support_interface": { - "value": "5" - }, - "jerk_support_bottom": { - "value": "5" - }, - "optimize_wall_printing_order": { - "default_value": true - }, - "skirt_brim_minimal_length": { - "default_value": 50 - }, - "jerk_support_infill": { - "value": "10" - }, - "initial_bottom_layers": { - "value": "3" - }, - "prime_tower_position_x": { - "value": "1" - }, - "acceleration_support_bottom": { - "value": "250" - }, - "speed_support_roof": { - "value": "33.33" - }, - "speed_support_infill": { - "value": "80" - }, - "bridge_skin_speed_2": { - "value": "15" - }, - "raft_fan_speed": { - "default_value": 100 - }, - "wipe_retraction_amount": { - "value": "3" - }, - "skin_edge_support_thickness": { - "value": "0" - }, - "bottom_layers": { - "value": "3" - }, - "retraction_extrusion_window": { - "value": "3" - }, - "acceleration_ironing": { - "value": "250" - }, - "support_top_distance": { - "value": "0.2" - }, - "travel_retract_before_outer_wall": { - "default_value": true - }, - "material_flow": { - "default_value": 99 - }, - "support_bottom_distance": { - "value": "0.2" - }, - "expand_skins_expand_distance": { - "value": "0.8" - }, - "jerk_wall": { - "value": "10" - }, - "support_zag_skip_count": { - "value": "8" - }, - "connect_infill_polygons": { - "value": "False" - }, - "acceleration_skirt_brim": { - "value": "250" - }, - "z_seam_corner": { - "default_value": "z_seam_corner_weighted" - }, - "raft_surface_jerk": { - "value": "10" - }, - "cross_infill_pocket_size": { - "value": "5.33" - }, - "support_infill_extruder_nr": { - "value": "0" - }, - "acceleration_enabled": { - "default_value": true - }, - "jerk_wall_x": { - "value": "10" - }, - "skin_overlap": { - "value": "15" - }, - "infill_material_flow": { - "value": "99" - }, - "speed_equalize_flow_max": { - "default_value": 40 - }, - "skin_preshrink": { - "value": "0.8" - }, - "speed_wall": { - "value": "20" - }, - "support_tree_collision_resolution": { - "value": "0.2" - }, - "meshfix_maximum_deviation": { - "default_value": 0.005 - }, - "jerk_roofing": { - "value": "10" - }, - "fill_outline_gaps": { - "default_value": true - }, - "layer_height": { - "default_value": 0.2 - }, - "remove_empty_first_layers": { - "default_value": false - }, - "prime_tower_flow": { - "value": "99" - }, - "support_roof_line_distance": { - "value": "0.57" - }, - "wipe_retraction_speed": { - "value": "30" - }, - "support_extruder_nr_layer_0": { - "value": "0" - }, - "layer_height_0": { - "default_value": 0.2 - }, - "multiple_mesh_overlap": { - "default_value": 0 - }, - "ooze_shield_dist": { - "default_value": 4 - }, - "jerk_enabled": { - "default_value": true - }, - "acceleration_support": { - "value": "400" - }, - "adhesion_extruder_nr": { - "value": "0" - }, - "skirt_line_count": { - "default_value": 2 - }, - "travel_compensate_overlapping_walls_x_enabled": { - "value": "False" - }, - "jerk_wall_0": { - "value": "10" - }, - "raft_speed": { - "value": "60" - }, - "speed_layer_0": { - "value": "10.0" - }, - "machine_width": { - "default_value": 210 - }, - "acceleration_wall": { - "value": "400" - }, - "jerk_infill": { - "value": "10" - }, - "wipe_hop_enable": { - "value": "False" - }, - "acceleration_travel_layer_0": { - "value": "400" - }, - "raft_interface_speed": { - "value": "60" - }, - "skin_edge_support_layers": { - "value": "0" - }, - "support_xy_distance_overhang": { - "value": "0.5" - }, - "brim_width": { - "default_value": 10 - }, - "coasting_enable": { - "default_value": true - }, - "jerk_print": { - "default_value": 10 - }, - "acceleration_support_roof": { - "value": "250" - }, - "prime_tower_min_volume": { - "default_value": 4 - }, - "support_roof_material_flow": { - "value": "99" - }, - "wall_0_wipe_dist": { - "value": "0" - }, - "jerk_topbottom": { - "value": "10" - }, - "retraction_count_max": { - "default_value": 30 - }, - "skin_overlap_mm": { - "value": "0.06" - }, - "extruders_enabled_count": { - "value": "2" - }, - "speed_support_bottom": { - "value": "33.33" - }, - "support_skip_some_zags": { - "default_value": true - }, - "ooze_shield_angle": { - "default_value": 50 - }, - "wall_thickness": { - "value": "1.2" - }, - "speed_print_layer_0": { - "value": "10.0" - } - } + "name": "Skriware 2", + "version": 2, + "inherits": "fdmprinter", + "metadata": { + "visible": true, + "author": "Skriware", + "manufacturer": "Skriware", + "file_formats": "text/x-gcode", + "platform_offset": [ + 0, + 0, + 0 + ], + "supports_usb_connection": false, + "platform": "skriware_2_platform.stl", + "machine_extruder_trains": { + "0": "skriware_2_extruder_0", + "1": "skriware_2_extruder_1" + } + }, + "overrides": { + "raft_interface_thickness": { + "value": "0.2" + }, + "wipe_retraction_prime_speed": { + "value": "30" + }, + "support_skip_zag_per_mm": { + "default_value": 10 + }, + "material_bed_temperature": { + "value": "50" + }, + "raft_airgap": { + "default_value": 0.2 + }, + "top_layers": { + "value": "4" + }, + "machine_extruder_count": { + "default_value": 2 + }, + "raft_surface_acceleration": { + "value": "400" + }, + "meshfix_maximum_travel_resolution": { + "value": "0.8" + }, + "machine_end_gcode": { + "default_value": "M59\nG92 E0\nG1 E-10 F300\nM104 T0 S0\nM104 T1 S0\nM140 S0\nG28 X0 Y0\nM84\nM106 S0\nM107" + }, + "wall_material_flow": { + "value": "99" + }, + "raft_interface_jerk": { + "value": "10" + }, + "acceleration_topbottom": { + "value": "400" + }, + "prime_tower_size": { + "default_value": 1 + }, + "max_skin_angle_for_expansion": { + "default_value": 50 + }, + "raft_acceleration": { + "value": "400" + }, + "support_xy_distance": { + "default_value": 0.6 + }, + "xy_offset_layer_0": { + "value": "-0.16" + }, + "raft_interface_fan_speed": { + "value": "40" + }, + "retraction_speed": { + "default_value": 30 + }, + "speed_print": { + "default_value": 20 + }, + "travel_avoid_supports": { + "default_value": true + }, + "infill_overlap_mm": { + "value": "0.0" + }, + "support_roof_height": { + "value": "0.4" + }, + "speed_travel_layer_0": { + "value": "120" + }, + "speed_wall_0": { + "value": "20" + }, + "acceleration_wall_x": { + "value": "400" + }, + "layer_0_z_overlap": { + "value": "0.1" + }, + "switch_extruder_retraction_speed": { + "value": "30" + }, + "travel_compensate_overlapping_walls_enabled": { + "default_value": false + }, + "raft_base_acceleration": { + "value": "400" + }, + "raft_base_speed": { + "value": "60" + }, + "wall_0_material_flow": { + "value": "99" + }, + "support_infill_rate": { + "value": "20" + }, + "raft_surface_layers": { + "default_value": 1 + }, + "machine_height": { + "default_value": 210 + }, + "retraction_prime_speed": { + "value": "60" + }, + "support_interface_material_flow": { + "value": "99" + }, + "raft_surface_fan_speed": { + "value": "80" + }, + "raft_base_line_width": { + "value": "0.4" + }, + "infill_line_distance": { + "value": "5.33" + }, + "default_material_print_temperature": { + "default_value": 200 + }, + "speed_roofing": { + "value": "20" + }, + "skin_material_flow": { + "value": "99" + }, + "cool_fan_full_layer": { + "value": "1" + }, + "material_break_preparation_temperature": { + "value": "195" + }, + "support_roof_density": { + "value": "70" + }, + "support_infill_sparse_thickness": { + "value": "0.2" + }, + "retraction_retract_speed": { + "value": "30" + }, + "speed_slowdown_layers": { + "default_value": 1 + }, + "support_line_distance": { + "value": "2" + }, + "cool_lift_head": { + "default_value": true + }, + "min_skin_width_for_expansion": { + "value": "0.67" + }, + "cool_min_speed": { + "default_value": 5 + }, + "switch_extruder_retraction_speeds": { + "default_value": 30 + }, + "raft_base_line_spacing": { + "value": "0.8" + }, + "speed_support": { + "value": "50" + }, + "skirt_brim_material_flow": { + "value": "99" + }, + "speed_infill": { + "value": "80" + }, + "support_initial_layer_line_distance": { + "value": "2" + }, + "support_use_towers": { + "default_value": false + }, + "skin_no_small_gaps_heuristic": { + "default_value": true + }, + "acceleration_roofing": { + "value": "400" + }, + "material_initial_print_temperature": { + "value": "195" + }, + "material_diameter": { + "default_value": 1.75 + }, + "xy_offset": { + "default_value": -0.16 + }, + "support_extruder_nr": { + "value": "0" + }, + "support_brim_line_count": { + "value": "16" + }, + "support_interface_extruder_nr": { + "value": "0" + }, + "support_roof_extruder_nr": { + "value": "0" + }, + "material_adhesion_tendency": { + "default_value": 0 + }, + "material_standby_temperature": { + "default_value": 195 + }, + "cool_fan_speed_0": { + "default_value": 100 + }, + "brim_line_count": { + "value": "17" + }, + "adhesion_type": { + "default_value": "raft" + }, + "switch_extruder_retraction_amount": { + "value": "16" + }, + "retraction_amount": { + "default_value": 3 + }, + "acceleration_travel": { + "value": "400" + }, + "jerk_print_layer_0": { + "value": "10" + }, + "raft_surface_thickness": { + "value": "0.2" + }, + "raft_base_jerk": { + "value": "10" + }, + "bottom_thickness": { + "value": "0.8" + }, + "roofing_material_flow": { + "value": "99" + }, + "top_skin_expand_distance": { + "value": "0.8" + }, + "speed_wall_x": { + "value": "20" + }, + "support_enable": { + "default_value": true + }, + "acceleration_print_layer_0": { + "value": "400" + }, + "jerk_prime_tower": { + "value": "5" + }, + "infill_before_walls": { + "default_value": false + }, + "raft_interface_line_spacing": { + "value": "0.4" + }, + "gantry_height": { + "value": "210" + }, + "material_print_temperature_layer_0": { + "value": "195" + }, + "raft_interface_line_width": { + "value": "0.4" + }, + "skirt_brim_line_width": { + "value": "0.5" + }, + "z_seam_y": { + "value": "180" + }, + "roofing_layer_count": { + "value": "1" + }, + "raft_margin": { + "default_value": 4 + }, + "cool_fan_full_at_height": { + "value": "0" + }, + "acceleration_support_interface": { + "value": "250" + }, + "retraction_min_travel": { + "value": "1" + }, + "acceleration_layer_0": { + "value": "400" + }, + "support_z_distance": { + "default_value": 0.2 + }, + "machine_heated_bed": { + "default_value": true + }, + "raft_jerk": { + "value": "10" + }, + "raft_surface_speed": { + "value": "60" + }, + "initial_layer_line_width_factor": { + "default_value": 120 + }, + "machine_start_gcode": { + "default_value": "G90 ;absolute positioning\nM82 ;set extruder to absolute mode\nM420 S1 Z0.6 ;enable bed levelling\nG1 Z10 F250 ;move the platform down 10mm\nM107 ;fan off\nM42 P11 S255 ;turn on front fan\nM140 S{material_bed_temperature}\nM104 T0 S{material_print_temperature, 0}\nM104 T1 S{material_print_temperature, 1}\nG1 F2500 Y260 X0\nM190 S{material_bed_temperature}\nM109 T0 S{material_print_temperature, 0}\nM109 T1 S{material_print_temperature, 1}\nM60 ;enable E-FADE Algorithm\nM62 A ;filament sensor off\nG92 E0 ;zero the extruded length\nT1\nG92 E0;zero the extruded length\nG1 F300 Z0.3\nG1 F1200 X20\nG1 F1200 X180 E21 ;extrude 21 mm of feed stock\nG1 F1200 E15 ;retracting 6 mm\nG1 F2000 E21\nG1 F2000 E11\nG1 F300 Z1.5\nG92 E0 ;zero the extruded length again\nT0\nG92 E0 ;zero the extruded length\nG1 F1200 Y258\nG1 F300 Z0.3\nG1 F1200 X40 E21 ;extrude 21 mm of feed stock\nG1 F1200 E15 ;retracting 6 mm\nG1 F2000 E21\nG1 F2000 E11\nG1 Z1.5\nM61 A ;filament sensor reset\nM63 A ;filament sensor on\nG92 E0 ;zero the extruded length again\nM58 ;end of Start G-Code and signal retract management\nT{initial_extruder_nr}" + }, + "bottom_skin_preshrink": { + "value": "0.8" + }, + "ironing_inset": { + "value": "0.2" + }, + "jerk_travel": { + "value": "10" + }, + "machine_depth": { + "default_value": 260 + }, + "jerk_skirt_brim": { + "value": "5" + }, + "infill_wipe_dist": { + "value": "0" + }, + "raft_interface_acceleration": { + "value": "400" + }, + "z_seam_x": { + "value": "115" + }, + "material_print_temperature": { + "value": "195" + }, + "material_bed_temperature_layer_0": { + "value": "50" + }, + "wipe_retraction_retract_speed": { + "value": "30" + }, + "jerk_travel_layer_0": { + "value": "10" + }, + "infill_overlap": { + "value": "0" + }, + "acceleration_support_infill": { + "value": "400" + }, + "travel_compensate_overlapping_walls_0_enabled": { + "value": "False" + }, + "support_bottom_material_flow": { + "value": "99" + }, + "jerk_support_roof": { + "value": "5" + }, + "wall_x_material_flow": { + "value": "99" + }, + "speed_support_interface": { + "value": "33.33" + }, + "jerk_layer_0": { + "value": "10" + }, + "support_angle": { + "default_value": 60 + }, + "infill_sparse_thickness": { + "value": "0.2" + }, + "prime_tower_position_y": { + "value": "1" + }, + "retraction_combing": { + "default_value": "infill" + }, + "acceleration_prime_tower": { + "value": "250" + }, + "acceleration_print": { + "default_value": 400 + }, + "acceleration_infill": { + "value": "500" + }, + "bridge_wall_speed": { + "value": "10.0" + }, + "acceleration_wall_0": { + "value": "400" + }, + "support_offset": { + "default_value": 0.2 + }, + "build_volume_temperature": { + "default_value": 28 + }, + "switch_extruder_prime_speed": { + "value": "60" + }, + "speed_prime_tower": { + "value": "20" + }, + "top_skin_preshrink": { + "value": "0.8" + }, + "jerk_ironing": { + "value": "5" + }, + "skin_outline_count": { + "default_value": 0 + }, + "skirt_brim_speed": { + "value": "10.0" + }, + "raft_base_thickness": { + "value": "0.2" + }, + "infill_sparse_density": { + "default_value": 15 + }, + "support_bottom_extruder_nr": { + "value": "0" + }, + "support_material_flow": { + "value": "98" + }, + "min_infill_area": { + "default_value": 1 + }, + "jerk_support": { + "value": "10" + }, + "bottom_skin_expand_distance": { + "value": "0.8" + }, + "retract_at_layer_change": { + "default_value": true + }, + "jerk_support_interface": { + "value": "5" + }, + "jerk_support_bottom": { + "value": "5" + }, + "optimize_wall_printing_order": { + "default_value": true + }, + "skirt_brim_minimal_length": { + "default_value": 50 + }, + "jerk_support_infill": { + "value": "10" + }, + "initial_bottom_layers": { + "value": "3" + }, + "prime_tower_position_x": { + "value": "1" + }, + "acceleration_support_bottom": { + "value": "250" + }, + "speed_support_roof": { + "value": "33.33" + }, + "speed_support_infill": { + "value": "80" + }, + "bridge_skin_speed_2": { + "value": "15" + }, + "raft_fan_speed": { + "default_value": 100 + }, + "wipe_retraction_amount": { + "value": "3" + }, + "skin_edge_support_thickness": { + "value": "0" + }, + "bottom_layers": { + "value": "3" + }, + "retraction_extrusion_window": { + "value": "3" + }, + "acceleration_ironing": { + "value": "250" + }, + "support_top_distance": { + "value": "0.2" + }, + "travel_retract_before_outer_wall": { + "default_value": true + }, + "material_flow": { + "default_value": 99 + }, + "support_bottom_distance": { + "value": "0.2" + }, + "expand_skins_expand_distance": { + "value": "0.8" + }, + "jerk_wall": { + "value": "10" + }, + "support_zag_skip_count": { + "value": "8" + }, + "connect_infill_polygons": { + "value": "False" + }, + "acceleration_skirt_brim": { + "value": "250" + }, + "z_seam_corner": { + "default_value": "z_seam_corner_weighted" + }, + "raft_surface_jerk": { + "value": "10" + }, + "cross_infill_pocket_size": { + "value": "5.33" + }, + "support_infill_extruder_nr": { + "value": "0" + }, + "acceleration_enabled": { + "default_value": true + }, + "jerk_wall_x": { + "value": "10" + }, + "skin_overlap": { + "value": "15" + }, + "infill_material_flow": { + "value": "99" + }, + "speed_equalize_flow_max": { + "default_value": 40 + }, + "skin_preshrink": { + "value": "0.8" + }, + "speed_wall": { + "value": "20" + }, + "support_tree_collision_resolution": { + "value": "0.2" + }, + "meshfix_maximum_deviation": { + "default_value": 0.005 + }, + "jerk_roofing": { + "value": "10" + }, + "fill_outline_gaps": { + "default_value": true + }, + "layer_height": { + "default_value": 0.2 + }, + "remove_empty_first_layers": { + "default_value": false + }, + "prime_tower_flow": { + "value": "99" + }, + "support_roof_line_distance": { + "value": "0.57" + }, + "wipe_retraction_speed": { + "value": "30" + }, + "support_extruder_nr_layer_0": { + "value": "0" + }, + "layer_height_0": { + "default_value": 0.2 + }, + "multiple_mesh_overlap": { + "default_value": 0 + }, + "ooze_shield_dist": { + "default_value": 4 + }, + "jerk_enabled": { + "default_value": true + }, + "acceleration_support": { + "value": "400" + }, + "adhesion_extruder_nr": { + "value": "0" + }, + "skirt_line_count": { + "default_value": 2 + }, + "travel_compensate_overlapping_walls_x_enabled": { + "value": "False" + }, + "jerk_wall_0": { + "value": "10" + }, + "raft_speed": { + "value": "60" + }, + "speed_layer_0": { + "value": "10.0" + }, + "machine_width": { + "default_value": 210 + }, + "acceleration_wall": { + "value": "400" + }, + "jerk_infill": { + "value": "10" + }, + "wipe_hop_enable": { + "value": "False" + }, + "acceleration_travel_layer_0": { + "value": "400" + }, + "raft_interface_speed": { + "value": "60" + }, + "skin_edge_support_layers": { + "value": "0" + }, + "support_xy_distance_overhang": { + "value": "0.5" + }, + "brim_width": { + "default_value": 10 + }, + "coasting_enable": { + "default_value": true + }, + "jerk_print": { + "default_value": 10 + }, + "acceleration_support_roof": { + "value": "250" + }, + "prime_tower_min_volume": { + "default_value": 4 + }, + "support_roof_material_flow": { + "value": "99" + }, + "wall_0_wipe_dist": { + "value": "0" + }, + "jerk_topbottom": { + "value": "10" + }, + "retraction_count_max": { + "default_value": 30 + }, + "skin_overlap_mm": { + "value": "0.06" + }, + "extruders_enabled_count": { + "value": "2" + }, + "speed_support_bottom": { + "value": "33.33" + }, + "support_skip_some_zags": { + "default_value": true + }, + "ooze_shield_angle": { + "default_value": 50 + }, + "wall_thickness": { + "value": "1.2" + }, + "speed_print_layer_0": { + "value": "10.0" + } + } } \ No newline at end of file diff --git a/resources/definitions/stereotech_ste320.def.json b/resources/definitions/stereotech_ste320.def.json index 3eb114324b..3aa89effc5 100644 --- a/resources/definitions/stereotech_ste320.def.json +++ b/resources/definitions/stereotech_ste320.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "Stereotech", "manufacturer": "Stereotech LLC.", - "category": "Other", "platform": "stereotech_ste320_platform.obj", "platform_texture": "StereotechSte320backplate.png", "platform_offset": [ diff --git a/resources/definitions/strateo3d.def.json b/resources/definitions/strateo3d.def.json index 2ee3650404..4b1e4a3fbd 100644 --- a/resources/definitions/strateo3d.def.json +++ b/resources/definitions/strateo3d.def.json @@ -6,7 +6,6 @@ { "author": "M.K", "manufacturer": "eMotionTech", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "has_machine_quality": true, diff --git a/resources/definitions/ubuild-3d_mr_bot_280.def.json b/resources/definitions/ubuild-3d_mr_bot_280.def.json index 255d8f032b..f1c7bc7581 100644 --- a/resources/definitions/ubuild-3d_mr_bot_280.def.json +++ b/resources/definitions/ubuild-3d_mr_bot_280.def.json @@ -6,7 +6,6 @@ "visible": true, "author": "uBuild-3D", "manufacturer": "uBuild-3D", - "category": "Other", "file_formats": "text/x-gcode", "has_materials": true, "preferred_quality_type": "draft", diff --git a/resources/definitions/ultimaker.def.json b/resources/definitions/ultimaker.def.json index 7a60ff35c8..ff9a75c40c 100644 --- a/resources/definitions/ultimaker.def.json +++ b/resources/definitions/ultimaker.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Ultimaker", "manufacturer": "Ultimaker B.V.", - "category": "Ultimaker", "visible": false, "exclude_materials": [ "generic_hips", "generic_petg", "structur3d_dap100silicone" ] }, diff --git a/resources/definitions/ultimaker_s3.def.json b/resources/definitions/ultimaker_s3.def.json index 620de59373..824a0e3a92 100644 --- a/resources/definitions/ultimaker_s3.def.json +++ b/resources/definitions/ultimaker_s3.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Ultimaker", "manufacturer": "Ultimaker B.V.", - "category": "Ultimaker", "visible": true, "file_formats": "application/x-ufp;text/x-gcode", "platform": "ultimaker_s3_platform.obj", diff --git a/resources/definitions/ultimaker_s5.def.json b/resources/definitions/ultimaker_s5.def.json index d21edb0843..ded94a2747 100644 --- a/resources/definitions/ultimaker_s5.def.json +++ b/resources/definitions/ultimaker_s5.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Ultimaker", "manufacturer": "Ultimaker B.V.", - "category": "Ultimaker", "visible": true, "file_formats": "application/x-ufp;text/x-gcode", "platform": "ultimaker_s5_platform.obj", diff --git a/resources/definitions/uni_print_3d.def.json b/resources/definitions/uni_print_3d.def.json index 99d9eab1e0..0f00c23165 100644 --- a/resources/definitions/uni_print_3d.def.json +++ b/resources/definitions/uni_print_3d.def.json @@ -6,7 +6,6 @@ { "visible": true, "author": "Alexander Rössler", - "category": "Other", "manufacturer": "TheCoolTool", "file_formats": "text/x-ngc;text/x-gcode", "platform": "uni_print_3d_platform.stl", diff --git a/resources/definitions/winbo_dragonl4.def.json b/resources/definitions/winbo_dragonl4.def.json index f89d592be1..754a1a77a2 100644 --- a/resources/definitions/winbo_dragonl4.def.json +++ b/resources/definitions/winbo_dragonl4.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Winbo", "manufacturer": "Winbo Smart Tech Co., Ltd.", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "supports_usb_connection": false, diff --git a/resources/definitions/winbo_mini2.def.json b/resources/definitions/winbo_mini2.def.json index 49afd18ba8..c2d2d9b7f4 100644 --- a/resources/definitions/winbo_mini2.def.json +++ b/resources/definitions/winbo_mini2.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Winbo", "manufacturer": "Winbo Smart Tech Co., Ltd.", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "supports_usb_connection": true, diff --git a/resources/definitions/winbo_superhelper105.def.json b/resources/definitions/winbo_superhelper105.def.json index fab2e9f45f..576398551b 100644 --- a/resources/definitions/winbo_superhelper105.def.json +++ b/resources/definitions/winbo_superhelper105.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Winbo", "manufacturer": "Winbo Smart Tech Co., Ltd.", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "supports_usb_connection": true, diff --git a/resources/definitions/winbo_superhelper155.def.json b/resources/definitions/winbo_superhelper155.def.json index 65bb4e7b73..77b4bc31c5 100644 --- a/resources/definitions/winbo_superhelper155.def.json +++ b/resources/definitions/winbo_superhelper155.def.json @@ -5,7 +5,6 @@ "metadata": { "author": "Winbo", "manufacturer": "Winbo Smart Tech Co., Ltd.", - "category": "Other", "visible": true, "file_formats": "text/x-gcode", "supports_usb_connection": true, diff --git a/resources/extruders/predator_extruder_0.def.json b/resources/extruders/predator_extruder_0.def.json new file mode 100644 index 0000000000..59574ae69f --- /dev/null +++ b/resources/extruders/predator_extruder_0.def.json @@ -0,0 +1,15 @@ +{ + "version": 2, + "name": "Extruder 0", + "inherits": "fdmextruder", + "metadata": { + "machine": "predator", + "position": "0" + }, + + "overrides": { + "extruder_nr": { "default_value": 0 }, + "machine_nozzle_size": { "default_value": 0.4 }, + "material_diameter": { "default_value": 1.75 } + } +} diff --git a/resources/images/anycubic_predator.png b/resources/images/anycubic_predator.png new file mode 100644 index 0000000000..2ab214826a Binary files /dev/null and b/resources/images/anycubic_predator.png differ diff --git a/resources/meshes/FLSUN-QQ-S.stl b/resources/meshes/FLSUN-QQ-S.stl new file mode 100644 index 0000000000..d4fe2fbfbe Binary files /dev/null and b/resources/meshes/FLSUN-QQ-S.stl differ diff --git a/resources/meshes/predator_platform.stl b/resources/meshes/predator_platform.stl new file mode 100644 index 0000000000..ae65da7c52 Binary files /dev/null and b/resources/meshes/predator_platform.stl differ diff --git a/resources/qml/ObjectItemButton.qml b/resources/qml/ObjectItemButton.qml index b454fd929a..9244fa6391 100644 --- a/resources/qml/ObjectItemButton.qml +++ b/resources/qml/ObjectItemButton.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2018 Ultimaker B.V. +// Copyright (c) 2020 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.10 @@ -14,33 +14,11 @@ Button width: parent.width height: UM.Theme.getSize("action_button").height leftPadding: UM.Theme.getSize("thin_margin").width - rightPadding: UM.Theme.getSize("thin_margin").width + rightPadding: perObjectSettingsInfo.visible ? UM.Theme.getSize("default_lining").width : UM.Theme.getSize("thin_margin").width checkable: true hoverEnabled: true - contentItem: Item - { - width: objectItemButton.width - objectItemButton.leftPadding - height: UM.Theme.getSize("action_button").height - - Label - { - id: buttonText - anchors - { - left: parent.left - right: parent.right - verticalCenter: parent.verticalCenter - } - text: objectItemButton.text - font: UM.Theme.getFont("default") - color: UM.Theme.getColor("text_scene") - visible: text != "" - renderType: Text.NativeRendering - verticalAlignment: Text.AlignVCenter - elide: Text.ElideRight - } - } + onClicked: Cura.SceneController.changeSelection(index) background: Rectangle { @@ -51,6 +29,149 @@ Button border.color: objectItemButton.checked ? UM.Theme.getColor("primary") : "transparent" } + contentItem: Item + { + width: objectItemButton.width - objectItemButton.leftPadding + height: UM.Theme.getSize("action_button").height + + UM.RecolorImage + { + id: swatch + anchors.verticalCenter: parent.verticalCenter + anchors.left: parent.left + width: height + height: parent.height - UM.Theme.getSize("narrow_margin").height + source: UM.Theme.getIcon("extruder_button") + color: extruderColor + visible: showExtruderSwatches && extruderColor != "" + } + + Label + { + id: buttonText + anchors + { + left: showExtruderSwatches ? swatch.right : parent.left + leftMargin: showExtruderSwatches ? UM.Theme.getSize("narrow_margin").width : 0 + right: perObjectSettingsInfo.visible ? perObjectSettingsInfo.left : parent.right + verticalCenter: parent.verticalCenter + } + text: objectItemButton.text + font: UM.Theme.getFont("default") + color: UM.Theme.getColor("text_scene") + opacity: (outsideBuildArea) ? 0.5 : 1.0 + visible: text != "" + renderType: Text.NativeRendering + verticalAlignment: Text.AlignVCenter + elide: Text.ElideRight + } + + Button + { + id: perObjectSettingsInfo + + anchors + { + right: parent.right + rightMargin: 0 + } + width: childrenRect.width + height: parent.height + padding: 0 + leftPadding: UM.Theme.getSize("thin_margin").width + visible: meshType != "" || perObjectSettingsCount > 0 + + onClicked: + { + Cura.SceneController.changeSelection(index) + UM.Controller.setActiveTool("PerObjectSettingsTool") + } + + property string tooltipText: + { + var result = ""; + if (!visible) + { + return result; + } + if (meshType != "") + { + result += "
"; + switch (meshType) { + case "support_mesh": + result += catalog.i18nc("@label", "Is printed as support."); + break; + case "cutting_mesh": + result += catalog.i18nc("@label", "Other models overlapping with this model are modified."); + break; + case "infill_mesh": + result += catalog.i18nc("@label", "Infill overlapping with this model is modified."); + break; + case "anti_overhang_mesh": + result += catalog.i18nc("@label", "Overlaps with this model are not supported."); + break; + } + } + if (perObjectSettingsCount != "") + { + result += "
" + catalog.i18ncp( + "@label", "Overrides %1 setting.", "Overrides %1 settings.", perObjectSettingsCount + ).arg(perObjectSettingsCount); + } + return result; + } + + contentItem: Item + { + height: parent.height + width: meshTypeIcon.width + perObjectSettingsCountLabel.width + UM.Theme.getSize("narrow_margin").width + + Cura.NotificationIcon + { + id: perObjectSettingsCountLabel + anchors + { + right: parent.right + rightMargin: 0 + } + visible: perObjectSettingsCount > 0 + color: UM.Theme.getColor("text_scene") + labelText: perObjectSettingsCount.toString() + } + + UM.RecolorImage + { + id: meshTypeIcon + anchors + { + right: perObjectSettingsCountLabel.left + rightMargin: UM.Theme.getSize("narrow_margin").width + } + + width: parent.height + height: parent.height + color: UM.Theme.getColor("text_scene") + visible: meshType != "" + source: + { + switch (meshType) { + case "support_mesh": + return UM.Theme.getIcon("pos_print_as_support"); + case "cutting_mesh": + case "infill_mesh": + return UM.Theme.getIcon("pos_modify_overlaps"); + case "anti_overhang_mesh": + return UM.Theme.getIcon("pos_modify_dont_support_overlap"); + } + return ""; + } + } + } + + background: Item {} + } + } + TextMetrics { id: buttonTextMetrics @@ -63,9 +184,13 @@ Button Cura.ToolTip { id: tooltip - tooltipText: objectItemButton.text - visible: objectItemButton.hovered && buttonTextMetrics.elidedText != buttonText.text + tooltipText: objectItemButton.text + perObjectSettingsInfo.tooltipText + visible: objectItemButton.hovered && (buttonTextMetrics.elidedText != buttonText.text || perObjectSettingsInfo.visible) } - onClicked: Cura.SceneController.changeSelection(index) + UM.I18nCatalog + { + id: catalog + name: "cura" + } } diff --git a/resources/qml/ObjectSelector.qml b/resources/qml/ObjectSelector.qml index 6757863e1c..15cb476e08 100644 --- a/resources/qml/ObjectSelector.qml +++ b/resources/qml/ObjectSelector.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2019 Ultimaker B.V. +// Copyright (c) 2020 Ultimaker B.V. // Cura is released under the terms of the LGPLv3 or higher. import QtQuick 2.10 @@ -87,6 +87,17 @@ Item anchors.bottom: parent.bottom + property var extrudersModel: CuraApplication.getExtrudersModel() + UM.SettingPropertyProvider + { + id: machineExtruderCount + + containerStack: Cura.MachineManager.activeMachine + key: "machine_extruder_count" + watchedProperties: [ "value" ] + storeIndex: 0 + } + ListView { id: listView @@ -120,6 +131,19 @@ Item } text: model.name width: listView.width + property bool outsideBuildArea: model.outside_build_area + property int perObjectSettingsCount: model.per_object_settings_count + property string meshType: model.mesh_type + property int extruderNumber: model.extruder_number + property string extruderColor: + { + if (model.extruder_number == -1) + { + return ""; + } + return contents.extrudersModel.getItem(model.extruder_number).color; + } + property bool showExtruderSwatches: machineExtruderCount.properties.value > 1 } } } diff --git a/resources/qml/WelcomePages/AddNetworkOrLocalPrinterContent.qml b/resources/qml/WelcomePages/AddNetworkOrLocalPrinterContent.qml index 51f73c2618..9e892e5521 100644 --- a/resources/qml/WelcomePages/AddNetworkOrLocalPrinterContent.qml +++ b/resources/qml/WelcomePages/AddNetworkOrLocalPrinterContent.qml @@ -157,8 +157,9 @@ Item const networkPrinterItem = addNetworkPrinterDropDown.contentItem.currentItem CuraApplication.getDiscoveredPrintersModel().createMachineFromDiscoveredPrinter(networkPrinterItem) - // If we have created a machine, go to the last page, which is the "cloud" page. - base.goToPage("cloud") + // If we have created a machine, end the wizard (since this is the last page) + base.endWizard() + } else { diff --git a/resources/quality/anycubic_predator/predator_coarse.inst.cfg b/resources/quality/anycubic_predator/predator_coarse.inst.cfg new file mode 100644 index 0000000000..e8c6f72e8e --- /dev/null +++ b/resources/quality/anycubic_predator/predator_coarse.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Coarse +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = coarse +weight = -3 +global_quality = True + +[values] +layer_height = 0.4 +layer_height_0 = 0.45 \ No newline at end of file diff --git a/resources/quality/anycubic_predator/predator_draft.inst.cfg b/resources/quality/anycubic_predator/predator_draft.inst.cfg new file mode 100644 index 0000000000..d94920785d --- /dev/null +++ b/resources/quality/anycubic_predator/predator_draft.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Draft +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = draft +weight = -2 +global_quality = True + +[values] +layer_height = 0.30 +layer_height_0 = 0.35 \ No newline at end of file diff --git a/resources/quality/anycubic_predator/predator_extra_coarse.inst.cfg b/resources/quality/anycubic_predator/predator_extra_coarse.inst.cfg new file mode 100644 index 0000000000..bad550ee1f --- /dev/null +++ b/resources/quality/anycubic_predator/predator_extra_coarse.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Extra Coarse +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = Xcoarse +weight = -4 +global_quality = True + +[values] +layer_height = 0.5 +layer_height_0 = 0.55 diff --git a/resources/quality/anycubic_predator/predator_extra_fine.inst.cfg b/resources/quality/anycubic_predator/predator_extra_fine.inst.cfg new file mode 100644 index 0000000000..7e745c5454 --- /dev/null +++ b/resources/quality/anycubic_predator/predator_extra_fine.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Extra Fine +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = Xfine +weight = 1 +global_quality = True + +[values] +layer_height = 0.05 +layer_height_0 = 0.10 diff --git a/resources/quality/anycubic_predator/predator_fine.inst.cfg b/resources/quality/anycubic_predator/predator_fine.inst.cfg new file mode 100644 index 0000000000..1c6d3555c9 --- /dev/null +++ b/resources/quality/anycubic_predator/predator_fine.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Fine +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = fine +weight = 1 +global_quality = True + +[values] +layer_height = 0.1 +layer_height_0 = 0.15 diff --git a/resources/quality/anycubic_predator/predator_normal.inst.cfg b/resources/quality/anycubic_predator/predator_normal.inst.cfg new file mode 100644 index 0000000000..6f5db85938 --- /dev/null +++ b/resources/quality/anycubic_predator/predator_normal.inst.cfg @@ -0,0 +1,15 @@ +[general] +version = 4 +name = Normal +definition = predator + +[metadata] +setting_version = 13 +type = quality +quality_type = normal +weight = 0 +global_quality = True + +[values] +layer_height = 0.2 +layer_height_0 = 0.25 \ No newline at end of file diff --git a/resources/quality/beamup_s/beamup_s_coarse.inst.cfg b/resources/quality/beamup_s/beamup_s_coarse.inst.cfg index 9f82b7b138..20decc8ded 100644 --- a/resources/quality/beamup_s/beamup_s_coarse.inst.cfg +++ b/resources/quality/beamup_s/beamup_s_coarse.inst.cfg @@ -1,18 +1,18 @@ -[general] -version = 4 -name = BeamUp S Coarse -definition = beamup_s - -[metadata] -setting_version = 10 -type = quality -quality_type = coarse -weight = -3 -material = generic_pla - -[values] -layer_height = 0.30 -adhesion_type = brim +[general] +version = 4 +name = BeamUp S Coarse +definition = beamup_s + +[metadata] +setting_version = 13 +type = quality +quality_type = coarse +weight = -3 +material = generic_pla + +[values] +layer_height = 0.30 +adhesion_type = brim brim_line_count = 5 infill_before_walls = False initial_layer_line_width_factor = 120.0 @@ -37,4 +37,4 @@ support_interface_skip_height = 0.30 support_offset = 0.8 support_z_distance = 0.2 wall_thickness = 0.8 -zig_zaggify_infill = True +zig_zaggify_infill = True diff --git a/resources/quality/beamup_s/beamup_s_draft.inst.cfg b/resources/quality/beamup_s/beamup_s_draft.inst.cfg index a696fafd2b..d172ea3925 100644 --- a/resources/quality/beamup_s/beamup_s_draft.inst.cfg +++ b/resources/quality/beamup_s/beamup_s_draft.inst.cfg @@ -1,18 +1,18 @@ -[general] -version = 4 -name = BeamUp S Draft -definition = beamup_s - -[metadata] -setting_version = 10 -type = quality -quality_type = draft -weight = -2 -material = generic_pla - -[values] -layer_height = 0.2 -adhesion_type = brim +[general] +version = 4 +name = BeamUp S Draft +definition = beamup_s + +[metadata] +setting_version = 13 +type = quality +quality_type = draft +weight = -2 +material = generic_pla + +[values] +layer_height = 0.2 +adhesion_type = brim brim_line_count = 5 infill_before_walls = False initial_layer_line_width_factor = 120.0 @@ -37,4 +37,4 @@ support_interface_skip_height = 0.20 support_offset = 0.8 support_z_distance = 0.2 wall_thickness = 0.8 -zig_zaggify_infill = True +zig_zaggify_infill = True diff --git a/resources/quality/beamup_s/beamup_s_extra_fine.inst.cfg b/resources/quality/beamup_s/beamup_s_extra_fine.inst.cfg index ee1a1cb6a7..b6783bf8e8 100644 --- a/resources/quality/beamup_s/beamup_s_extra_fine.inst.cfg +++ b/resources/quality/beamup_s/beamup_s_extra_fine.inst.cfg @@ -1,18 +1,18 @@ -[general] -version = 4 -name = BeamUp S Extra Fine -definition = beamup_s - -[metadata] -setting_version = 10 -type = quality -quality_type = high -weight = 1 -material = generic_pla - -[values] -layer_height = 0.06 -adhesion_type = brim +[general] +version = 4 +name = BeamUp S Extra Fine +definition = beamup_s + +[metadata] +setting_version = 13 +type = quality +quality_type = high +weight = 1 +material = generic_pla + +[values] +layer_height = 0.06 +adhesion_type = brim brim_line_count = 5 infill_before_walls = False initial_layer_line_width_factor = 120.0 @@ -37,4 +37,4 @@ support_interface_skip_height = 0.06 support_offset = 0.8 support_z_distance = 0.2 wall_thickness = 0.8 -zig_zaggify_infill = True +zig_zaggify_infill = True diff --git a/resources/quality/beamup_s/beamup_s_fine.inst.cfg b/resources/quality/beamup_s/beamup_s_fine.inst.cfg index c68f854536..9f6686487e 100644 --- a/resources/quality/beamup_s/beamup_s_fine.inst.cfg +++ b/resources/quality/beamup_s/beamup_s_fine.inst.cfg @@ -1,18 +1,18 @@ -[general] -version = 4 -name = BeamUp S Fine -definition = beamup_s - -[metadata] -setting_version = 10 -type = quality -quality_type = normal -weight = 0 -material = generic_pla - -[values] -layer_height = 0.1 -adhesion_type = brim +[general] +version = 4 +name = BeamUp S Fine +definition = beamup_s + +[metadata] +setting_version = 13 +type = quality +quality_type = normal +weight = 0 +material = generic_pla + +[values] +layer_height = 0.1 +adhesion_type = brim brim_line_count = 5 infill_before_walls = False initial_layer_line_width_factor = 120.0 @@ -37,4 +37,4 @@ support_interface_skip_height = 0.10 support_offset = 0.8 support_z_distance = 0.2 wall_thickness = 0.8 -zig_zaggify_infill = True +zig_zaggify_infill = True diff --git a/resources/quality/beamup_s/beamup_s_normal.inst.cfg b/resources/quality/beamup_s/beamup_s_normal.inst.cfg index 7b692d2cb3..f926cb11a8 100644 --- a/resources/quality/beamup_s/beamup_s_normal.inst.cfg +++ b/resources/quality/beamup_s/beamup_s_normal.inst.cfg @@ -1,18 +1,18 @@ -[general] -version = 4 -name = BeamUp S Normal -definition = beamup_s - -[metadata] -setting_version = 10 -type = quality -quality_type = fast -weight = -1 -material = generic_pla - -[values] -layer_height = 0.15 -adhesion_type = brim +[general] +version = 4 +name = BeamUp S Normal +definition = beamup_s + +[metadata] +setting_version = 13 +type = quality +quality_type = fast +weight = -1 +material = generic_pla + +[values] +layer_height = 0.15 +adhesion_type = brim brim_line_count = 5 infill_before_walls = False initial_layer_line_width_factor = 120.0 @@ -37,4 +37,4 @@ support_interface_skip_height = 0.15 support_offset = 0.8 support_z_distance = 0.2 wall_thickness = 0.8 -zig_zaggify_infill = True +zig_zaggify_infill = True diff --git a/resources/quality/katihal/alyanx3dp_normal_generic_pla.inst.cfg b/resources/quality/katihal/alyanx3dp_normal_generic_pla.inst.cfg index 4c79a3ac78..009f6c89bc 100644 --- a/resources/quality/katihal/alyanx3dp_normal_generic_pla.inst.cfg +++ b/resources/quality/katihal/alyanx3dp_normal_generic_pla.inst.cfg @@ -4,7 +4,7 @@ definition = alyanx3dp name = Normal [metadata] -setting_version = 6 +setting_version = 13 type = quality quality_type = alyanx_normal weight = 2 diff --git a/resources/quality/makeblock/makeblock_mcreate_pla_normal.inst.cfg b/resources/quality/makeblock/makeblock_mcreate_pla_normal.inst.cfg index 661695cca0..7f3384a29f 100644 --- a/resources/quality/makeblock/makeblock_mcreate_pla_normal.inst.cfg +++ b/resources/quality/makeblock/makeblock_mcreate_pla_normal.inst.cfg @@ -4,7 +4,7 @@ name = Fine definition = makeblock_mcreate [metadata] -setting_version = 6 +setting_version = 13 type = quality quality_type = normal weight = 0 diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_adaptive.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_adaptive.inst.cfg index de5c97f913..2428d5c64d 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive material = generic_abs diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_good.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_good.inst.cfg index 9a49399734..acccc5190b 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_good.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good material = generic_abs diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_low.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_low.inst.cfg index 2515cc32eb..2971e89ce2 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_low.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low material = generic_abs diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_standard.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_standard.inst.cfg index 9b140cbb75..95e19fb800 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_standard.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard material = generic_abs diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_super.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_super.inst.cfg index 55dd8755fb..525a1dca8b 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_super.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super material = generic_abs diff --git a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_ultra.inst.cfg b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_ultra.inst.cfg index 748b4d6c50..bb9ac9f1af 100644 --- a/resources/quality/rigid3d_base/abs/rigid3d_base_abs_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/abs/rigid3d_base_abs_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra material = generic_abs diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_adaptive.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_adaptive.inst.cfg index cd2e5804cd..e1b98bdacf 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive material = generic_nylon diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_good.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_good.inst.cfg index 11ecdbf8d7..597f954879 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_good.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good material = generic_nylon diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_low.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_low.inst.cfg index d512935d05..d4f71ce09a 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_low.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low material = generic_nylon diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_standard.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_standard.inst.cfg index e936714f2c..cf2c326bde 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_standard.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard material = generic_nylon diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_super.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_super.inst.cfg index b634af5a7f..76b0e03252 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_super.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super material = generic_nylon diff --git a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_ultra.inst.cfg b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_ultra.inst.cfg index 583d8660f8..ea28a18bf6 100644 --- a/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/nylon/rigid3d_base_nylon_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra material = generic_nylon diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_adaptive.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_adaptive.inst.cfg index ae8de691b7..4cbbac976c 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive material = generic_petg diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_good.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_good.inst.cfg index 7a97e15b90..085f63fd29 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_good.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good material = generic_petg diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_low.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_low.inst.cfg index c3153454b8..441223b259 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_low.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low material = generic_petg diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_standard.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_standard.inst.cfg index d583ab6514..6eb60cbe30 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_standard.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard material = generic_petg diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_super.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_super.inst.cfg index cb77ab35d8..ab284f19bd 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_super.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super material = generic_petg diff --git a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_ultra.inst.cfg b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_ultra.inst.cfg index 6ab237d97b..d4b0c58c70 100644 --- a/resources/quality/rigid3d_base/petg/rigid3d_base_petg_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/petg/rigid3d_base_petg_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra material = generic_petg diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_adaptive.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_adaptive.inst.cfg index 67ece9b983..f88063ebd1 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive material = generic_pla diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_good.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_good.inst.cfg index ebc48e1e47..2eeed8c565 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_good.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good material = generic_pla diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_low.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_low.inst.cfg index a2cc3d8ada..6e62844cf4 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_low.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low material = generic_pla diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_standard.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_standard.inst.cfg index 6f30e132f4..4ffd5305c4 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_standard.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard material = generic_pla diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_super.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_super.inst.cfg index 075aaa18e4..8487f78f55 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_super.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super material = generic_pla diff --git a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_ultra.inst.cfg b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_ultra.inst.cfg index 7460b92cb3..e9886bf1b5 100644 --- a/resources/quality/rigid3d_base/pla/rigid3d_base_pla_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/pla/rigid3d_base_pla_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra material = generic_pla diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_adaptive.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_adaptive.inst.cfg index 2ca4e97ba9..9aa132a769 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive weight = -6 diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_good.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_good.inst.cfg index 1e5da51f73..8bc628eeec 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_good.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good weight = -2 diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_low.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_low.inst.cfg index f93f3c83df..7de29f815d 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_low.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low weight = -4 diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_standard.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_standard.inst.cfg index 0fce643397..6cb9e65c33 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_standard.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard weight = -3 diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_super.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_super.inst.cfg index 5ff420ea23..b160a086b9 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_super.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super weight = -1 diff --git a/resources/quality/rigid3d_base/rigid3d_base_global_ultra.inst.cfg b/resources/quality/rigid3d_base/rigid3d_base_global_ultra.inst.cfg index 6f96648312..9bc40461ee 100644 --- a/resources/quality/rigid3d_base/rigid3d_base_global_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/rigid3d_base_global_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra weight = 0 diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_adaptive.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_adaptive.inst.cfg index bc93daa751..e4dda56ce2 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_adaptive.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_adaptive.inst.cfg @@ -4,7 +4,7 @@ name = Dynamic Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = adaptive material = generic_tpu diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_good.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_good.inst.cfg index 0f0b3fad82..8cb55d02de 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_good.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_good.inst.cfg @@ -4,7 +4,7 @@ name = Good Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = good material = generic_tpu diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_low.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_low.inst.cfg index c0653ede27..3a7bfbf138 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_low.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_low.inst.cfg @@ -4,7 +4,7 @@ name = Low Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = low material = generic_tpu diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_standard.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_standard.inst.cfg index a0aa088d5b..392c3aa303 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_standard.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_standard.inst.cfg @@ -4,7 +4,7 @@ name = Standard Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = standard material = generic_tpu diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_super.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_super.inst.cfg index 23a6e77aca..29e1565547 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_super.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_super.inst.cfg @@ -4,7 +4,7 @@ name = Super Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = super material = generic_tpu diff --git a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_ultra.inst.cfg b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_ultra.inst.cfg index 206a8c7c01..92f49140bd 100644 --- a/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_ultra.inst.cfg +++ b/resources/quality/rigid3d_base/tpu/rigid3d_base_tpu_ultra.inst.cfg @@ -4,7 +4,7 @@ name = Ultra Quality definition = rigid3d_base [metadata] -setting_version = 9 +setting_version = 13 type = quality quality_type = ultra material = generic_tpu diff --git a/tests/Settings/TestDefinitionContainer.py b/tests/Settings/TestDefinitionContainer.py index 9edf7f3d36..2f2b343338 100644 --- a/tests/Settings/TestDefinitionContainer.py +++ b/tests/Settings/TestDefinitionContainer.py @@ -45,6 +45,18 @@ def test_definitionIds(file_path): definition_id = os.path.basename(file_path).split(".")[0] assert " " not in definition_id # Definition IDs are not allowed to have spaces. +@pytest.mark.parametrize("file_path", definition_filepaths) +def test_noCategory(file_path): + """ + Categories for definition files have been deprecated. Test that they are not + present. + :param file_path: The path of the machine definition to test. + """ + with open(file_path, encoding = "utf-8") as f: + json = f.read() + metadata = DefinitionContainer.deserializeMetadata(json, "test_container_id") + assert "category" not in metadata[0] + ## Tests all definition containers @pytest.mark.parametrize("file_path", machine_filepaths) def test_validateMachineDefinitionContainer(file_path, definition_container): @@ -59,7 +71,6 @@ def test_validateMachineDefinitionContainer(file_path, definition_container): with patch("UM.VersionUpgradeManager.VersionUpgradeManager.getInstance", MagicMock(return_value = mocked_vum)): assertIsDefinitionValid(definition_container, file_path) - def assertIsDefinitionValid(definition_container, file_path): with open(file_path, encoding = "utf-8") as data: json = data.read() diff --git a/tests/TestObjectsModel.py b/tests/TestObjectsModel.py index caed4741bb..543334cea6 100644 --- a/tests/TestObjectsModel.py +++ b/tests/TestObjectsModel.py @@ -125,7 +125,16 @@ class Test_Update: application_with_mocked_scene.getController().getScene().getRoot = MagicMock(return_value = group_scene_node) with patch("UM.Application.Application.getInstance", MagicMock(return_value=application_with_mocked_scene)): objects_model._update() - assert objects_model.items == [{'name': 'Group #1', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': group_scene_node}] + assert objects_model.items == [{ + 'name': 'Group #1', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': group_scene_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }] def test_updateWithNonGroup(self, objects_model, application_with_mocked_scene, slicable_scene_node): objects_model._shouldNodeBeHandled = MagicMock(return_value=True) @@ -133,7 +142,16 @@ class Test_Update: application_with_mocked_scene.getController().getScene().getRoot = MagicMock(return_value=slicable_scene_node) with patch("UM.Application.Application.getInstance", MagicMock(return_value=application_with_mocked_scene)): objects_model._update() - assert objects_model.items == [{'name': 'YAY(1)', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': slicable_scene_node}] + assert objects_model.items == [{ + 'name': 'YAY(1)', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': slicable_scene_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }] def test_updateWithNonTwoNodes(self, objects_model, application_with_mocked_scene, slicable_scene_node): objects_model._shouldNodeBeHandled = MagicMock(return_value=True) @@ -143,7 +161,25 @@ class Test_Update: application_with_mocked_scene.getController().getScene().getRoot = MagicMock(return_value=slicable_scene_node) with patch("UM.Application.Application.getInstance", MagicMock(return_value=application_with_mocked_scene)): objects_model._update() - assert objects_model.items == [{'name': 'YAY', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': slicable_scene_node}, {'name': 'YAY(1)', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': copied_node}] + assert objects_model.items == [{ + 'name': 'YAY', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': slicable_scene_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }, { + 'name': 'YAY(1)', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': copied_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }] def test_updateWithNonTwoGroups(self, objects_model, application_with_mocked_scene, group_scene_node): objects_model._shouldNodeBeHandled = MagicMock(return_value=True) @@ -153,7 +189,25 @@ class Test_Update: application_with_mocked_scene.getController().getScene().getRoot = MagicMock(return_value=group_scene_node) with patch("UM.Application.Application.getInstance", MagicMock(return_value=application_with_mocked_scene)): objects_model._update() - assert objects_model.items == [{'name': 'Group #1', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': group_scene_node}, {'name': 'Group #2', 'selected': False, 'outside_build_area': False, 'buildplate_number': None, 'node': copied_node}] + assert objects_model.items == [{ + 'name': 'Group #1', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': group_scene_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }, { + 'name': 'Group #2', + 'selected': False, + 'outside_build_area': False, + 'buildplate_number': None, + 'node': copied_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }] def test_updateOutsideBuildplate(self, objects_model, application_with_mocked_scene, group_scene_node): objects_model._shouldNodeBeHandled = MagicMock(return_value=True) @@ -162,5 +216,14 @@ class Test_Update: application_with_mocked_scene.getController().getScene().getRoot = MagicMock(return_value=group_scene_node) with patch("UM.Application.Application.getInstance", MagicMock(return_value=application_with_mocked_scene)): objects_model._update() - assert objects_model.items == [{'name': 'Group #1', 'selected': False, 'outside_build_area': True, 'buildplate_number': None, 'node': group_scene_node}] + assert objects_model.items == [{ + 'name': 'Group #1', + 'selected': False, + 'outside_build_area': True, + 'buildplate_number': None, + 'node': group_scene_node, + "extruder_number": -1, + "per_object_settings_count": 0, + "mesh_type": "" + }]