Selection API/de

From FreeCAD Documentation
Jump to navigation Jump to search
This page is a translated version of the page Selection API and the translation is 0% complete.
Outdated translations are marked like this.
Other languages:
Deutsch • ‎English • ‎español • ‎français • ‎italiano
(November 2018) Diese Information kann unvollständig und veraltet sein. Für die letzte API siehe die (engl.) autogenerierte API-Dokumentation.

The selection submodule is part of the FreeCADGui module. Example:

import FreeCADGui
sel = FreeCADGui.Selection.getSelection()
Method.png addSelection(FreeCAD.Object)

Description: Adds an object to the selection

Returns:

Method.png clearSelection([string])

Description: Clears the selection of the given document name. If no document is given the complete selection is cleared.

Returns:

Method.png getSelection([string])

Description: Returns a list of selected document objects for a given document name. If no document is given the complete selection is returned.

Returns: a list of document objects in the order they were selected.

Method.png getSelectionEx([string])

Description: Returns a list of SelectionObject for a given document name. If no document is given the complete selection is returned. Used for selecting subobjects (ex some Edges of a Face).

Returns: a list of SelectionObjects in the order they were selected

Method.png isSelected(FreeCAD.Object)

Description: Checks if a given object is selected

Returns:

Method.png removeSelection(FreeCAD.Object)

Description: Removes an object from the selection

Returns: