Microscopy Image Browser 2.91
MIB
Loading...
Searching...
No Matches
mibInputMultiDlg.m File Reference

custom input dialog More...

Functions

function varargoutmibInputMultiDlg (varargin)
 custom input dialog
 
function  mibInputMultiDlg>mibInputMultiDlg_OpeningFcn (hObject, eventdata, handles, varargin)
 
function varargoutmibInputMultiDlg>mibInputMultiDlg_OutputFcn (hObject, eventdata, handles)
 
function  mibInputMultiDlg>mibInputMultiDlg_CloseRequestFcn (hObject, eventdata, handles)
 
function  mibInputMultiDlg>okBtn_Callback (hObject, eventdata, handles)
 
function  mibInputMultiDlg>cancelBtn_Callback (hObject, eventdata, handles)
 
function  mibInputMultiDlg>mibInputMultiDlg_KeyPressFcn (hObject, eventdata, handles)
 
function  mibInputMultiDlg>textEdit_Callback (hObject, eventdata, handles)
 
function  mibInputMultiDlg>mibInputMultiDlg_ResizeFcn (hObject, eventdata, handles)
 
function  mibInputMultiDlg>Help_Callback (hObject, eventdata, handles)
 

Detailed Description

custom input dialog

Function Documentation

◆ mibInputMultiDlg()

function varargout = mibInputMultiDlg ( varargin)

custom input dialog

Parameters
varargin
mibInputMultiDlg ( mibPath, prompts, defaultAns, dlg_title, options )
function varargout = mibInputMultiDlg(varargin)
custom input dialog
Definition mibInputMultiDlg.m:17
Required Parameters for varargin:
  • mibPath [optional] a cell string with a path to MIB installation, use
    global mibPath;
    to get it, or just an empty cell: {[]}
  • prompts a cell array {n x 1} with the prompts for each edit field of the dialog
  • defaultAns a cell array {n x 1} with the default answers for each edit. The following options for each element is available:
    • ' or some text - initialized as a text box with the provided default text
    • another cell array - initialized as a combo box with entries taken from this cell array; Note! the last entry should be the default value to be selected!
    • true/false - initialized as a checkbox
  • dlg_title - a string with the name of the dialog
  • options an optional structure with additional options .WindowStyle - a string, can be either normal or modal (default). .PromptLines - a number or an array of numbers (equal to number of prompts) that define how many lines of text should be in the prompt field. Default is 1. .Title - a string with a text that will be displayed before the widgets, at the top of the window .TitleLines - a number that defines number of text lines reserved for the title .WindowWidth - a number scales the standard width of the dialog x times .Columns - an integer that defines number of columns .LastItemColumns - [optional] force the last entry to be on a single column, 1 or 0 .Focus - define index of the widget to get focused .okBtnText - text for the OK button .helpBtnText - text for the Help button .HelpUrl - URL to the help page, when provided a Help button is displayed, press of the button opens the url in a browser (requires http in the beginning of the url link). Alternatively, it can be a command to execute. .msgBoxOnly - logical, to mimic message box without input fields .Icon - string (question-default, celebrate, call4help, warning), an icon to use
Return values
answera cell array with the entered values, or empty, when cancelled
selectedIndicesa vector with indices of selected options, mostly used for comboboxes

Examples:

global mibPath;
prompts = {'Enter a text'; 'Select the option'; 'Are you sure?'; 'placeholder, remove text to make empty'; 'This is very very very very very very very very very very long prompt'};
defAns = {'my test string'; {'Option 1', 'Option 2', 'Option 3', 2}; true; NaN; []};
dlgTitle = 'multi line input diglog';
options.WindowStyle = 'normal'; // [optional] style of the window
options.PromptLines = [1, 1, 1, 1, 2]; // [optional] number of lines for widget titles
options.Title = 'My test Input dialog'; // [optional] additional text at the top of the window
options.TitleLines = 2; // [optional] make it twice tall, number of text lines for the title
options.WindowWidth = 1.2; // [optional] make window x1.2 times wider
options.Columns = 2; // [optional] define number of columns
options.Focus = 1; // [optional] define index of the widget to get focus
options.HelpUrl = 'http:\\mib.helsinki.fi'; // [optional], an url for the Help button
options.LastItemColumns = 1; // [optional] force the last entry to be on a single column
options.msgBoxOnly = false; // [optional] mimic message box without input fields
options.Icon = 'question'; // [optional] icon to use: "question" (default), "celebrate", "call4help", "warning"
[answer, selIndex] = mibInputMultiDlg({mibPath}, prompts, defAns, dlgTitle, options);
if isempty(answer); return; end

Referenced by mibModel.addFrame(), mibImage.addFrameToImage(), mibAlignmentController.AutomaticFeatureBasedAlignment(), mibDeepController.balanceClasses(), mibModel.colorChannelActions(), mibModel.contentAwareFill(), mibAlignmentController.continueBtn_Callback(), mibModel.contrastCLAHE(), mibModel.contrastNormalization(), mibImage.copyColorChannel(), mibModel.copySwapSlice(), mibDeepController.countLabels(), mibCropController.cropToBtn_Callback(), mibModel.deleteSlice(), mibMeasure.DistanceFreeFun(), mibDeepController.evaluateSegmentation(), mibDeepController.exportNetwork(), mibGraphcutController.exportSuperpixelsBtn_Callback(), mibDeepController.generate3DDeepLabV3Network(), mibDeepController.generateDeepLabV3Network(), mibCropObjectsController.generatePatches(), mibVolRenAppController.grabVolume(), mibVolRenController.grabVolume(), mibPreferencesController.guiScalingBtn_Callback(), mibDeepController.importNetwork(), mibGraphcutController.importSuperpixelsBtn_Callback(), mibModel.insertEmptySlice(), mibImage.invertColorChannel(), mibAnnotationsController.loadBtn_Callback(), mibLines3DController.loadBtn_Callback(), mibMeasureToolController.loadBtn_Callback(), mibDeepActivationsController.makeCollage(), mibModel.materialsActions(), mibModel.materialsSwapColors(), mibMeasureToolController.measureTable_cm(), mibController.menuDatasetScalebar_Callback(), mibController.menuFileExportImage_Callback(), mibController.menuFileImportImage_Callback(), mibController.menuFileRender_Callback(), mibController.menuImageToolsProjection_Callback(), mibController.menuMaskExport_Callback(), mibController.menuMaskImageReplace_Callback(), mibController.menuMaskImport_Callback(), mibController.menuModelAnn_Callback(), mibController.menuModelsImport_Callback(), mibVolRenController.menuSettingsSelectColormap_Callback(), mibController.mibAutoBrightnessBtn_Callback(), mibController.mibBrushPanelInterpolationSettingsBtn_Callback(), mibController.mibBufferToggleContext_Callback(), mibDeepTrainingProgressStructUpdateAxesLimits(), mibController.mibFileFilterPopup_cm(), mibController.mibFilesListbox_cm_Callback(), mibGenerateDefaultSegmentationPalette(), mibGetImageMetadata(), mibGetImages(), mibController.mibPixelInfo_Callback(), mibController.mibRemoveMaterialBtn_Callback(), mibRenderVolumeWithFiji(), mibController.mibSegmentationAnnotation(), mibController.mibSegmentationTable_cm_Callback(), mibController.mibSegmSAMPanel_Callbacks(), mibController.mibShowMilestoneDialog(), mibSubtractRunningAverage(), mibModel.modelExport(), mibPreferencesController.modelsColorsTable_cb(), mibPreferencesAppController.ModelsColorsTableContextMenuCallbacks(), mibGUI>menuHelp_Callbacks(), mibGUI>mibChangeLayerSliderContext_cb(), mibGUI>mibChangeTimeSliderContext_cb(), mibDeepAugmentSettingsController.previewAugmentations(), mibModel.resliceDataset(), mibImage.rotateColorChannel(), mibAnnotationsController.saveAnnotationsToFile(), mibLines3DController.saveBtn_Callback(), mibDeepController.saveCheckpointNetworkCheck(), mibImage.saveImageAsDialog(), mibImage.saveModel(), Lines3D.saveToFile(), mibBatchController.selectedActionTable_ContextCallback(), mibDeepController.sendReportsCallback(), mibDeepController.setActivationLayerOptions(), mibDeepController.setInputLayerSettings(), mibMeasure.setOptions(), mibDeepAugmentSettingsController.setPreviewAugmentationSettings(), mibDeepController.setSegmentationLayerOptions(), mibAnnotationsController.settingsBtn_Callback(), mibLines3DController.settingsBtn_Callback(), mibDeepController.setTrainingSettings(), mibModel.smoothImage(), mibDeepController.start(), mibWoundHealingAssayController.Stitch(), mibImage.swapColorChannels(), mibAnnotationsController.tableContextMenu_cb(), mibStatisticsController.tableContextMenu_cb(), mibDeepController.transferLearning(), mibAlignmentController.updateAutomaticOptions(), mibDeepController.updateDynamicMaskSettings(), mibRoiRegion.updateOptions(), mibImage.updatePixSizeResolution(), and mibLines3DController.visualizeBtn_Callback().

◆ mibInputMultiDlg>cancelBtn_Callback()

function mibInputMultiDlg>cancelBtn_Callback ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>Help_Callback()

function mibInputMultiDlg>Help_Callback ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>mibInputMultiDlg_CloseRequestFcn()

function mibInputMultiDlg>mibInputMultiDlg_CloseRequestFcn ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>mibInputMultiDlg_KeyPressFcn()

function mibInputMultiDlg>mibInputMultiDlg_KeyPressFcn ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>mibInputMultiDlg_OpeningFcn()

function mibInputMultiDlg>mibInputMultiDlg_OpeningFcn ( hObject,
eventdata,
handles,
varargin )

References max, mibRescaleWidgets(), mibUpdateFontSize(), min, and moveWindowOutside().

Here is the call graph for this function:

◆ mibInputMultiDlg>mibInputMultiDlg_OutputFcn()

function varargout = mibInputMultiDlg>mibInputMultiDlg_OutputFcn ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>mibInputMultiDlg_ResizeFcn()

function mibInputMultiDlg>mibInputMultiDlg_ResizeFcn ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>okBtn_Callback()

function mibInputMultiDlg>okBtn_Callback ( hObject,
eventdata,
handles )

◆ mibInputMultiDlg>textEdit_Callback()

function mibInputMultiDlg>textEdit_Callback ( hObject,
eventdata,
handles )