ui

class trame_slicer.app.ui.BrushParametersState(brush_diameter_slider: trame_slicer.app.ui.slider.SliderState = <factory>, brush_diameter_mode: trame_slicer.segmentation.paint_effect_parameters.BrushDiameterMode = <BrushDiameterMode.ScreenRelative: 2>, use_sphere_brush: bool = True)

Bases: object

brush_diameter_mode: BrushDiameterMode = 2
use_sphere_brush: bool = True
brush_diameter_slider: SliderState
class trame_slicer.app.ui.BrushParametersUI(typed_state: TypedState[BrushParametersState], **kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.ControlButton(*, name: str, icon: str | tuple, click: Callable | str | None = None, size: int = 35, **kwargs)

Bases: VBtn

class trame_slicer.app.ui.DownloadSceneButton(**kwargs)

Bases: FlexContainer

set_download_callback(download_callback)
class trame_slicer.app.ui.DownloadSceneState(loading_busy: bool = False)

Bases: object

loading_busy: bool = False
class trame_slicer.app.ui.DrawEffectState(brush_interaction_mode: trame_slicer.segmentation.scissors_effect_parameters.BrushInteractionMode = <BrushInteractionMode.CONTINUOUS: 1>)

Bases: object

brush_interaction_mode: BrushInteractionMode = 1
class trame_slicer.app.ui.DrawEffectUI(**kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.DynamicSelect(state: TypedState[DynamicSelectState], **kwargs)

Bases: VSelect

class trame_slicer.app.ui.DynamicSelectState(current_id: int = -1, items: list[dict[str, int | str]] = <factory>)

Bases: object

current_id: int = -1
items: list[dict[str, int | str]]
class trame_slicer.app.ui.FlexContainer(row: bool = False, fill_height: bool = False, align: str | None = None, justify: str | None = None, **kwargs)

Bases: Div

class trame_slicer.app.ui.IslandsEffectUI(**kwargs)

Bases: FlexContainer

apply_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.IslandsState(mode: trame_slicer.segmentation.segmentation_effect_islands.SegmentationIslandsMode = <SegmentationIslandsMode.KEEP_LARGEST_ISLAND: 1>, minimum_size: int = 1000)

Bases: object

minimum_size: int = 1000
mode: SegmentationIslandsMode = 1
class trame_slicer.app.ui.LayoutButton(**kwargs)

Bases: VMenu

class trame_slicer.app.ui.LayoutButtonState(layout_ids: list[str] = <factory>, current_layout_id: str = 'Axial Primary')

Bases: object

current_layout_id: str = 'Axial Primary'
layout_ids: list[str]
class trame_slicer.app.ui.LoadVolumeButton(name: str, load_directory: bool, icon: str, typed_state: TypedState[LoadVolumeItemsState], **kwargs)

Bases: FlexContainer

on_load_volume

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.LoadVolumeItemsState(loading_busy: bool = False, button_tooltip: bool = False)

Bases: object

button_tooltip: bool = False
loading_busy: bool = False
class trame_slicer.app.ui.LoadVolumeState(file_button: trame_slicer.app.ui.load_volume_ui.LoadVolumeItemsState = <factory>, dir_button: trame_slicer.app.ui.load_volume_ui.LoadVolumeItemsState = <factory>)

Bases: object

file_button: LoadVolumeItemsState
dir_button: LoadVolumeItemsState
class trame_slicer.app.ui.LoadVolumeUI(**kwargs)

Bases: FlexContainer

on_load_volume

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.LogicalOperatorsEffectUI(**kwargs)

Bases: FlexContainer

apply_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.LogicalOperatorsSegmentationMode(*values)

Bases: Enum

COPY = 1
ADD = 2
SUBTRACT = 3
INTERSECT = 4
INVERT = 5
CLEAR = 6
FILL = 7
class trame_slicer.app.ui.LogicalOperatorsState(logical_operator: trame_slicer.app.ui.segmentation.logical_operators_effect_ui.LogicalOperatorsSegmentationMode = <LogicalOperatorsSegmentationMode.COPY: 1>, reference_segment_id: str | None = None, available_segments: list[trame_slicer.app.ui.segmentation.segment_state.SegmentState] = <factory>)

Bases: object

logical_operator: LogicalOperatorsSegmentationMode = 1
reference_segment_id: str | None = None
available_segments: list[SegmentState]
class trame_slicer.app.ui.MarkupsButton

Bases: VMenu

clear_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

place_node_type

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.MedicalViewerUI(server: Server, layout_manager: LayoutManager)

Bases: object

property data
property name
class trame_slicer.app.ui.MprInteractionButton(**kwargs)

Bases: FlexContainer

toggle_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.MprInteractionButtonState(is_interactive: bool = False)

Bases: object

is_interactive: bool = False
class trame_slicer.app.ui.PaintEffectState(brush_diameter_slider: trame_slicer.app.ui.slider.SliderState = <factory>, brush_diameter_mode: trame_slicer.segmentation.paint_effect_parameters.BrushDiameterMode = <BrushDiameterMode.ScreenRelative: 2>, use_sphere_brush: bool = True)

Bases: BrushParametersState

class trame_slicer.app.ui.PaintEffectUI(**kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.Preset(title: str, props: dict[str, str])

Bases: object

title: str
props: dict[str, str]
class trame_slicer.app.ui.RangeSlider(typed_state: TypedState[RangeSliderState], **kwargs)

Bases: VRangeSlider

class trame_slicer.app.ui.RangeSliderState(min_value: float = 0, max_value: float = 1, value: list[float] = <factory>, step: float = 1e-06, is_reversed: bool = False, is_disabled: bool = False)

Bases: object

is_disabled: bool = False
is_reversed: bool = False
max_value: float = 1
min_value: float = 0
step: float = 1e-06
value: list[float]
class trame_slicer.app.ui.ScissorsEffectState(brush_interaction_mode: trame_slicer.segmentation.scissors_effect_parameters.BrushInteractionMode = <BrushInteractionMode.CONTINUOUS: 1>, fill_mode: trame_slicer.segmentation.scissors_effect_parameters.ScissorsEffectFillMode = <ScissorsEffectFillMode.ERASE_INSIDE: 1>, range_mode: trame_slicer.segmentation.scissors_effect_parameters.ScissorsEffectRangeMode = <ScissorsEffectRangeMode.UNLIMITED: 1>, symmetric_distance: float = 0)

Bases: object

brush_interaction_mode: BrushInteractionMode = 1
fill_mode: ScissorsEffectFillMode = 1
range_mode: ScissorsEffectRangeMode = 1
symmetric_distance: float = 0
class trame_slicer.app.ui.ScissorsEffectUI(**kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.SegmentDisplayState(border_thickness: trame_slicer.app.ui.slider.SliderState = <factory>, opacity_mode: trame_slicer.segmentation.segmentation_display.SegmentationOpacityEnum = <SegmentationOpacityEnum.BOTH: 3>, opacity_2d: trame_slicer.app.ui.slider.SliderState = <factory>, opacity_3d: trame_slicer.app.ui.slider.SliderState = <factory>, show_3d: bool = False, is_extended: bool = False)

Bases: object

is_extended: bool = False
opacity_mode: SegmentationOpacityEnum = 3
show_3d: bool = False
border_thickness: SliderState
opacity_2d: SliderState
opacity_3d: SliderState
class trame_slicer.app.ui.SegmentDisplayUI(typed_state: TypedState[SegmentDisplayState], **kwargs)

Bases: VCard

class trame_slicer.app.ui.SegmentEditAreaState(mask_select: trame_slicer.app.ui.dynamic_select.DynamicSelectState = <factory>, overwrite_mode: trame_slicer.segmentation.segmentation_overwrite_mode.SegmentationOverwriteMode = <SegmentationOverwriteMode.OVERWRITE_ALL: 0>, is_extended: bool = False)

Bases: object

is_extended: bool = False
overwrite_mode: SegmentationOverwriteMode = 0
mask_select: DynamicSelectState
class trame_slicer.app.ui.SegmentEditAreaUI(segment_edit_area_typed_state: TypedState[SegmentEditAreaState], **kwargs)

Bases: VCard

class trame_slicer.app.ui.SegmentEditState(segment_state: trame_slicer.app.ui.segmentation.segment_state.SegmentState = <factory>, is_color_dialog_visible: bool = False)

Bases: object

is_color_dialog_visible: bool = False
segment_state: SegmentState
class trame_slicer.app.ui.SegmentEditUI(**kwargs)

Bases: AbstractElement

cancel_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

color_changed

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

name_changed

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.SegmentEditorState(segment_list: trame_slicer.app.ui.segmentation.segment_list.SegmentListState = <factory>, segment_display: trame_slicer.app.ui.segmentation.segment_display_ui.SegmentDisplayState = <factory>, segment_edit_area: trame_slicer.app.ui.segmentation.segment_edit_area_ui.SegmentEditAreaState = <factory>, can_undo: bool = False, can_redo: bool = False, active_effect_name: str = '')

Bases: object

active_effect_name: str = ''
can_redo: bool = False
can_undo: bool = False
segment_list: SegmentListState
segment_display: SegmentDisplayState
segment_edit_area: SegmentEditAreaState
class trame_slicer.app.ui.SegmentEditorToolbarUI(editor_ui: SegmentEditorUI, **kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.SegmentEditorUI(**kwargs)

Bases: FlexContainer

add_segment_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

build_effect_buttons(all: bool = True, **kwargs)
build_undo_redo_buttons()
delete_segment_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

edit_segment_color_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

effect_button_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

get_effect_ui(effect_type: type[SegmentationEffect])
is_active_effect(effect_type: type[SegmentationEffect])
redo_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

select_segment_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

sub_state(sub_name)
toggle_segment_visibility_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

undo_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.SegmentEditorUndoRedoUI(editor_ui: SegmentEditorUI, **kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.SegmentList(typed_state: TypedState[SegmentListState], edit_ui: SegmentEditUI, **kwargs)

Bases: VList

List view for the current active segments.

build_menu_items()
delete_segment_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

edit_segment_color_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

select_segment_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

toggle_segment_visibility_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.SegmentListState(segments: list[trame_slicer.app.ui.segmentation.segment_state.SegmentState] = <factory>, active_segment_id: str = '')

Bases: object

active_segment_id: str = ''
segments: list[SegmentState]
class trame_slicer.app.ui.SegmentState(name: str = '', color: str = '', segment_id: str = '', is_visible: bool = True)

Bases: object

color: str = ''
is_visible: bool = True
name: str = ''
segment_id: str = ''
class trame_slicer.app.ui.SegmentationAppUI(server: Server, layout_manager: LayoutManager)

Bases: object

property data
property name
class trame_slicer.app.ui.SlabButton

Bases: VMenu

class trame_slicer.app.ui.SlabState(current_slab_type: trame_slicer.app.ui.slab_button.SlabType = <SlabType.MAX: 1>, slab_thickness_value: float = 0.0, slab_enabled: bool = False)

Bases: object

current_slab_type: SlabType = 1
slab_enabled: bool = False
slab_thickness_value: float = 0.0
class trame_slicer.app.ui.SlabType(*values)

Bases: Enum

MIN = 0
MAX = 1
AVERAGE = 2
SUM = 3
class trame_slicer.app.ui.Slider(typed_state: TypedState[SliderState], **kwargs)

Bases: VSlider

class trame_slicer.app.ui.SliderState(min_value: float = 0, max_value: float = 1, value: float = 0.5, step: float = 1e-06, is_reversed: bool = False, is_disabled: bool = False)

Bases: object

is_disabled: bool = False
is_reversed: bool = False
max_value: float = 1
min_value: float = 0
step: float = 1e-06
value: float = 0.5
class trame_slicer.app.ui.SmoothingEffectMode(*values)

Bases: Enum

MEDIAN = 1
OPENING = 2
CLOSING = 3
GAUSSIAN = 4
JOINT = 5
class trame_slicer.app.ui.SmoothingEffectUI(**kwargs)

Bases: FlexContainer

apply_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.SmoothingState(mode: trame_slicer.app.ui.segmentation.smoothing_effect_ui.SmoothingEffectMode = <SmoothingEffectMode.MEDIAN: 1>, apply_to_all_visibile_segments: bool = False, kernel_size: float = 3.0, standard_deviation: float = 3.0, smoothing_factor: float = 0.5, brush: trame_slicer.app.ui.segmentation.brush_parameters_ui.BrushParametersState = <factory>)

Bases: object

apply_to_all_visibile_segments: bool = False
kernel_size: float = 3.0
mode: SmoothingEffectMode = 1
smoothing_factor: float = 0.5
standard_deviation: float = 3.0
brush: BrushParametersState
class trame_slicer.app.ui.Text(text: str, title: bool = False, subtitle: bool = False, **kwargs)

Bases: Div

class trame_slicer.app.ui.TextField(**kwargs)

Bases: VTextField

class trame_slicer.app.ui.ThresholdEffectUI(**kwargs)

Bases: FlexContainer

apply_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

auto_threshold_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

use_as_mask_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.ThresholdState(threshold_slider: trame_slicer.app.ui.slider.RangeSliderState = <factory>)

Bases: object

threshold_slider: RangeSliderState
class trame_slicer.app.ui.ViewerLayout(server: Server, template_name='main', title: str = 'Trame Slicer', theme: str = 'dark', is_drawer_visible: bool = False)

Bases: VAppLayout

class trame_slicer.app.ui.ViewerLayoutState(is_drawer_visible: bool = False, active_tool: str | None = None, is_volume_loaded: bool = False)

Bases: object

active_tool: str | None = None
is_drawer_visible: bool = False
is_volume_loaded: bool = False
class trame_slicer.app.ui.VolumeIntensityRangeMaskState(threshold_slider: trame_slicer.app.ui.slider.RangeSliderState = <factory>, is_visible: bool = False, is_enabled: bool = False)

Bases: object

is_enabled: bool = False
is_visible: bool = False
threshold_slider: RangeSliderState
class trame_slicer.app.ui.VolumeIntensityRangeMaskUI(**kwargs)

Bases: FlexContainer

class trame_slicer.app.ui.VolumePropertyState(window_level_slider: trame_slicer.app.ui.slider.RangeSliderState = <factory>, vr_shift_slider: trame_slicer.app.ui.slider.SliderState = <factory>, presets_3d: list[trame_slicer.app.ui.volume_property_ui.Preset] = <factory>, preset_3d_name: str = 'CT-Coronary-Arteries-3', presets_2d: list[trame_slicer.app.ui.volume_property_ui.Preset] = <factory>, preset_2d_name: str | None = None, volume_crop_active: bool = False)

Bases: object

preset_2d_name: str | None = None
preset_3d_name: str = 'CT-Coronary-Arteries-3'
volume_crop_active: bool = False
window_level_slider: RangeSliderState
vr_shift_slider: SliderState
presets_3d: list[Preset]
presets_2d: list[Preset]
class trame_slicer.app.ui.VolumePropertyUI(**kwargs)

Bases: VCard

auto_window_level_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

vr_crop_button_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

trame_slicer.app.ui.create_slice_buttons(_server, _view_id, view: SliceView)
trame_slicer.app.ui.create_vertical_slice_view_gutter_ui(server: Server, view_id: str, view: AbstractViewChild) None
trame_slicer.app.ui.create_vertical_view_gutter_ui(server: Server, view_id: str, view: AbstractViewChild, fill_gutter_f: Callable[[Server, str, AbstractViewChild], None] | None = None) None
trame_slicer.app.ui.enum_to_radio_buttons(typed_state: TypedState, enum_type: type[Enum])
trame_slicer.app.ui.enum_to_title(enum: Enum) str

trame_slicer.app.ui.control_button module

class trame_slicer.app.ui.control_button.ControlButton(*, name: str, icon: str | tuple, click: Callable | str | None = None, size: int = 35, **kwargs)

Bases: VBtn

trame_slicer.app.ui.download_scene_button module

class trame_slicer.app.ui.download_scene_button.DownloadSceneState(loading_busy: bool = False)

Bases: object

loading_busy: bool = False
class trame_slicer.app.ui.download_scene_button.DownloadSceneButton(**kwargs)

Bases: FlexContainer

set_download_callback(download_callback)

trame_slicer.app.ui.dynamic_select module

class trame_slicer.app.ui.dynamic_select.DynamicSelectState(current_id: int = -1, items: list[dict[str, int | str]] = <factory>)

Bases: object

current_id: int = -1
items: list[dict[str, int | str]]
class trame_slicer.app.ui.dynamic_select.DynamicSelect(state: TypedState[DynamicSelectState], **kwargs)

Bases: VSelect

trame_slicer.app.ui.enum_to_title module

trame_slicer.app.ui.enum_to_title.enum_to_title(enum: Enum) str
trame_slicer.app.ui.enum_to_title.enum_to_radio_buttons(typed_state: TypedState, enum_type: type[Enum])

trame_slicer.app.ui.flex_container module

class trame_slicer.app.ui.flex_container.FlexContainer(row: bool = False, fill_height: bool = False, align: str | None = None, justify: str | None = None, **kwargs)

Bases: Div

trame_slicer.app.ui.layout_button module

class trame_slicer.app.ui.layout_button.LayoutButtonState(layout_ids: list[str] = <factory>, current_layout_id: str = 'Axial Primary')

Bases: object

layout_ids: list[str]
current_layout_id: str = 'Axial Primary'
class trame_slicer.app.ui.layout_button.LayoutButton(**kwargs)

Bases: VMenu

trame_slicer.app.ui.load_volume_ui module

class trame_slicer.app.ui.load_volume_ui.LoadVolumeItemsState(loading_busy: bool = False, button_tooltip: bool = False)

Bases: object

loading_busy: bool = False
button_tooltip: bool = False
class trame_slicer.app.ui.load_volume_ui.LoadVolumeState(file_button: trame_slicer.app.ui.load_volume_ui.LoadVolumeItemsState = <factory>, dir_button: trame_slicer.app.ui.load_volume_ui.LoadVolumeItemsState = <factory>)

Bases: object

file_button: LoadVolumeItemsState
dir_button: LoadVolumeItemsState
class trame_slicer.app.ui.load_volume_ui.LoadVolumeUI(**kwargs)

Bases: FlexContainer

on_load_volume

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

class trame_slicer.app.ui.load_volume_ui.LoadVolumeButton(name: str, load_directory: bool, icon: str, typed_state: TypedState[LoadVolumeItemsState], **kwargs)

Bases: FlexContainer

on_load_volume

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

trame_slicer.app.ui.markups_button module

class trame_slicer.app.ui.markups_button.MarkupsButton

Bases: VMenu

place_node_type

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

clear_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

trame_slicer.app.ui.medical_viewer_ui module

class trame_slicer.app.ui.medical_viewer_ui.MedicalViewerUI(server: Server, layout_manager: LayoutManager)

Bases: object

property data
property name

trame_slicer.app.ui.mpr_interaction_button module

class trame_slicer.app.ui.mpr_interaction_button.MprInteractionButtonState(is_interactive: bool = False)

Bases: object

is_interactive: bool = False
class trame_slicer.app.ui.mpr_interaction_button.MprInteractionButton(**kwargs)

Bases: FlexContainer

toggle_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

trame_slicer.app.ui.segmentation_app_ui module

class trame_slicer.app.ui.segmentation_app_ui.SegmentationAppUI(server: Server, layout_manager: LayoutManager)

Bases: object

property data
property name

trame_slicer.app.ui.slab_button module

class trame_slicer.app.ui.slab_button.SlabType(*values)

Bases: Enum

MIN = 0
MAX = 1
AVERAGE = 2
SUM = 3
class trame_slicer.app.ui.slab_button.SlabState(current_slab_type: trame_slicer.app.ui.slab_button.SlabType = <SlabType.MAX: 1>, slab_thickness_value: float = 0.0, slab_enabled: bool = False)

Bases: object

current_slab_type: SlabType = 1
slab_thickness_value: float = 0.0
slab_enabled: bool = False
class trame_slicer.app.ui.slab_button.SlabButton

Bases: VMenu

trame_slicer.app.ui.slider module

class trame_slicer.app.ui.slider.SliderState(min_value: float = 0, max_value: float = 1, value: float = 0.5, step: float = 1e-06, is_reversed: bool = False, is_disabled: bool = False)

Bases: object

min_value: float = 0
max_value: float = 1
value: float = 0.5
step: float = 1e-06
is_reversed: bool = False
is_disabled: bool = False
class trame_slicer.app.ui.slider.RangeSliderState(min_value: float = 0, max_value: float = 1, value: list[float] = <factory>, step: float = 1e-06, is_reversed: bool = False, is_disabled: bool = False)

Bases: object

min_value: float = 0
max_value: float = 1
value: list[float]
step: float = 1e-06
is_reversed: bool = False
is_disabled: bool = False
class trame_slicer.app.ui.slider.Slider(typed_state: TypedState[SliderState], **kwargs)

Bases: VSlider

class trame_slicer.app.ui.slider.RangeSlider(typed_state: TypedState[RangeSliderState], **kwargs)

Bases: VRangeSlider

trame_slicer.app.ui.text_components module

class trame_slicer.app.ui.text_components.Text(text: str, title: bool = False, subtitle: bool = False, **kwargs)

Bases: Div

class trame_slicer.app.ui.text_components.TextField(**kwargs)

Bases: VTextField

trame_slicer.app.ui.view_gutter module

trame_slicer.app.ui.view_gutter.create_vertical_view_gutter_ui(server: Server, view_id: str, view: AbstractViewChild, fill_gutter_f: Callable[[Server, str, AbstractViewChild], None] | None = None) None
trame_slicer.app.ui.view_gutter.create_slice_buttons(_server, _view_id, view: SliceView)
trame_slicer.app.ui.view_gutter.create_vertical_slice_view_gutter_ui(server: Server, view_id: str, view: AbstractViewChild) None

trame_slicer.app.ui.viewer_layout module

class trame_slicer.app.ui.viewer_layout.ViewerLayoutState(is_drawer_visible: bool = False, active_tool: str | None = None, is_volume_loaded: bool = False)

Bases: object

is_drawer_visible: bool = False
active_tool: str | None = None
is_volume_loaded: bool = False
class trame_slicer.app.ui.viewer_layout.ViewerLayout(server: Server, template_name='main', title: str = 'Trame Slicer', theme: str = 'dark', is_drawer_visible: bool = False)

Bases: VAppLayout

trame_slicer.app.ui.volume_property_ui module

class trame_slicer.app.ui.volume_property_ui.Preset(title: str, props: dict[str, str])

Bases: object

title: str
props: dict[str, str]
class trame_slicer.app.ui.volume_property_ui.VolumePropertyState(window_level_slider: trame_slicer.app.ui.slider.RangeSliderState = <factory>, vr_shift_slider: trame_slicer.app.ui.slider.SliderState = <factory>, presets_3d: list[trame_slicer.app.ui.volume_property_ui.Preset] = <factory>, preset_3d_name: str = 'CT-Coronary-Arteries-3', presets_2d: list[trame_slicer.app.ui.volume_property_ui.Preset] = <factory>, preset_2d_name: str | None = None, volume_crop_active: bool = False)

Bases: object

window_level_slider: RangeSliderState
vr_shift_slider: SliderState
presets_3d: list[Preset]
preset_3d_name: str = 'CT-Coronary-Arteries-3'
presets_2d: list[Preset]
preset_2d_name: str | None = None
volume_crop_active: bool = False
class trame_slicer.app.ui.volume_property_ui.VolumePropertyUI(**kwargs)

Bases: VCard

auto_window_level_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.

vr_crop_button_clicked

Signal implementation. Can be connected to one or more callables. When called, will call associated callables with the provided args and kwargs.

Provides utility methods and contextmanager to control signal execution. Can be used both as class property and instance.

Parameters:

type_info – Types of arguments expected by the signal.