172 Commits

Author SHA1 Message Date
Jack Ha
04a135e6a3 CURA-5157 renamed extruder to position in addExtruderStackForSingleExtrusionMachine, fixes loading some upgrades from 3.0 2018-03-27 13:04:05 +02:00
Lipu Fei
08f43f6b2e Fix profile ordering in profile importing
CURA-5054
2018-03-15 15:27:47 +01:00
Lipu Fei
22573a685d Fix quality definition comparison in quality importing
CURA-4946
2018-03-14 14:31:30 +01:00
Lipu Fei
0655ef0bc5 Fix quality profile import
CURA-4946
2018-03-14 14:22:46 +01:00
Lipu Fei
191faaba19 Fix machine definition in quality importing
CURA-4946
2018-03-14 13:49:16 +01:00
Ian Paschal
05c59ddaa7 CURA-4946 Handle gcode with wrong quality definition
Some gcode has its quality definition set to, say, UM2 extended, which is _actually_ just UM2 gcode. Thus, we check if the definition in the profile matches the current machine or what it in theory should be, either one being valid. See comments in code for details.
2018-03-14 13:29:48 +01:00
Ian Paschal
6d2d9c8fe2 CURA-4946 Fixed typo 2018-03-13 12:39:10 +01:00
Lipu Fei
1f08accbec Fix profile importing for version upgrade
CURA-4946
2018-03-12 16:15:16 +01:00
Lipu Fei
a81981a27a Better info on no profiles to import for gcode
CIRA-4946

If a gcode is sliced with default profiles, there won't be any custom
profiles to import from that gcode. In that case, we show a info message
telling the user about this instead of showing an error message.
2018-03-09 16:40:57 +01:00
Lipu Fei
07824c21e1 Move getMachineDefinitionIDForQualitySearch() into QualityManager.py 2018-02-28 11:48:20 +01:00
Lipu Fei
9a354efd19 Merge remote-tracking branch 'origin/master' into refactoring_machine_manager 2018-02-21 14:05:19 +01:00
Diego Prado Gesto
6af5a5d4bc CURA-4946 When storing the gcode profile, the definition must be the
quality definition if the printer has_machine_quality. Otherwise the
fdmprinter definition must be used as a fallback. If there is no
quality_definition then the printer definition is use.
2018-02-20 11:11:21 +01:00
Diego Prado Gesto
6a4f519238 Revert "CURA-4946 Add the quality_definition metadata entry to the gcode so when"
This reverts commit 744313af273ed34a5796d3970c3915f68abaedc7.
2018-02-20 09:30:05 +01:00
Lipu Fei
62c31c2f6c WIP: Remove old QualityManager 2018-02-19 22:11:47 +01:00
Lipu Fei
27f7d16a57 WIP: Make import/export profile work 2018-02-19 21:47:12 +01:00
Lipu Fei
0c3ac090c9 WIP: Cleanup 2018-02-19 21:11:01 +01:00
Jack Ha
aed0c124e9 CURA-4606 improved addExtruderStackForSingleExtrusionMachine by using containers directly 2018-02-16 14:23:11 +01:00
Lipu Fei
12164a0c88 WIP: Remove set..ById()s in CuraContainerStack 2018-02-16 14:23:11 +01:00
Diego Prado Gesto
744313af27 CURA-4946 Add the quality_definition metadata entry to the gcode so when
parsing, the quality definition is taken into account instead of the
definition.
The message when importing a profile to a different machine,
now shows the expected machine and the current machine definition id.!!
2018-02-16 14:01:46 +01:00
Diego Prado Gesto
735dac6a4a Modify debug message to show the correct/useful information 2018-02-16 09:15:06 +01:00
Jack Ha
98f925d50c CURA-4924 now creating the extruder container with metadata extruder 2018-02-07 10:00:02 +01:00
Jack Ha
cb6b465ce7 CURA-4924 fix loading profiles with % in it 2018-02-07 09:55:22 +01:00
Diego Prado Gesto
4cf07f5fe6 CURA-4868 Fix typo 2018-01-30 17:23:55 +01:00
Lipu Fei
759e596eb6 Fix add extruder function
CURA-4868
2018-01-30 12:19:16 +01:00
Lipu Fei
f1363fab73 Move newline format
CURA-4863
2018-01-29 16:33:52 +01:00
Lipu Fei
924f3972fd Create quality_changes for extruder stack if missing in profile importing
CURA-4868
2018-01-29 14:50:08 +01:00
Lipu Fei
34e6816f83 Fix container ID modification in profile importing
CURA-4868
2018-01-29 14:50:07 +01:00
Lipu Fei
7dfc1a4aa7 Add encoding='utf-8' for text file reading
CURA-4875

When encoding is not provided, the behaviour is system dependent and it
can break on OS X.
2018-01-29 12:29:20 +01:00
Diego Prado Gesto
e38cf957bb CURA-4839 Avoid creating unique names for the extruder instance
containers if the strategy is upgrade existing
2018-01-24 16:04:11 +01:00
Lipu Fei
1c605a5108 Fix different strategies for machine and quality in project loading
CURA-4839
2018-01-23 10:58:43 +01:00
Lipu Fei
b92ebadfd0 Fix quality_changes for single-extrusion machines
CURA-4839

- Add newly created quality_changes container to ContainerRegistry
- If an extruder is created by CuraContainerRegistry, in project
  loading, do not try to override extruder's quality changes.
2018-01-19 15:05:05 +01:00
Lipu Fei
e7a19bcce5 Fix has_machine_quality value parsing
CURA-4837
2018-01-19 14:34:25 +01:00
Lipu Fei
79e79dd84c Only import profiles that match with the active machine
CURA-4837
2018-01-19 14:08:52 +01:00
ChrisTerBeke
ce709bf24a Remove debug print - CURA-4829 2018-01-19 10:48:45 +01:00
Diego Prado Gesto
a6acf4a4af CURA-4829 Do not save the quality changes profile in the GCode if the
containers are empty.
Change the message when trying to import a GCode as a profile, but not profile was stored.
2018-01-19 10:34:04 +01:00
Diego Prado Gesto
26371c9c3a CURA-4815 When creating the unique name for a machine, don't look at the
definition instance container for the id, just look at the container
stack ids.
2018-01-17 10:57:11 +01:00
Diego Prado Gesto
78b42afbcb CURA-4776 Add unique id to the profiles so user can import the same
profile several times with different names.It also fixes the issue for
importing profiles from GCode.
2018-01-10 16:40:58 +01:00
Aleksei S
92e48795c9 Merge branch 'master' of github.com:Ultimaker/cura 2018-01-10 11:20:31 +01:00
Aleksei S
95361bbeb2 Refactoring: profile from Gcode
CURA-4776
2018-01-10 11:19:19 +01:00
Lipu Fei
91cccedf75 Fix upgrading quality changes for single extrusion machines 2018-01-10 08:54:46 +01:00
Aleksei S
3852b0d1c3 Merge branch 'master' of github.com:Ultimaker/cura 2018-01-09 13:39:32 +01:00
Aleksei S
d633a4c112 Fix: cura does not profile form G-code
CURA-4776
2018-01-09 13:38:41 +01:00
Lipu Fei
78b9a14007 Fix all possible quality changes containers for single extrusion
In the current fix, the quality changes that are applicable to the
machine may not have been fixed yet because they are not active at that
moment. This commit makes sure that for a single extrusion machine which
has just been updated to have an ExtruderStack, all the quality changes
containers that are applicable to this machine will be updated as well.
2018-01-09 13:30:01 +01:00
Lipu Fei
c91eb30de9 Skip loaded instance containers
When trying to apply the fix for single extrusion machines by creating a
new ExtruderStack, skip the quality changes container that has already
been loaded.
2018-01-09 13:30:01 +01:00
Lipu Fei
8e5167be76 Use the same machine def for extruder quality changes containers 2018-01-09 13:30:00 +01:00
Lipu Fei
59d7cc663a Fix creating ExtruderStack for single-extrusion machine at runtime
Move per-extruder settings from the machine's quality changes container
to the extruder's quality changes container.
2018-01-09 13:30:00 +01:00
Lipu Fei
70d5d4415f
Merge branch 'master' into CURA-4708_fix_definition_changes_extruder_stacks 2018-01-02 10:41:44 +01:00
Ghostkeeper
2e197f0f34
Move all per-extruder settings
Also move things that we didn't think of previously, such as extruder offsets. You can't enter them as a user in the interface if it was single-extrusion, but you could've edited the files.

Contributes to issue CURA-4708.
2018-01-02 08:36:46 +01:00
Ghostkeeper
a87465186e
Fix off-by-one bug when importing profiles with extruder stacks
Since machine_extruders contains only the extruder stacks (not the global stack) but profile_index counts through all stacks including the global stack, we need to increase the length of machine_extruders by 1 when comparing.
I also swapped the comparison around since I think it's more logical this way around.

Contributes to issue CURA-4738.
2018-01-02 08:19:31 +01:00
Lipu Fei
0c28c61e05 Create new SettingInstances when moving user changes settings
CURA-4708
2017-12-22 14:09:13 +01:00