CAM OpActiveToggle
CAM OpActiveToggle
- Menu location
-
- Workbenches
- Default shortcut
-
P then X
- Introduced in version
-
-
- See also
-
None
Description
The Toggle Operation command (tooltip: "Toggles the active state of the operation") toggles the Active property of a selected CAM Operation.
If this property is set to false, the Operation is treated as inactive. Its toolpath is replaced by the single comment (inactive operation), it is not drawn in the 3D View, and it contributes no motion to the output of Post Process. Inspect Toolpath still opens and shows that single comment line.
introduced in 26.3: the command also accepts the Job or its Operations group as the single selected object. If all Operations are in the same state they are all toggled; if they are mixed, all are set to active. Several Operations can be selected and toggled together.
When a dressup is selected, the Active property of its base Operation is toggled.
Usage
-
Select one or more Operations in the Operations group belonging to a Job, or the Job itself (introduced in 26.3). A deactivated Operation can be recognized by its grayed out label and icon.
-
There are several ways to invoke the command:
-
Press the
Toggle Operation button.
-
Select the option from the menu.
-
Use the Tree View context menu of Operations or of the Job.
-
Use the keyboard shortcut: P then X.
-
-
The result depends on the selected Operation:
-
If you have selected an active Operation the command deactivates it:
-
The Operation icon is replaced with the inactive-operation icon.
-
The Operation icon and label are grayed out.
-
The toolpaths generated from the Operation disappear from the 3D View.
-
The Operation’s toolpath is reduced to the comment
(inactive operation), so Post Process emits no motion for it. -
If the Operation has dressups, they are also shown in an inactive state in the Tree View.
-
-
If you have selected a deactivated Operation the command activates it:
-
The Operation icon is replaced with that belonging to the Operation.
-
The Operation icon and label are no longer grayed out.
-
The toolpaths generated from the Operation are recomputed and displayed in the 3D View.
-
The Operation’s G-code is provided again to Inspect Toolpath and Post Process.
-
-
Notes
-
Arrays, Simple Copies and Path From Shape TC objects also have an Active property and show the toggle icon when inactive. Comment and Stop objects have no Active property and cannot be toggled.
-
The command can be used while a task panel is open.
Scripting
See also: FreeCAD Scripting Basics.
Example:
op = FreeCAD.ActiveDocument.Profile
op.Active = not op.Active
FreeCAD.ActiveDocument.recompute()