Specifications
Setting Properties for GUI Components
2-15
When you first add a component to a layout, GUIDE sets the value of Tag to a
default string such as
pushbutton1. If the component has a Callback property,
GUIDE also sets the value of
Callback to the string %automatic. The following
figure shows an example.
-
When you save or run the GUI, GUIDE generates an M-file that includes stubs
for the
Callback functions for each component that has one. GUIDE creates a
unique function name for each
Callback function in the M-file by prefixing the
value of the
Tag property to the string _Callback, for example,
pushbutton1_Callback. GUIDE also changes the value of the Callback
property to a string that is a calling sequence for the callback. For example, if
the name of the GUI M-file is
simple_gui, the new value of the Callback
property becomes
untitled('pushbutton1_Callback',gcbo,[],guidata(gcbo))
...