Arch Remove: Difference between revisions

From FreeCAD Documentation
(API and scripting links)
(Two ways of using the tool)
Line 25: Line 25:


<!--T:7-->
<!--T:7-->
# Select a subcomponent inside an Arch object, '''or''':
# Select a subcomponent inside an Arch object.
# Press the {{Button|[[Image:Arch Remove.svg|16px]] [[Arch Remove|Remove]]}} button.
# Select object(s) to be subtracted, then the Arch component from which they must be subtracted (the arch component must be the last thing you selected).

Or
# Select objects to be subtracted, the last object selected must the Arch object from which the other objects will be subtracted.
# Press the {{Button|[[Image:Arch Remove.svg|16px]] [[Arch Remove|Remove]]}} button.
# Press the {{Button|[[Image:Arch Remove.svg|16px]] [[Arch Remove|Remove]]}} button.



Revision as of 18:26, 1 December 2018

Arch Remove

Menu location
Arch → Remove
Workbenches
Arch
Default shortcut
None
Introduced in version
-
See also
Arch Add

Description

The Remove tools allows you to do 2 kinds of operations:

  • Remove a subcomponent from an Arch object, for example remove a box that has been added to a wall, like in the Arch Add example
  • Subtract a shape-based object from an Arch component such as a wall or structure

In the above image, a box is being subtracted from a wall.

How to use

  1. Select a subcomponent inside an Arch object.
  2. Press the Remove button.

Or

  1. Select objects to be subtracted, the last object selected must the Arch object from which the other objects will be subtracted.
  2. Press the Remove button.

Scripting

See also: Arch API and FreeCAD Scripting Basics.

The Remove tool can be used in macros and from the Python console by using the following function:

removeComponents(objectsList,[hostObject])
  • removes the given component or the components from the given list from their parents. If a host object is specified, this function will try adding the components as holes to the host object instead.

Example:

import FreeCAD, Arch, Draft, Part
line = Draft.makeWire([FreeCAD.Vector(0,0,0),FreeCAD.Vector(2,2,0)])
wall = Arch.makeWall(line)
box = Part.makeBox(1,1,1)
Arch.addComponents(box,wall)
Arch.removeComponents(box)