CAM: respect SHOW_OPERATION_LABELS in post-operation information
This commit is contained in:
@@ -587,7 +587,8 @@ def init_shared_values(values: Values) -> None:
|
||||
#
|
||||
values["SHOW_MACHINE_UNITS"] = True
|
||||
#
|
||||
# If True then the current operation label is output just before the PRE_OPERATION.
|
||||
# If True then the current operation label is output just before the PRE_OPERATION
|
||||
# and just before the POST_OPERATION.
|
||||
#
|
||||
values["SHOW_OPERATION_LABELS"] = True
|
||||
#
|
||||
|
||||
@@ -154,9 +154,12 @@ def output_postop(values: Values, gcode: Gcode, obj) -> None:
|
||||
nl: str = "\n"
|
||||
|
||||
if values["OUTPUT_COMMENTS"]:
|
||||
comment = PostUtilsParse.create_comment(
|
||||
values, f'{values["FINISH_LABEL"]} operation: {obj.Label}'
|
||||
)
|
||||
if values["SHOW_OPERATION_LABELS"]:
|
||||
comment = PostUtilsParse.create_comment(
|
||||
values, f'{values["FINISH_LABEL"]} operation: {obj.Label}'
|
||||
)
|
||||
else:
|
||||
comment = PostUtilsParse.create_comment(values, f'{values["FINISH_LABEL"]} operation')
|
||||
gcode.append(f"{PostUtilsParse.linenumber(values)}{comment}{nl}")
|
||||
for line in values["POST_OPERATION"].splitlines(False):
|
||||
gcode.append(f"{PostUtilsParse.linenumber(values)}{line}{nl}")
|
||||
|
||||
Reference in New Issue
Block a user