User`s guide

11 Lay Out a Programmatic GUI
Compose and Code GUIs with Interactive Tools
In this section...
“Set Positions of Components Interactively” on page 11-43
“Align C omponents” on page 11-53
“Set Colors Interactively” on page 11-60
“Set Font Characteristics Interactively” on page 11-62
“Generate Code to Set Component Properties ” on page 11-64
Laying out a programmatic GUI can take time and involves many small
steps. For example, you must position c omponents manually—often several
times—to place them exactly where you want them to be. Establishing final
settings f or other properties and coding statements for them also takes time.
You can reduce the effort involved by taking advantage of built-in M ATLAB
tools and GUIs to establish values for component properties. The following
sections describe some of the tools.
Mode or
Tool
Use it to
Commands
Plot edit
mode
Interactively edit and
annotate plots
plotedit
Property
Editor
Edit graphical properties of
objects
propedit, propertyeditor
Property
Inspector
Int
eractively display and
edi
tmostobjectproperties
inspect
Al
ign
Di
stribute
To
ol
Al
ign and distribute
co
mponents with respect
to
one another
al
ign
C
olor
S
elector
C
hoose a color from a palette
o
f colors and obtain its value
u
isetcolor
Font Selector Preview character font,
style, and size and choose
values for them
uisetfont
11-42