
Untitled
By: a guest on
May 9th, 2012 | syntax:
None | size: 0.63 KB | hits: 23 | expires: Never
How to find out how many figures are currently opened?
numel(get(0,'Children'));
function h = findobjhelper( varargin )
%Copyright 2009-2010 The MathWorks, Inc.
allowHVHandles = true;
nin = nargin;
rootHandleVis = builtin( 'get', 0, 'ShowHiddenHandles' );
% See if 'flat' keyword is present
hasflat = false;
if (nin > 1)
if strcmp( varargin{2}, 'flat' ) % Does the 'flat' keyword exist
hasflat = true;
end
end
if nin == 0
if feature('HgUsingMatlabClasses')
h = findobjinternal( 0, '-function', @findobjfilter );
else
h = findobjinternal(0);
end
length(findobj('Type','figure'))