PolygonSelectors#

PolygonSelectors#

Constructor#

PolygonSelectors(parent, limits[, ...])

Collection of PolygonSelector instances on a shared parent graphic.

Properties#

PolygonSelectors.alpha

The opacity of the graphic

PolygonSelectors.alpha_mode

How the alpha is handled by the renderer

PolygonSelectors.axes

PolygonSelectors.block_events

Used to block events for a graphic and prevent recursion.

PolygonSelectors.block_handlers

Used to block event handlers for a graphic and prevent recursion.

PolygonSelectors.deleted

used to emit an event after the graphic is deleted

PolygonSelectors.event_handlers

Registered event handlers.

PolygonSelectors.imgui_right_click

The imgui popup that is opened by a right-click on this graphic.

PolygonSelectors.legend_item

The legend item of this graphic, created with create_legend_item().

PolygonSelectors.name

Graphic name

PolygonSelectors.offset

[x, y, z]

PolygonSelectors.rotation

Orientation of the graphic as a quaternion

PolygonSelectors.scale

(x, y, z) scaling factor

PolygonSelectors.selection

Child selector selections in append order.

PolygonSelectors.supported_events

events supported by this graphic

PolygonSelectors.tooltip_format

set a custom tooltip format function which takes a pick_info dict and returns a str to be displayed in the tooltip

PolygonSelectors.visible

Whether the graphic is visible

PolygonSelectors.world_object

Associated pygfx WorldObject.

Methods#

PolygonSelectors.add_axes()

Add axes onto this Graphic

PolygonSelectors.add_event_handler(handler)

Register a callback fired on any selection change.

PolygonSelectors.append(selection)

Create a new child selector and return it.

PolygonSelectors.append_imgui_right_click([gui])

Append imgui elements to the right-click popup of this graphic.

PolygonSelectors.clear()

Remove all child selectors.

PolygonSelectors.clear_event_handlers()

clear all event handlers added to this graphic

PolygonSelectors.format_pick_info(ev)

Takes a pygfx.PointerEvent and returns formatted pick info.

PolygonSelectors.map_model_to_world(position)

map position from model (data) space to world space, basically applies the world affine transform

PolygonSelectors.map_world_to_model(position)

map position from world space to model (data) space, basically applies the inverse world affine transform

PolygonSelectors.remove(item)

Remove a child selector by index or reference.

PolygonSelectors.remove_event_handler(handler)

remove a registered event handler

PolygonSelectors.remove_imgui_right_click()

Remove and return the right-click popup of this graphic

PolygonSelectors.rotate(alpha[, axis])

Rotate the Graphic with respect to the world.

PolygonSelectors.set_imgui_right_click([...])

Set the imgui popup that is opened by a right-click on this graphic, replaces the popup of the subplot or Figure for this graphic.