Разработка графического пользовательского интерфейса в среде MATLAB. Бадриев И.Б - 101 стр.

UptoLike

9 Ëèñòèíã ïðîãðàììû                                                      101


  % *See GUI Options on GUIDE's Tools menu. Choose "GUI allows
  % only one instance to run (singleton)".

  % See also: GUIDE, GUIDATA, GUIHANDLES

  % Edit the above text to modify the response to help graphic

  % Begin initialization code - DO NOT EDIT

  % Êîëè÷åñòâî êîïèé ïðèëîæåíèÿ
  gui_Singleton = 1;
  % Ôîðìèðóåì ñòðóêòóðó ñîäåðæàùóþ èíôîðìàöèþ î ïðèëîæåíèè

gui\_State = struct('gui\_Name',      mfilename, ...
                   'gui\_Singleton', gui\_Singleton, ...
                   'gui\_OpeningFcn', @graphic\_OpeningFcn, ...
                   'gui\_OutputFcn', @graphic\_OutputFcn, ...
                   'gui\_LayoutFcn', [] , ...
                   'gui\_Callback',   []);

  % Ïðîâåðÿåì áûëà ëè ôóíêöèÿ graphic âûçâàíà ñ âõîäíûìè àðãóìåíòàìè è
  % ÿâëÿåòñÿ ëè ïåðâûé àðãóìåíò ñòðîêîé
  if nargin && ischar(varargin{1})
    % Â ñòðóêòóðó gui_State ïðèñâàèâàåì ïîëþ gui_Callback óêàçàòåëü íà
    % ôóíêöèþ âûçâàâøóþ ïðèëîæåíèå graphic
    gui_State.gui_Callback = str2func(varargin{1});
  end
  % Ïðîâåðÿåì áûëà ëè ôóíêöèÿ graphic âûçâàíà ñ âûõîäíûìè àðãóìåíòàìè
  % è ñîçäàåì îêíî ïðèëîæåíèÿ ïðè ïîìîùè ôóíêöèè gui_mainfcn
  if nargout
    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
  else
    gui_mainfcn(gui_State, varargin{:});
  end