Basically the entire implementation of BuildVolume.py is in here by now... It's a bit more conservative than BuildVolume but I couldn't find a case where this fails (again).
CURA-4036
initial_layer_line_width_factor is a percentage ranging from 0 to 100,
so when calculating the prime tower position, we need to divide it by
100.
If a PrinterOutputDevice is able to connect quickly to a machine, then
by the time the MachineManager is created and connects to the signal,
it will be too late, and it might miss that there is already connected
devices.
# Conflicts:
# plugins/USBPrinting/USBPrinterOutputDeviceManager.py
global_container_stack.definitionChanges always returns a container, global_container_stack.findContainer({"type": "definition_changes"}) does not (because an empty container does not have the type "definition_changes".
It doesn't make sense to always have a nozzle offset for all nozzles. What's more, the setting only exists in fdmextruder.def.json so it can't be set in something that inherits from fdmprinter.def.json.
When this is imported during the __init__, it'll long have been imported elsewhere and won't need to import it again but still guarantees that it is actually imported if no other module does it first.
Contributes to issue CURA-4024.
This actually looks really nice. It just moves right along that border there. Eventually we could also auto-position the X position but for now this is fine.
When the setting is equal to the default the setting_version won't get written to the preferences file. In that case the version upgrade system assumes that the setting_version was 0 or 1 and upgrades it.
This makes sure that the setting is never equal to the default so that it always gets written.
Found while working on CURA-4024.
Recently we changed the empty containers such that there is only one empty container instance and it doesn't have the proper type any more. Instead we have properties on the stack that allows us to find the container with the proper type. It's faster and easier to use.
We've had a few bugs about this so I decided to update all of them to remove those for the future, except the ones in plugins/MachineSettingsAction/MachineSettingsAction.py because we have a pending pull request that fixes those. Fixing them would give merge conflicts for fieldOfView.
It doesn't really belong to CURA-4024 but I'm sticking it under that nomer anyway to get it reviewed.