Filter löschen
Filter löschen

Embedding a uicontrol listbox in a uimenu?

2 Ansichten (letzte 30 Tage)
Benjamin Levy
Benjamin Levy am 30 Nov. 2017
Beantwortet: Elizabeth Reese am 4 Dez. 2017
I have a set of customized menu options on the toolbar of my GUI. One of the options is 'Tools', which has several submenus. I want to embed a checkbox or listbox uicontrol in the second submenu of 'Tools', so that the workflow will be... 1. Click on 'Tools' in topbar of figure. 2. Click on 'Plotting' from 'Tools'. At this point, a popup window or such should appear which allows me to select one or more features from a list (checkbox or listbox); the values selected are returned with a callback to plot the selected features on a gui handle in the main figure.
In otherwords, can I implement the uicontrol 'listbox' in the uimenu context.
Thank you.
BSL

Antworten (1)

Elizabeth Reese
Elizabeth Reese am 4 Dez. 2017
It is possible to open a new dialog with the checkbox or listbox from the menu. You can do this by adding a callback to the "Plotting" option in your menu. In the callback, create your new dialog with the uicontrols that you would like to use. You can add a callback to those uicontrols and have the dialog return the values that were selected. You can read more about dialog boxes here.

Kategorien

Mehr zu Migrate GUIDE Apps finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by