User`s guide
15 Examples of GUIs Created Programmatically
Call the colorPalette Function
You can c
all the
colorPalette function with a statement such as
mGetColorFcn = colorPalette('Parent',hPaletteContainer)
The col
orPalette
function accepts property value p airs as input arguments.
Only th
e custom property
Parent is su p ported. This property specifies the
handle
of the parent figure or panel that contains the color palette. If the call
to
col
orPalette
does not specify a parent, it uses the current figure, gcf.
Unrec
ognized property names or invalid values are ignored.
colo
rPalette
returns a function handle that the host G UI can call to get the
curr
ently selected color. The host GUI can use the returned function handle
at an
y time b efore the color palette is destroyed. For more information,
see “
Share D ata Between T wo GUIs” on page 15-60 for implementation
det
ails. “Icon Editor” on page 15-63 is an example of a host GUI that uses
the
colorPalette.
15-54