www.gusucode.com > mbcguitools 工具箱 matlab 源码程序 > mbcguitools/@mvgraph2d/subsref.m

    function out=subsref(gr,s)
%SUBSREF Dot-referencing for mvgraph2d
%   Provides dot referencing interface for mvgraph2d object.  

%  Copyright 2000-2007 The MathWorks, Inc. and Ford Global Technologies, Inc.


% Bail if we've not been given a graph2d object
if ~isa(gr,'mvgraph2d')
   error(message('mbc:mvgraph2d:InvalidObject3'))
end

if length(s)>1 | ~strcmp(s(1).type,'.')
   error(message('mbc:mvgraph2d:InvalidIndex'));
end

out=get(gr,s.subs);