MibRibbon¶
- class controllers.MibRibbon¶
MIBRIBBON - controller for methods of the ribbon panels in MIB.
- Constructor Summary
- MibRibbon(mainCtrl, view, ribbonHandles, ribbonWidgets, model)¶
MIBRIBBON - % Init properties.
- Syntax:
obj = MibRibbon(mainCtrl, view, ribbonHandles, ribbonWidgets, model)
- Property Summary
- gui¶
handle to the GUI of the ribbon panel (views.components.Roi)
- handles¶
struct of ROI panel handles (panel, listbox, buttons, …)
- listeners¶
cell array of listeners
- mibController¶
controllers.MibController
- mibModel¶
models.MibModel
- view¶
MibView (full app view)
- Method Summary
- addCallbacksToDatasetImage()¶
ADDCALLBACKSTODATASETIMAGE - add callbacks to the Image ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetImage()
- addCallbacksToDatasetMask()¶
ADDCALLBACKSTODATASETMASK - add callbacks to the Mask ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetMask()
- addCallbacksToDatasetModel()¶
ADDCALLBACKSTODATASETMODEL - add callbacks to the Model ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetModel()
- addCallbacksToDatasetRibbon()¶
ADDCALLBACKSTODATASETRIBBON - add callbacks to the Dataset ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetRibbon()
- addCallbacksToDatasetSelection()¶
ADDCALLBACKSTODATASETSELECTION - add callbacks to the Selection ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetSelection()
- addCallbacksToDatasetTools()¶
ADDCALLBACKSTODATASETTOOLS - add callbacks to the Tools ribbon to allow lazy loading.
- Syntax:
obj.addCallbacksToDatasetTools()
- dataset_Callbacks(hWidget, hData)¶
DATASET_CALLBACKS - callbacks on press of buttons in the Dataset ribbon.
- Syntax:
obj.dataset_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- homeDevTest_Callback(hWidget, hData)¶
HOMEDEVTEST_CALLBACK - Reserved for MIB developmental purposes.
- Syntax:
obj.homeDevTest_Callback(hWidget, hData)
Currently runs benchmarkGetSetData (below) - a correctness + performance benchmark of the getData2D/3D/4D and setData2D/3D/4D accessors. Can also be invoked from the MATLAB command line without widget arguments:
mib.cRibbon.homeDevTest_Callback();
- homeExamples_Callback(BatchOptIn)¶
HOMEEXAMPLES_CALLBACK - callback on press of the Examples buttons in the Home ribbon; imports an example dataset.
- Syntax:
obj.homeExamples_Callback(BatchOptIn)- Input Arguments:
BatchOptIn - a structure for batch processing mode, when NaN return a structure with default options via “syncBatch” event .Dataset [cell] dataset name .DirectoryName [cell] output directory, only for DeepMIB projects .showWaitbar [logical] show or not the waitbar
- homeImport_Callback(hWidget, hData)¶
HOMEIMPORT_CALLBACK - callback on press of the import buttons in the Home ribbon.
- Syntax:
obj.homeImport_Callback(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- homeSelectRecentDir_Callback(recentDir)¶
HOMESELECTRECENTDIR_CALLBACK - callback on selection of the recent directory.
- Syntax:
obj.homeSelectRecentDir_Callback(recentDir)
in a list (obj.view.handles.ribbonHome.loadFile.Popup) under the Open image button (obj.view.handles.ribbonHome.loadFile) of the Home ribbon (obj.view.handles.ribbonHome)
- Input Arguments:
recentDir - char with the full directory path
- homeUpdateRecentDirsList()¶
HOMEUPDATERECENTDIRSLIST - update the recent directories list (obj.view.handles.ribbonHome.loadFile.Popup) under the Open image button (obj.view.handles.ribbonHome.loadFile) of.
- Syntax:
obj.homeUpdateRecentDirsList()
the Home ribbon (obj.view.handles.ribbonHome)
Triggered on listening to MibModel->UpdateRecentDirsList event (notify(obj.mibModel, ‘UpdateRecentDirsList’); called in models.MibModel.loadImages function
- home_Callbacks(hWidget, hData)¶
HOME_CALLBACKS - callback on press of the I/O tools buttons in the Home ribbon.
- Syntax:
obj.home_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- imageIntensityProfile(mode)¶
IMAGEINTENSITYPROFILE - Draw a line or freehand path and display the intensity profile.
- Syntax:
obj.imageIntensityProfile(mode)
Lets the user draw an interactive ROI on the current image view, then on double-click or Enter computes
improfilefor each displayed color channel and shows the result in a two-panel MATLAB figure (image with overlay on top, intensity vs. distance on the bottom). Press Escape to cancel without computing.- Input Arguments:
mode - char; drawing mode
'line'- straight line between two endpoints'arbitrary'- freehand open path
- Output Arguments:
(none)
- Usage:
Example 1 - called from image_Callbacks
obj.imageIntensityProfile('line'); obj.imageIntensityProfile('arbitrary');
- image_Callbacks(hWidget, hData)¶
IMAGE_CALLBACKS - callback on press of buttons in the Image ribbon.
- Syntax:
obj.image_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- mask_Callbacks(hWidget, hData)¶
MASK_CALLBACKS - callback on press of buttons in the Mask ribbon.
- Syntax:
obj.mask_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- modelRender_Callback(hWidget, hData)¶
MODELRENDER_CALLBACK - callback on press of buttons in the Render button of the Model ribbon.
- Syntax:
obj.modelRender_Callback(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- model_Callbacks(hWidget, hData)¶
MODEL_CALLBACKS - callbacks on press of buttons in the Model ribbon.
- Syntax:
obj.model_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- selectionBuffer(parameter)¶
SELECTIONBUFFER - Copy/Paste/Clear the selection of the current layer to/from a buffer.
- Syntax:
obj.selectionBuffer(parameter)- Input Arguments:
parameter - action to perform:
'copy'- store the selection from the current slice into the buffer'paste'- OR the buffered selection into the current slice'pasteall'- OR the buffered selection into all Z-slices of the current stack'clear'- clear the selection buffer
Updates 01.06.2026, IB, ported from MIB2 menuSelectionBuffer_Callback
- selection_Callbacks(hWidget, hData)¶
SELECTION_CALLBACKS - callback on press of buttons in the Selection to Mask section of the Selection ribbon.
- Syntax:
obj.selection_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- tools_Callbacks(hWidget, hData)¶
TOOLS_CALLBACKS - callback on press of buttons in the Tools ribbon.
- Syntax:
obj.tools_Callbacks(hWidget, hData)- Input Arguments:
hWidget - handle to the pressed widget
hData - handle to supporting EventData class
- updateVoxelSizes(pixSize, BatchOptIn)¶
UPDATEVOXELSIZES - Update the physical voxel sizes of the currently shown dataset.
- Syntax:
result = obj.updateVoxelSizes(pixSize, BatchOptIn)
Opens an interactive dialog when called without arguments, or accepts values programmatically via pixSize / BatchOptIn for scripting and batch-processing workflows. Replaces MIB2: mibController.menuDatasetParameters_Callback
- Input Arguments:
pixSize - (optional) [struct] structure with new voxel parameters. When omitted or empty the user is prompted via an interactive dialog. Fields:
.x - [numeric] physical voxel size in X
.y - [numeric] physical voxel size in Y
.z - [numeric] physical voxel size in Z
.t - [numeric] time step between frames
.units - [char] physical units:
'm','cm','mm','um', or'nm'.tunits - [char] time units (e.g.,
's','m','h')
BatchOptIn - (optional) [struct] structure for batch-processing mode. Pass NaN to retrieve default options via the ‘SyncBatch’ event. Fields:
.VoxelX - [char] physical voxel size in X
.VoxelY - [char] physical voxel size in Y
.VoxelZ - [char] physical voxel size in Z
.VoxelT - [char] time step between frames
.Units - [cell]
{'m','cm','mm','um','nm'}with selected index as second element.TimeUnits - [char] time units
.id - (optional) [numeric] dataset index 1-9; default = current dataset
- Output Arguments:
result - 1 on success, 0 on cancel