part:selection
List of: Scheme Extensions
Subjects: Part Management
Contents: Scheme Support

Action: Returns a list of currently selected entities.

Filename: scm/scmext/part_scm.cxx

Syntax: (part:selection [part=active])

Arg Types: part part

Returns: (entity ... )

Description: This extension return a list of all currently selected entities in a part. If the optional part is not specified, then the active part is assumed. Use the env: set-active-part extension to establish the active part.


Note Use part:clear-selection to deselect all selected entities.

Example: ; part:selection

; Create a new part

(define part1 (part:new))

;; part1

; Create a new block

(define block (solid:block 0 0 0 1 1 1))

;; block

; Create a new sphere

(define sphere (solid:sphere 0 0 0 1))

;; sphere

; Select block and sphere

(entity:select block sphere)

;; ()

; Get current selection

(part:selection)

;; block sphere
PDF/SCM/04SC.PDF
HTM/DATA/SCM/SCM/04SC/0088.HTM