MATLAB SIMULINK 7 - GRAPHICAL USER INTERFACE Guida Utente Pagina 723

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 759
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 722
Color Palette
The colorPalette function then defines the valid custom properties in a
3-by-3 cell array.
mPropertyDefs = {... % The supported custom property/value
% pairs of this GUI
'parent', @localValidateInput, 'mPaletteParent';
The first column contains the property name.
The second column contains a function handle for the function,
localValidateInput, that validates the input property values .
The third column is the local variable that holds the value of the property.
colorPalette then initializes the properties with default values.
mPaletteParent = []; % Use input property 'parent ' to initialize
Process the Input Arguments. The processUserInputs helper
function processes the input property/value pairs.
colorPalette calls
processUserInputs before it creates the components, to determine the parent
of the components.
% Process the command line inp ut arguments supplied when
% the GUI is invoked
processUserInputs();
1 processUserI nputs sequences through the inputs, if any, and tries
to match each property name to a string in the first column of the
mPropertyDefs cell array.
2 If it finds a match, processUserInputs assigns the value that was input
for the property to its variable in the third column of the
mPropertyDefs
cell array.
3 processUserI nputs then calls the helper function specified in the second
column of the
mPropertyDefs cellarraytovalidatethevaluethatwas
passed in for the property.
15-59
Vedere la pagina 722
1 2 ... 718 719 720 721 722 723 724 725 726 727 728 ... 758 759

Commenti su questo manuale

Nessun commento