Mercurial > hg > octave-lyh
diff scripts/plot/__axis_label__.m @ 8557:ab82e19002c4
better compatibility for axis label properties
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 21 Jan 2009 14:30:41 -0500 |
parents | d81caf2e3a28 |
children | 7d48766c21a5 |
line wrap: on
line diff
--- a/scripts/plot/__axis_label__.m +++ b/scripts/plot/__axis_label__.m @@ -23,16 +23,18 @@ function retval = __axis_label__ (caller, txt, varargin) if (ischar (txt)) - ## FIXME -- should be able to use text instead of __go_text__. ca = gca (); - h = __go_text__ (ca, "fontangle", get (ca, "fontangle"), - "fontname", get (ca, "fontname"), - "fontsize", get (ca, "fontsize"), - "fontunits", get (ca, "fontunits"), - "fontweight", get (ca, "fontweight"), - "string", txt, varargin{:}); - set (ca, caller, h); + h = get (gca (), caller); + + set (h, "fontangle", get (ca, "fontangle"), + "fontname", get (ca, "fontname"), + "fontsize", get (ca, "fontsize"), + "fontunits", get (ca, "fontunits"), + "fontweight", get (ca, "fontweight"), + "string", txt, + varargin{:}); + if (nargout > 0) retval = h; endif