Specifications
1 Getting Started with GUIDE
1-36
•on – The control is operational
•off – The control is disabled and its label (set by the
string property) is
grayed out.
•inactive – The control is disabled, but its label is not grayed out.
When a control is disabled, clicking on it with the left mouse button does not
execute its callback routine. However, the left-click causes two other callback
routines to execute:
•First the figure
WindowButtonDownFcn callback executes
•Then the control’s
ButtonDownFcn callback executes
A right mouse button click on a disabled control posts a context menu, if one is
defined for that control. See the
Enable property description for more details.
Axes
Axes enable your GUI to display graphics (e.g., graphs and images). Like all
graphics objects, axes have properties that you can set to control many aspects
of its behavior and appearance. See Axes Properties for general information on
axes objects.
Axes Callbacks
Axes are not uicontrol objects, but can be programmed to execute a callback
when users click a mouse button in the axes. Use the axes
ButtonDownFcn
property to define the callback.
Plotting to Axes in GUIs
GUIs that contain axes should ensure the Command-line accessibility option
in the Application Options dialog is set to
Callback (the default). This enables
you to issue plotting commands from callbacks without explicitly specifying the
target axes. See Command-Line Accessibility for more information about how
this option works.
GUIs with Multiple Axes
If a GUI has multiple axes, you should explicitly specify which axes you want
to target when you issue plotting commands. You can do this using the
axes
command and the
handles structure. For example,
axes(handles.axes1)