12.07.2015 Views

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

uicontrolString property (even though the text string has changed on the screen). Thisbehavior is consistent with the respective platform conventions.Frames are boxes that visually enclose regions of a figure window. Frames canmake a user interface easier to understand by visually grouping relatedcontrols. Frames have no callback routines associated with them. Onlyuicontrols can appear within frames.Frames are opaque, not transparent, so the order you define uicontrols isimportant in determining whether uicontrols within a frame are covered by theframe or are visible. Stacking order determines the order objects are drawn:objects defined first are drawn first; objects defined later are drawn overexisting objects. If you use a frame to enclose objects, you must define the framebefore you define the objects.List boxes display a list of items (defined using the String property) and enableusers to select one or more items. The Min and Max properties control theselection mode. The Value property indicates selected entries and contains theindices into the list of strings; a vector value indicates multiple selections.<strong>MATLAB</strong> evaluates the list box’s callback routine after any mouse button upevent that changes the Value property. Therefore, you may need to add a“Done” button to delay action caused by multiple clicks on list items. List boxesdifferentiate between single and double clicks and set the figureSelectionType property to normal or open accordingly before evaluating thelist box’s Callback property.Pop-up menus open to display a list of choices (defined using the Stringproperty) when pressed. When not open, a pop-up menu indicates the currentchoice. Pop-up menus are useful when you want to provide users with anumber of mutually exclusive choices, but do not want to take up the amountof space that a series of radio buttons requires. You must specify a value for theString property.Push buttons generate an action when pressed. To activate a push button, clickthe mouse button on the push button.Radio buttons are similar to check boxes, but are intended to be mutuallyexclusive within a group of related radio buttons (i.e., only one is in a pressedstate at any given time). To activate a radio button, click the mouse button onthe object. The state of the device is indicated on the display. Note that yourcode can implement the mutually exclusive behavior of radio buttons.2-535

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!