mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-21 21:58:01 -06:00
Convert unit of adaptive layers threshold and change name
This usage is hopefully more intuitive than the previous one.
This commit is contained in:
parent
05b1ce9658
commit
eaedca1917
2 changed files with 11 additions and 3 deletions
|
@ -66,6 +66,13 @@ class VersionUpgrade43to44(VersionUpgrade):
|
|||
# Alternate skin rotation should be translated to top/bottom line directions.
|
||||
if "skin_alternate_rotation" in parser["values"] and parseBool(parser["values"]["skin_alternate_rotation"]):
|
||||
parser["values"]["skin_angles"] = "[45, 135, 0, 90]"
|
||||
# Unit of adaptive layers topography size changed.
|
||||
if "adaptive_layer_height_threshold" in parser["values"]:
|
||||
val = parser["values"]["adaptive_layer_height_threshold"]
|
||||
if val.startswith("="):
|
||||
val = val[1:]
|
||||
val = "=({val}) / 1000".format(val = val) # Convert microns to millimetres. Works even if the profile contained a formula.
|
||||
parser["values"]["adaptive_layer_height_threshold"] = val
|
||||
|
||||
result = io.StringIO()
|
||||
parser.write(result)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue