brain_deer.presentation.qt.bottom_panel

Bottom panel of braindeer 🧠🦌 Created on Wed Apr 9 08:33:22 2025 @author: maikemustin

Classes

StickyComboBox

ComboBox that keeps the bottom panel open while its popup is active.

LayerStackWidget

Widget for visual layer stack management with drag-and-drop reordering.

LayerStackItemWidget

Individual layer item in the stack with controls.

Functions

projection_target_candidates(→ list[str])

Volumes and tractograms that can receive a projected scalar map.

atlas_row_structure_id(→ str | None)

Structure id when a loaded_files entry is an atlas-browser-managed tract row.

atlas_browser_2_widget(main_window)

Return the Atlas Browser 2 widget instance (None when the plugin is inactive).

create_original_files_tab(main_window)

Create the original file manager tab.

create_datalad_tab(main_window)

Create DataLad integration tab.

create_bids_tab(main_window)

Create BIDS dataset browser tab.

create_layer_composition_tab(main_window)

Create layer composition and blending tab.

create_composition_controls(main_window)

Create composition control panel.

create_global_composition_settings(main_window)

Create global composition settings.

create_export_tab(main_window)

Create comprehensive export & publishing tab.

datalad_action(main_window, action)

Handle DataLad actions via the CLI when available.

bids_action(main_window, action)

Legacy hook — delegate to the BIDS panel when present.

export_action(main_window, export_type)

Handle comprehensive export actions.

handle_screenshot_export(main_window)

Export high-quality screenshot of current view.

handle_multiview_export(main_window)

Export multi-view layout (sagittal, coronal, axial, 3D).

handle_montage_export(main_window)

Export slice montage.

handle_3d_model_export(main_window, format_type)

Export 3D models in various formats.

handle_vtk_export(main_window)

Export VTK scene file.

handle_gltf_export(main_window)

Export glTF 2.0 for web/AR/VR.

handle_x3d_export(main_window)

Export X3D for web visualization.

handle_video_export(main_window, video_type)

Export video and animations.

handle_web_export(main_window, web_type)

Export web and interactive formats.

complete_export(main_window, export_type)

Complete export with status update.

update_remove_button_state(main_window)

Update the remove button state based on selection.

open_screenshot_export(main_window)

Open the screenshot export dialog.

import_dicom_folder(main_window)

Import DICOM series from a folder.

remove_selected_file(main_window)

Remove selected files from the bottom panel list and main window.

highlight_active_file(main_window, filename)

Bold the active row's filename in the bottom Files list (no signals fired).

reorder_files(main_window)

Handle file reordering when items are dragged in the list

refresh_file_row_3d_ui(→ None)

Sync bottom-panel 3D toggle / render mode from loaded_files[filename].

apply_projection_target(→ None)

Set a single projection target (legacy); prefer apply_projection_targets().

reapply_atlas_tract_projections(→ None)

Re-run map projection for Atlas-Browser tracts targeted by volume_name.

refresh_surface_row_targets(main_window)

Re-render the automatic surface scene after the file set/roles change.

export_combined_layers(main_window)

Export all layers as a single combined volume.

export_individual_layers(main_window)

Export each layer as a separate file.

export_complete_scene(main_window)

Export complete scene with metadata and layer configuration.

Module Contents

brain_deer.presentation.qt.bottom_panel.projection_target_candidates(main_window, exclude_filename: str) → list[str]

Volumes and tractograms that can receive a projected scalar map.

brain_deer.presentation.qt.bottom_panel.atlas_row_structure_id(info) → str | None

Structure id when a loaded_files entry is an atlas-browser-managed tract row.

brain_deer.presentation.qt.bottom_panel.atlas_browser_2_widget(main_window)

Return the Atlas Browser 2 widget instance (None when the plugin is inactive).

class brain_deer.presentation.qt.bottom_panel.StickyComboBox(main_window, *args, **kwargs)

Bases: PyQt5.QtWidgets.QComboBox

ComboBox that keeps the bottom panel open while its popup is active.

brain_deer.presentation.qt.bottom_panel.create_original_files_tab(main_window)

Create the original file manager tab.

brain_deer.presentation.qt.bottom_panel.create_datalad_tab(main_window)

Create DataLad integration tab.

brain_deer.presentation.qt.bottom_panel.create_bids_tab(main_window)

Create BIDS dataset browser tab.

brain_deer.presentation.qt.bottom_panel.create_layer_composition_tab(main_window)

Create layer composition and blending tab.

brain_deer.presentation.qt.bottom_panel.create_composition_controls(main_window)

Create composition control panel.

brain_deer.presentation.qt.bottom_panel.create_global_composition_settings(main_window)

Create global composition settings.

class brain_deer.presentation.qt.bottom_panel.LayerStackWidget(main_window)

Bases: PyQt5.QtWidgets.QWidget

Widget for visual layer stack management with drag-and-drop reordering.

add_layer_item(layer_id: str, layer_config: dict)

Add a new layer to the visual stack.

remove_layer_item(layer_id: str)

Remove a layer from the visual stack.

update_stack_info()

Update the stack information display.

add_new_layer()

Add a new layer via file dialog.

remove_selected_layer()

Remove the currently selected layer.

duplicate_layer()

Duplicate the currently selected layer.

on_layer_reordered()

Handle layer reordering via drag-drop.

class brain_deer.presentation.qt.bottom_panel.LayerStackItemWidget(layer_id: str, layer_config: dict, main_window)

Bases: PyQt5.QtWidgets.QWidget

Individual layer item in the stack with controls.

on_opacity_changed(value)

Handle opacity change.

on_visibility_changed(state)

Handle visibility change.

brain_deer.presentation.qt.bottom_panel.create_export_tab(main_window)

Create comprehensive export & publishing tab.

brain_deer.presentation.qt.bottom_panel.datalad_action(main_window, action)

Handle DataLad actions via the CLI when available.

brain_deer.presentation.qt.bottom_panel.bids_action(main_window, action)

Legacy hook — delegate to the BIDS panel when present.

brain_deer.presentation.qt.bottom_panel.export_action(main_window, export_type)

Handle comprehensive export actions.

brain_deer.presentation.qt.bottom_panel.handle_screenshot_export(main_window)

Export high-quality screenshot of current view.

brain_deer.presentation.qt.bottom_panel.handle_multiview_export(main_window)

Export multi-view layout (sagittal, coronal, axial, 3D).

brain_deer.presentation.qt.bottom_panel.handle_montage_export(main_window)

Export slice montage.

brain_deer.presentation.qt.bottom_panel.handle_3d_model_export(main_window, format_type)

Export 3D models in various formats.

brain_deer.presentation.qt.bottom_panel.handle_vtk_export(main_window)

Export VTK scene file.

brain_deer.presentation.qt.bottom_panel.handle_gltf_export(main_window)

Export glTF 2.0 for web/AR/VR.

brain_deer.presentation.qt.bottom_panel.handle_x3d_export(main_window)

Export X3D for web visualization.

brain_deer.presentation.qt.bottom_panel.handle_video_export(main_window, video_type)

Export video and animations.

brain_deer.presentation.qt.bottom_panel.handle_web_export(main_window, web_type)

Export web and interactive formats.

brain_deer.presentation.qt.bottom_panel.complete_export(main_window, export_type)

Complete export with status update.

brain_deer.presentation.qt.bottom_panel.update_remove_button_state(main_window)

Update the remove button state based on selection.

brain_deer.presentation.qt.bottom_panel.open_screenshot_export(main_window)

Open the screenshot export dialog.

brain_deer.presentation.qt.bottom_panel.import_dicom_folder(main_window)

Import DICOM series from a folder.

brain_deer.presentation.qt.bottom_panel.remove_selected_file(main_window)

Remove selected files from the bottom panel list and main window.

brain_deer.presentation.qt.bottom_panel.highlight_active_file(main_window, filename)

Bold the active row’s filename in the bottom Files list (no signals fired).

brain_deer.presentation.qt.bottom_panel.reorder_files(main_window)

Handle file reordering when items are dragged in the list

brain_deer.presentation.qt.bottom_panel.refresh_file_row_3d_ui(main_window, filename: str) → None

Sync bottom-panel 3D toggle / render mode from loaded_files[filename].

brain_deer.presentation.qt.bottom_panel.apply_projection_target(main_window, filename: str, target: str | None) → None

Set a single projection target (legacy); prefer apply_projection_targets().

brain_deer.presentation.qt.bottom_panel.reapply_atlas_tract_projections(main_window, volume_name: str) → None

Re-run map projection for Atlas-Browser tracts targeted by volume_name.

Called when a projection source’s appearance (colormap / contrast / time index) changes so the tract colors track the map without a scene rebuild.

brain_deer.presentation.qt.bottom_panel.refresh_surface_row_targets(main_window)

Re-render the automatic surface scene after the file set/roles change.

brain_deer.presentation.qt.bottom_panel.export_combined_layers(main_window)

Export all layers as a single combined volume.

brain_deer.presentation.qt.bottom_panel.export_individual_layers(main_window)

Export each layer as a separate file.

brain_deer.presentation.qt.bottom_panel.export_complete_scene(main_window)

Export complete scene with metadata and layer configuration.