MATLAB Creating Graphical User Interfaces

(ff) #1
If the value of Max - Min is less than or equal to 1, the editable text field allows only a
single line of input. If the width of the text field is too narrow for the text, MATLAB
displays only part of the text. The user can use the arrow keys to move the cursor over
the entire line of text.

Pop-Up Menu

This code creates a pop-up menu:

f = figure;
pm = uicontrol(f,'Style','popupmenu',...
'String',{'one','two','three','four'},...
'Value',1,'Position',[30 80 130 20]);

9 Lay Out a Programmatic UI

Free download pdf