MATLAB SIMULINK 7 - GRAPHICAL USER INTERFACE Dokumentacja Strona 27

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 180
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 26
Getting Started Example
1-19
data_popup_Callback(handles.data_popup,[],handles)
Push Button Callbacks
Each of the push buttons creates a different type of plot using the data specified
by the current selection in the popup menu. Their callbacks get data from the
handles structure and then plot it.
Surf push button callback:
function varargout = surf_pushbutton_Callback(h,eventdata,handles,varargin)
z = handles.data; % Load data from handles structure
surf(z);
Mesh push button callback:
function varargout = mesh_pushbutton_Callback(h,eventdata,handles,varargin)
z = handles.data; % Load data from handles structure
mesh(z)
Contour push button callback:
function varargout =
contour_pushbutton_Callback(h,eventdata,handles,varargin)
z = handles.data; % Load data from handles structure
contour(z)
Example – Testing the GUI
After writing the callbacks, you can activate the GUI to test it. Activate the
GUI by selecting
Activate Figure from the Tools menu or use the activator
button from the GUIDE toolbar. Select
membrane in the popup menu and press
the
Contour push button. The GUI should look like this:
Przeglądanie stron 26
1 2 ... 22 23 24 25 26 27 28 29 30 31 32 ... 179 180

Komentarze do niniejszej Instrukcji

Brak uwag