User`s guide
8 Programming a GUIDE GUI
Tip You can enable text in controls to resize automatically by setting the
component’s
fontUnits to normalized, without the need for a ResizeFcn.
This example illustrates one way to achieve the same result with callback
code.
Nested panels resize from inner to outer (in child-to-parent order). For more
information about resizing panels, see the uipanel properties reference page.
Button Group
Button groups are like panels except that they manage exclusive selection
behavior for radio buttons and toggle buttons. If a button group contains a
set of radio buttons, toggle buttons, or both, the button group allows only one
of them to be selected. When a user clicks a button, that button is s elected
and all others are deselected.
When programming a button group, you do not code callbacks for the
individual buttons; instead, use its
SelectionChangeFcn callback to manage
responses to selections. The following example, “Programming a Button
Group” on page 8-43, illustrates how you use
uibuttongroup event data to
do this.
The following figure shows a button group with two radio buttons and two
toggle buttons. Radio Button 1 is selected.
8-42