m_pr.m

来自「这是一个用于语音信号处理的工具箱」· M 代码 · 共 83 行

M
83
字号
%
% Callback function for Property button of Main window
% Author : Minkyu Lee
% Date : 29-Sep-1994
%

PV=[2 219 291 186];
s2 = 'Property';

% Open analysis window
while exist('m_pr_win_h')==1
   try1 = 'get(m_pr_win_h,''position'');';
   eval(try1,catch2);
   if check ==0
      clear m_pr_win_h;
      check = 1;
      break;
   end
   s1 = get(m_pr_win_h,'Name');
   if ~strcmp(s1,s2)
      clear m_pr_win_h;
      break;
   end
   figure(m_pr_win_h);
   break;
end;

if exist('m_pr_win_h')~=1;

   m_pr_win_h=figure('Position',PV,...
      'Resize','off',...
      'Numbertitle','off',...
      'color',BACK_COLOR,...
      'Name',s2);

   S=sprintf('Number of poles : %d',num_poles);
   m_pr_txt_np_h=uicontrol('Style','edit',...
      'Position',[15 150 150 20],...
      'String',S);
   
   m_pr_sl_np_h=uicontrol('Style','slider',...
      'Position',[175 150 110 20],...
      'String','Number of poles',...
      'Max',max_np,...
      'Min',min_np,...
      'Value', num_poles,...
      'Callback','pr_np');
   
   S=sprintf('Number of zeros : %d',num_zeros);
   m_pr_txt_nz_h=uicontrol('Style','edit',...
      'Position',[15 110 150 20],...
      'String',S);
   
   m_pr_sl_nz_h=uicontrol('Style','slider',...
      'Position',[175 110 110 20],...
      'String','Number of zeros',...
      'Max',max_nz,...
      'Min',min_nz,...
      'Value', num_zeros,...
      'Callback','pr_nz');
   
   
   m_pr_cb_pzplot_h=uicontrol('Style','checkbox',...
      'Position',[15 70 130 20],...
      'String','Pole-Zero plot',...
      'Value',pzplot_flag);
   
   m_pr_cb_spec_h=uicontrol('Style','checkbox',...
      'Position',[155 70 130 20],...
      'String','Spectrum',...
      'Value',spec_flag);
   
   m_pr_pb_save_h=uicontrol('Style','pushbutton',...
      'Position',[15 20 80 30],...
      'String','OK',...
      'Callback','pr_ok');
   
   m_pr_pb_cancel_h=uicontrol('Style','pushbutton',...
      'Position',[105 20 80 30],...
      'String','Cancel',...
      'Callback','pr_canc');
end;

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?