You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
356 B
Matlab

function figured(figNum)
%Alternative to the "figure" command that does not grab focus unless figure window needs to be created
figHandles = findobj('Type','figure');
if sum(figNum==figHandles)<0.5
%new figure number, so create
figure(figNum);
else
%eisting figure number, so use without giving that figure focus
set(0,'CurrentFigure',figNum);
end