This is a static copy of a profile report

Home

scribe.legend.methods>getsizeinfo (22 calls, 0.083 sec)
Generated 18-Mar-2011 23:32:26 using cpu time.
M-subfunction in file /Applications/MATLAB_R2010a.app/toolbox/matlab/scribe/@scribe/@legend/methods.m
Copy to new window for comparing multiple runs

Parents (calling functions)

Function NameFunction TypeCalls
scribe.legend.methodsM-function2
scribe.legend.methods>getsizeM-subfunction20
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
632
strsizes(k,:) = strsize(h,ppos...
770.062 s75.0%
624
interp = get(ax,'Interpreter')...
220.010 s12.5%
622
fname = get(ax,'fontname'); fs...
220.010 s12.5%
646
out.strsizes = strsizes;
220 s0%
645
laxspace = 5; out.xlaxspace = ...
220 s0%
All other lines  0 s0%
Totals  0.083 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
scribe.legend.methods>strsizeM-subfunction770.062 s75.0%
opaque.doubleM-function220 s0%
Self time (built-ins, overhead, etc.)  0.021 s25.0%
Totals  0.083 s100% 
M-Lint results
Line numberMessage
Coverage results
[ Show coverage for parent directory ]
Total lines in function32
Non-code lines (comments, blank lines)7
Code lines (lines that can run)25
Code lines that did run25
Code lines that did not run0
Coverage (did run/can run)100.00 %
Function listing
   time   calls  line
615 function out = getsizeinfo(h)
616
22 617 parent = get(h,'Parent');
22 618 fig = ancestor(h,'figure');
22 619 ppos = hgconvertunits(fig,get(parent,'Position'),get(parent,'Units'),...
620 'points',get(parent,'Parent'));
22 621 ax = double(h);
0.01 22 622 fname = get(ax,'fontname'); fsize = get(ax,'fontsize');
22 623 fangl = get(ax,'fontangle'); fwght = get(ax,'fontweight');
0.01 22 624 interp = get(ax,'Interpreter');
22 625 strings = h.String;
22 626 if isempty(strings), strings{end+1} = 'data1'; end
627 % get normalized (to figure/overlay) sizes of all strings
22 628 strsizes = ones(length(strings),2);
22 629 for k=1:length(strings)
77 630 str = strings{k};
77 631 if isempty(str), str = 'Onj'; end
0.06 77 632 strsizes(k,:) = strsize(h,ppos,fname,fsize,fangl,fwght,interp,str);
77 633 end
634 % space sizes in/around legend:
635
22 636 topspace = 2; out.topspace = topspace/ppos(4);
22 637 rowspace = 0.5; out.rowspace = rowspace/ppos(4);
22 638 botspace = 2; out.botspace = botspace/ppos(4);
22 639 leftspace = 6; out.leftspace = leftspace/ppos(3);
22 640 rightspace = 3; out.rightspace = rightspace/ppos(3);
22 641 tokentotextspace = 3; out.tokentotextspace = tokentotextspace/ppos(3);
22 642 colspace = 5; out.colspace = colspace/ppos(3);
22 643 out.tokenwidth = h.itemTokenSize(1)/ppos(3);
644 % spaces between legend and axes
22 645 laxspace = 5; out.xlaxspace = laxspace/ppos(3); out.ylaxspace = laxspace/ppos(4);
22 646 out.strsizes = strsizes;

Other subfunctions in this file are not included in this listing.