dohome.m

来自「任意边界结构正交曲线网格生成程序」· M 代码 · 共 40 行

M
40
字号
function theResult = dohome(self, varargin)% ps/dohome -- Set controls to "home" values.%  dohome(self) sets the controls associated with%   self, a "ps" object, to their "home" value.%   For sliders, this "Value" is midway between%   the "Min" and "Max" properties.%% Note: this routine also needs to force the figure%  to update itself. % Copyright (C) 1999 Dr. Charles R. Denham, ZYDECO.%  All Rights Reserved.%   Disclosure without explicit written consent from the%    copyright owner does not constitute publication. % Version of 10-Dec-1999 01:08:11.% Updated    10-Dec-1999 14:27:28.if nargout > 0, theResult = []; endif nargin < 1, help(mfilename), return, endtheSliders = findobj(handle(self), 'Type', 'uicontrol', ...							'Style', 'slider');					for i = 1:length(theSliders)	theMin = get(theSliders(i), 'Min');	theMax = get(theSliders(i), 'Max');	set(theSliders(i), 'Value', mean([theMin theMax]))endaxis tightset(gca, 'CLimMode', 'auto')if nargout > 0	theResult = self;else	assignin('caller', 'ans', self)end

⌨️ 快捷键说明

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