This is a static copy of a profile reportHome
gcf (2137 calls, 0.098 sec)
Generated 05-Aug-2011 13:03:27 using cpu time.
function in file /usr/local/MATLAB/R2011a/toolbox/matlab/graphics/gcf.m
Copy to new window for comparing multiple runs
Parents (calling functions)
Lines where the most time was spent
Line Number | Code | Calls | Total Time | % Time | Time Plot |
27 | h = get(0,'CurrentFigure'); | 2137 | 0.087 s | 88.9% |  |
32 | if isempty(h) | 2137 | 0 s | 0% |  |
All other lines | | | 0.011 s | 11.1% |  |
Totals | | | 0.098 s | 100% | |
Children (called functions)
No childrenCode Analyzer results
No Code Analyzer messages.Coverage results
[ Show coverage for parent directory ]
Total lines in function | 34 |
Non-code lines (comments, blank lines) | 30 |
Code lines (lines that can run) | 4 |
Code lines that did run | 2 |
Code lines that did not run | 2 |
Coverage (did run/can run) | 50.00 % |
Function listing
time calls line
1 function h = gcf()
2 %GCF Get handle to current figure.
3 % H = GCF returns the handle of the current figure. The current
4 % figure is the window into which graphics commands like PLOT,
5 % TITLE, SURF, etc. will draw.
6 %
7 % The handle of the current figure is stored in the root
8 % property CurrentFigure, and can be queried directly using GET,
9 % and modified using FIGURE or SET.
10 %
11 % Clicking on uimenus and uicontrols contained within a figure,
12 % or clicking on the drawing area of a figure cause that
13 % figure to become current.
14 %
15 % The current figure is not necessarily the frontmost figure on
16 % the screen.
17 %
18 % GCF should not be relied upon during callbacks to obtain the
19 % handle of the figure whose callback is executing - use GCBO
20 % for that purpose.
21 %
22 % See also FIGURE, CLOSE, CLF, GCA, GCBO, GCO, GCBF.
23
24 % Copyright 1984-2002 The MathWorks, Inc.
25 % $Revision: 5.17 $ $Date: 2002/04/10 17:07:02 $
26
0.09 2137 27 h = get(0,'CurrentFigure');
28
29 % 'CurrentFigure' is no longer guaranteed to return a figure,
30 % so we might need to create one (because gcf IS guaranteed to
31 % return a figure)
2137 32 if isempty(h)
33 h = figure;
34 end