569 Commits

Author SHA1 Message Date
Jaime van Kessel
506f2b9820
Remove code duplication in createAbstractMachine
This also caused a crash when an abstract machine with multiple extruders was selected

CURA-8463
2022-08-26 14:08:03 +02:00
c.lamboo
ff7c9eddde Add documentation
CURA-9514, CURA-9277
2022-08-26 11:34:34 +02:00
c.lamboo
f000b75661 Move getMachinesWithDefinition to MachinesManager
CURA-9514, CURA-9277
2022-08-26 11:16:10 +02:00
c.lamboo
8b84db7059 Remove AbstractMachine
Having a separate class for the AbstractMachine complicated things; it's behaviour was extremely similar to the GlobalStack so adding one more stack container type in addition to the many similar setting container types we already have adds complexity to the system. Having these different classes for machines and abstract machines also add complexity to the update script as the abstract machines were stored in a separate folder from the machine types.

Because of these reasons we decided to replace the AbstractMachine by a GlobalStack where the is_abstract_machine property metadata property is set to True.

CURA-9514, CURA-9277

Co-authored-by: joeydelarago <joeydelarago@gmail.com>
2022-08-26 10:45:45 +02:00
joeydelarago
04580b8fdc Simplify logic by having abstract printers always be online.
CURA-9221
2022-08-24 14:33:04 +02:00
joeydelarago
1e898ff930 Remove redundant comment
CURA-9514
2022-08-24 10:23:35 +02:00
joeydelarago
91b8c97dae Subtract online printers from list of all printers instead of searching for offline printers.
This prevents printers without "is_online" in the metadata from being left out, and is generally more defensive for uncertain states.

CURA-9514
2022-08-24 10:09:45 +02:00
joeydelarago
035fb27ab0 Code style
CURA-9514
2022-08-23 15:44:42 +02:00
joeydelarago
93e2bef303 Group printers by section (Connected Printers/Other Printers)
Cleanup redundant code.

CURA-9514
2022-08-23 15:44:16 +02:00
joeydelarago
b18080c332 Rename AbstractStacksModel.py -> MachineListModel.py since this model includes both abstract machine stacks and regular machines
Add machineCount for displaying the number of machines of a type.

MachineSelectorButton is in use in other places, swapped it out for a new Component MachineListButton.

CURA-9514
2022-08-23 14:29:05 +02:00
joeydelarago
7ffa770fb4 Searching container registry returns ContainerStacks.
Made typing more generic to work with an ContainerStack to compensate.

Made AbstractMachine getMachines a classmethod so it can be called with ContainerStacks.

CURA-9514
2022-08-23 10:35:00 +02:00
joeydelarago
c016c23d10 Create model from abstract machine list
CURA-9514
2022-08-22 16:26:02 +02:00
Jaime van Kessel
3514c01b25 Remove duplicated code
CURA-9352
2022-06-17 15:21:30 +02:00
j.delarago
9dff733345 Remove todos that are no longer applicable
Remove debug print statement

CURA-9321
2022-06-16 15:32:33 +02:00
j.delarago
1a464051d4 On initial startup, when assigning your first printer the ActiveIntentQualitiesModel.py would not be updated. Causing an error unsupported configuration to show.
Fixed by updating the model when the globalContainer is changed as well.

CURA-8849
2022-06-16 14:27:13 +02:00
j.delarago
8c92ebfccd Add missing import
CURA-8849
2022-06-16 10:41:06 +02:00
j.delarago
f9dda40409 Better typing
CURA-8849
2022-06-15 17:41:21 +02:00
j.delarago
6f8470167f Suggested changes
CURA-8849
2022-06-15 17:40:07 +02:00
Joey de l'Arago
142f1823b3
Apply suggestions from code review
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:31:40 +02:00
Joey de l'Arago
b132b5c08c
Update cura/Machines/Models/IntentSelectionModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:29:59 +02:00
Joey de l'Arago
e47a2d1c99
Update cura/Machines/Models/IntentSelectionModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:29:26 +02:00
Joey de l'Arago
b4152d29d6
Update cura/Machines/Models/ActiveIntentQualitiesModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:29:16 +02:00
Joey de l'Arago
87afb117d0
Update cura/Machines/Models/ActiveIntentQualitiesModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:28:22 +02:00
Joey de l'Arago
760976159c
Update cura/Machines/Models/ActiveIntentQualitiesModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:28:13 +02:00
Joey de l'Arago
caa0c255aa
Update cura/Machines/Models/ActiveIntentQualitiesModel.py
Co-authored-by: Casper Lamboo <c.lamboo@ultimaker.com>
2022-06-15 17:28:06 +02:00
j.delarago
d19e89325f Stop returning quality types from inactive quality groups. This was causing the resolution drop down to show unavailable resolutions.
CURA-8849
2022-06-15 09:06:00 +02:00
Ghostkeeper
074e9a8607
Show profile group name in bold
That highlights it relative to the layer height.

Contributes to issue CURA-8849.
2022-06-14 15:36:29 +02:00
j.delarago
5cfb6f94e3 Update the resolution dropdown model whenever a custom profile is enabled. Otherwise it won't reflect the custom profiles parent resolution.
CURA-8849
2022-06-14 15:03:47 +02:00
j.delarago
a87695cd8d Added new intent selection buttons and resolution drop down to replace the matrix.
We are now selecting intents first and then quality, however the container hierarchy quality -> intents. This is the reason for the new functions inside machine manager.

CURA-8849
2022-06-14 11:41:38 +02:00
Jaime van Kessel
e6551821aa Use intent category if no translation is available
Previously we would only accept intents that had a translation. If we
could not find one, we would use "unknown" as the intent category. However,
we didn't really do this consistently. In some places it would show unkown
and in others we'd show the intent type.

This should make the behavior the same across the board. It will try to get a
translation for the intent category and show that. If it's unable to find that
it will use the category instead. Note that it will use the python title function
to ensure it has nice capitalisation

CURA-9297
2022-06-01 11:07:01 +02:00
Remco Burema
6b04c736e9 Revert "Disable the material sync message again"
This reverts commit 1f6e1942d775d47dd48be4fd83c5346271827a5e.
2022-05-31 12:34:55 +02:00
j.delarago
ba3913395c Add catalog to files that weren't translating
CURA-9141
2022-05-05 16:42:01 +02:00
Jaime van Kessel
efc5438090 Remove unneeded clear 2022-04-08 09:16:22 +02:00
Jaime van Kessel
9e4798c98b Set ownership of MaterialBrandsModel to cpp
This hopefully prevents the crash for MacOS
2022-04-07 20:10:58 +02:00
Jaime van Kessel
262520f193 Remove setting parent from basematerial 2022-04-07 18:05:27 +02:00
Jelle Spijker
3f8907d02a
Merge branch 'master' into CURA-8640_PyQt6
# Conflicts:
#	cura/CuraApplication.py
#	resources/qml/Preferences/Materials/MaterialsSyncDialog.qml
#	resources/qml/Preferences/Materials/MaterialsView.qml
2022-03-24 11:53:44 +01:00
Jaime van Kessel
1632527651 Prevent crash when switching extruder in profiles page 2022-02-21 15:40:08 +01:00
Ghostkeeper
c7d7dd11d1
Merge branch 'master' into PyQt6_upgrade
Conflicts:
	cura/PlatformPhysics.py -> Removed shapely on master, while QTimer import got updated to Qt6.
	plugins/Toolbox -> Entire folder is deleted in master, but it was updated to Qt6 here. This can all be removed.
2022-02-21 11:52:28 +01:00
Ghostkeeper
5c71671585
Make setting names italic if changed in quality-changes profile
This was the behaviour before.

Contributes to issue CURA-8686.
2022-01-26 14:00:29 +01:00
Ghostkeeper
5e5e0febb9
Format calculated functions in QualitySettingsModel itself
That way we don't have to re-format it in the display in the table.

Contributes to issue CURA-8686.
2022-01-26 11:33:42 +01:00
Ghostkeeper
f4d60b38ee
Shorten two texts of 'Sync materials with printers'
In most languages this doesn't properly fit in the space we have for these buttons.
The same text in the window title and header was not changed. There we do have space for it. The button in the material manager was also not adjusted since it's different and already about as short as can be (but needs to refer to printers instead of materials due to the context of already being in the material manager).

Contributes to issue CURA-8753.
2022-01-10 17:28:45 +01:00
Remco Burema
32b52c6166
Qt5->Qt6: Rectify constant locations: UserRole, CppOwnership
part of CURA-8591
2021-12-28 14:54:56 +01:00
Remco Burema
abe7c1bf7f
Search/replace Qt5->Qt6.
part of upgrading Qt to v6.2: CURA-8591
2021-12-28 14:46:02 +01:00
Jaime van Kessel
fe8a3fc61d Prevent crash when setting non default intent category 2021-12-10 09:51:09 +01:00
Jaime van Kessel
8f92f049d1 Emit signal when property changed
The signals weren't being emitted when the property was set.

CURA-8671
2021-12-06 09:43:53 +01:00
Ghostkeeper
0477ba44b2
Encode capabilities as comma-separated list
Previously it was encoded as a stringified Python list of strings, which is much harder to parse.
This would go wrong if any of these capabilities have a comma in them, but I think that would be bad practice for keywords like this anyway.

Contributes to issue CURA-8671.
2021-12-03 13:25:41 +01:00
Ghostkeeper
b76df21b4b
Filter printer list by capabilities
And an example of such usage: In the material sync via cloud we only want to sync with printers that can receive those materials.

We might want to add a message for the user to also make sure the firmware is up to date. Because if the firmware is not up to date now it will show no printers and instruct the user how to connect the printer to the cloud.

Contributes to issue CURA-8671.
2021-12-02 17:55:53 +01:00
Jaime van Kessel
42e066a5a8 Merge branch '4.12' of github.com:Ultimaker/Cura 2021-10-28 13:54:58 +02:00
Jaime van Kessel
59be3e195d Use category as fallback translation for intents instead of "unkown" 2021-10-28 13:48:09 +02:00
Jaime van Kessel
8f1cf4a963 Move openSYncAllWindow to the right class
CURA-8609
2021-10-28 09:43:12 +02:00