Skip to content

netlist_carpentry.vis.dynamic.config

Classes:

  • CytoscapeConfig

    A configuration class for cytoscape objects, handling environment values like

Attributes:

  • DEFAULT_CONFIG

    A default config for ipycytoscape with common settings.

DEFAULT_CONFIG module-attribute

DEFAULT_CONFIG = CytoscapeConfig(min_zoom=1 / 5.0, max_zoom=5.0, autolock=False)

A default config for ipycytoscape with common settings.

CytoscapeConfig

Bases: BaseModel

A configuration class for cytoscape objects, handling environment values like 'min_zoom'/'max_zoom' or 'panning_enabled' that handle how the rendered widget behaves. A CytoscapeConfig can be applied to a CytoscapeWidget via CytoscapeGraph.apply_config(), where unset values (i.e. values that are None) are ignored, and the previous settings are kept.

Attributes:

min_zoom class-attribute instance-attribute

min_zoom: Optional[float] = None

Minimum zoom level (scale factor) of the viewport.

max_zoom class-attribute instance-attribute

max_zoom: Optional[float] = None

Maximum zoom level (scale factor) of the viewport.

zooming_enabled class-attribute instance-attribute

zooming_enabled: Optional[bool] = None

Whether zooming of the viewport is enabled.

user_zooming_enabled class-attribute instance-attribute

user_zooming_enabled: Optional[bool] = None

Whether user-initiated zooming (scroll/pinch) is enabled.

panning_enabled class-attribute instance-attribute

panning_enabled: Optional[bool] = None

Whether panning of the viewport is enabled.

user_panning_enabled class-attribute instance-attribute

user_panning_enabled: Optional[bool] = None

Whether user-initiated panning (drag) is enabled.

box_selection_enabled class-attribute instance-attribute

box_selection_enabled: Optional[bool] = None

Whether box (rectangle) selection of elements is enabled.

selection_type class-attribute instance-attribute

selection_type: Optional[Literal['single', 'additive']] = None

Selection mode: 'single' replaces the selection, 'additive' adds to it.

touch_tap_threshold class-attribute instance-attribute

touch_tap_threshold: Optional[int] = None

Number of taps on a touch device required to trigger a selection.

desktop_tap_threshold class-attribute instance-attribute

desktop_tap_threshold: Optional[int] = None

Number of clicks on a desktop required to trigger a selection.

autolock class-attribute instance-attribute

autolock: Optional[bool] = None

Whether the graph layout is automatically locked after rendering.

auto_ungrabify class-attribute instance-attribute

auto_ungrabify: Optional[bool] = None

Whether nodes are automatically made non-grabbable (non-movable by user).

auto_unselectify class-attribute instance-attribute

auto_unselectify: Optional[bool] = None

Whether nodes are automatically made non-selectable by the user.

headless class-attribute instance-attribute

headless: Optional[bool] = None

Whether to run in headless mode (no visual rendering).

style_enabled class-attribute instance-attribute

style_enabled: Optional[bool] = None

Whether CSS-like styling of elements is enabled.

hide_edges_on_viewport class-attribute instance-attribute

hide_edges_on_viewport: Optional[bool] = None

Whether to hide edges when zoomed out beyond a threshold.

texture_on_viewport class-attribute instance-attribute

texture_on_viewport: Optional[bool] = None

Whether to use texture-based rendering for the viewport.

motion_blur class-attribute instance-attribute

motion_blur: Optional[bool] = None

Whether to apply a motion blur effect during panning/zooming.

motion_blur_opacity class-attribute instance-attribute

motion_blur_opacity: Optional[float] = None

Opacity of the motion blur trail (0.0 to 1.0).

wheel_sensitivity class-attribute instance-attribute

wheel_sensitivity: Optional[float] = None

Sensitivity multiplier for mouse-wheel zooming.

zoom class-attribute instance-attribute

zoom: Optional[float] = None

Initial zoom level (scale factor) of the viewport.