11407 Commits

Author SHA1 Message Date
Jack Ha
3b25191949 Undo a fix that causes Cura to crash when starting up clean.
Contributes to issue CURA-4243.
2017-12-04 17:00:43 +01:00
Jack Ha
90e8256f46 Fix that renaming a custom material also updates the selected material.
The namechanged signal was not connected at startup, so the update would only work if you change material first before renaming.

Contributes to CURA-4243.
2017-12-04 16:30:21 +01:00
Jack Ha
c52451217b Use timer instead of calling _update directly.
Speeds up when the signal is called very often in a small period.

Contributes to issue CURA-4243.
2017-12-04 16:29:21 +01:00
Jack Ha
ac97d0d83f Sort materials by brand, material, name, color_name.
Contributes to issue CURA-4243.
2017-12-04 13:23:30 +01:00
Jack Ha
44537c4ef4 Added sorting by brand to MaterialsModel.
Contributes to issue CURA-4243.
2017-12-04 11:11:57 +01:00
Ghostkeeper
72c7d2bd76
Reconstruct ID for submaterials from unique base name
When you make the ID of the subprofile unique it doesn't get linked to the base profile any more since the '#2' gets put at the end.

Contributes to issue CURA-4243.
2017-12-04 11:04:28 +01:00
Ghostkeeper
bc28189ff5
Don't serialize the name of the metadata
It's being serialized in a different place.

Contributes to issue CURA-4243.
2017-12-04 10:55:30 +01:00
Ghostkeeper
083a4a8024
Rewrite cloning of materials
The original was based on reading the original file back, but that won't work if the files are provided by an arbitrary container provider. Instead we'll actually make a copy of all the profiles that need to be copied. It's much faster as well.

Contributes to issue CURA-4243.
2017-12-01 16:19:58 +01:00
Ghostkeeper
17ede12573
Also set base_file metadata when deserialising just metadata
Contributes to issue CURA-4243.
2017-12-01 16:07:30 +01:00
Ruben D
d29d73413f
Remove unused function
Contributes to issue CURA-4243.
2017-11-30 01:11:10 +01:00
Ruben D
f9c59c7e1e
Don't update model if extruders haven't all been loaded yet
This model is created while the extruder stacks have not yet been filled in. You can't connect yet. When the extruder is ready, _extrudersChanged will be called again and then the new extruder will also get connected.

Contributes to issue CURA-4243.
2017-11-30 00:33:10 +01:00
Ruben D
c1ba64fd9e
Correct variants after all metadata is loaded
As explained in the block of documentation, we can't find the variants because there is no guarantee that the variants have been loaded by the time that the metadata of materials is deserialised and we don't know their IDs either (so no lazy loading). This registers a function to be called upon completely loading the metadata, which runs a query on the metadata to find the variant by its definition and name. A bit hacky but I see no better solution.

Contributes to issue CURA-4243.
2017-11-30 00:10:02 +01:00
Ghostkeeper
c34de83e3f
Use isLoaded to check if a material is already loaded
This prevents us from having to make an expensive findContainers call if it's not necessary, and also prevents us from unnecessarily loading the subcontainers in a loop during loading.

Contributes to issue CURA-4243.
2017-11-29 18:04:07 +01:00
Ghostkeeper
cacc4b8586
Properly set the definition to the currently processed machine
Otherwise all of them stay at fdmprinter.

Contributes to issue CURA-4243.
2017-11-29 16:41:20 +01:00
Ghostkeeper
838e49f3da
Pass just metadata through quality manager instead of full containers
Where we only need metadata, we should pass metadata instead of full containers.
Also add some type hinting.

Contributes to issue CURA-4243.
2017-11-29 14:33:04 +01:00
Ghostkeeper
99cd139ba4
Remove setting definition double
Contributes to issue CURA-4243.
2017-11-29 13:39:24 +01:00
Ghostkeeper
dad99f5292
Merge branch 'master' into feature_local_container_server
Contributes to issue CURA-4243.
2017-11-29 13:06:08 +01:00
Ghostkeeper
8707396ad7
Remove isReadOnly functionality
Everyone should now ask it from the container registry.

Contributes to issue CURA-4243.
2017-11-28 17:30:00 +01:00
Ghostkeeper
c63ef6fed6
Remove unused variables
The machine_name variable is later redefined.

Contributes to issue CURA-4243.
2017-11-28 16:58:04 +01:00
Ghostkeeper
381d9bf3f1
Log which file caused it to go wrong
Contributes to issue CURA-4243.
2017-11-28 16:15:20 +01:00
Ghostkeeper
56d6664c8c
Guard against materials not having a definition
The empty container has no definition.

Contributes to issue CURA-4243.
2017-11-28 15:33:21 +01:00
Ghostkeeper
eb3981b4e0
Let _fetchInstanceContainers return containers split by loaded or not
It must now return two dictionaries: One for the profiles that have been completely loaded and one for the profiles that are only metadata. We could probably improve on these a little bit, since all of these (except the material model) will now load all available quality profiles. I'll see if it is necessary to optimise that.

Contributes to issue CURA-4243.
2017-11-28 14:26:14 +01:00
Lipu Fei
7d01e3388f Merge remote-tracking branch 'upstream/3.1' 2017-11-28 11:36:03 +01:00
Lipu Fei
6db06ea713 Fix project loading for single-extrusion machines
CURA-4617
2017-11-28 11:17:17 +01:00
ChrisTerBeke
9db8bff924 Merge pull request #2838 from fieldOfView/fix_crashhandler_crash
Fix error when CrashHandler is opened before opengl is initialised
2017-11-28 10:38:23 +01:00
ChrisTerBeke
68cd9df65f Merge branch '3.1' 2017-11-28 10:36:11 +01:00
ChrisTerBeke
7b30e9a6fc
Merge pull request #2856 from Ultimaker/simulation_view_gradient_changes
Adapt gradient in Simulation view for better visualization of feedrates
2017-11-28 10:34:10 +01:00
ChrisTerBeke
ec281dc1d5
Merge pull request #2861 from Builder3D/master
Removed the "Not supported" materials Builder Premium
2017-11-28 09:55:46 +01:00
Diego Prado Gesto
49537b64f7 CURA-4482 Fix error in SolidView when the support angle stack doesn't
exist. This error was sent twice through the CrashHandler and it is in Metabase.
2017-11-28 09:39:57 +01:00
Buco
af0b949a6f Changed Setting version
Setting version to 4
2017-11-28 09:28:25 +01:00
Buco
6caa434dc2 Add Quality Profiles
Added extra Quality profiles for BVOH, PET, Innoflex60 and PVA
2017-11-28 09:07:34 +01:00
Buco
228c373133
Merge pull request #1 from Ultimaker/master
Update from original
2017-11-28 08:32:39 +01:00
Ruben D
ab64cb5749
Add print head shape
Fixes #2808.
2017-11-27 23:10:58 +01:00
ChrisTerBeke
67d6b6ab6f Merge branch '3.1' 2017-11-27 17:36:41 +01:00
ChrisTerBeke
0e2f60f18b Fix toggling UM2 upgrades on extruder 0 - CURA-4626 2017-11-27 17:35:57 +01:00
ChrisTerBeke
e6e8353ea8
Merge pull request #2838 from fieldOfView/fix_crashhandler_crash
Fix error when CrashHandler is opened before opengl is initialised
2017-11-27 17:18:38 +01:00
ChrisTerBeke
a072af5585 Merge branch '3.1' 2017-11-27 17:17:02 +01:00
ChrisTerBeke
b74ebc57b4 Fix per extruder setting value depending on extruder count - CURA-4627 2017-11-27 17:00:57 +01:00
ChrisTerBeke
26b9fc3163 Only create extruder stack for single extrusion machine when not yet existing - CURA-4482 2017-11-27 16:55:01 +01:00
ChrisTerBeke
8cfaa44580 Fix resolving global stack definition when switching variant - CURA-4620 2017-11-27 16:40:23 +01:00
Ghostkeeper
e5427eded6
Refactor _getBasicMaterials to only handle metadata
Otherwise the full profile of all materials and all their definitions gets loaded.

Contributes to issue CURA-4243.
2017-11-27 15:38:11 +01:00
ChrisTerBeke
9e6704a162 Fix extruder stack machine definition link for per extruder settings resolvement - CURA-4627 2017-11-27 15:14:32 +01:00
Lipu Fei
33a06e13a9 Remove legacy if check in project loading
CURA-4617
2017-11-27 14:27:11 +01:00
Ghostkeeper
952e3974eb
Remove convenience handling of 'None'
Because this parameter has type checking, we'll get warned if this variable is None.

Contributes to issue CURA-4243.
2017-11-27 14:22:09 +01:00
Ghostkeeper
54a12d14c4
Add string representation for debugging
My IDE shows the str(inst) representation of an object when indicating what value is in there. This makes it easier to find stuff. It'll also make debug prints more clear than the default <XmlMaterialProfile.XmlMaterialProfile.XmlMaterialProfile object at 0x12345678> stuff of Python.

Contributes to issue CURA-4243.
2017-11-27 14:19:30 +01:00
Lipu Fei
49cac860a8 Fix project loading
CURA-4617
2017-11-27 14:17:13 +01:00
Ghostkeeper
17a25f98a4
Merge branch '3.1' 2017-11-27 13:58:52 +01:00
Ghostkeeper
13124ae983
Don't make filter_out_tiny_gaps a child setting of fill_perimeter_gaps
Parent settings are not used by the engine. Or they shouldn't be, because the parent settings are disabled by the front-end when all of their child settings are overwritten. Then you'd have a parent setting that is used by the engine but you can't modify it. Also, the command-line slicing doesn't load parent settings since it can't parse categories and such.
2017-11-27 13:58:34 +01:00
Buco
53627c5f1f Removed the "Not supported" materials
Removed the "not supported" materials. So all the other material quality profiles, BVOH, global, Innoflex60, PET, PLA and PVA are supported by our printer. In Cura 3.1 beta only PLA is supported.
2017-11-27 13:58:10 +01:00
Ghostkeeper
65ea8a614c
Don't make filter_out_tiny_gaps a child setting of fill_perimeter_gaps
Parent settings are not used by the engine. Or they shouldn't be, because the parent settings are disabled by the front-end when all of their child settings are overwritten. Then you'd have a parent setting that is used by the engine but you can't modify it. Also, the command-line slicing doesn't load parent settings since it can't parse categories and such.
2017-11-27 13:54:29 +01:00