Mercurial > hg > octave-lyh
changeset 10911:da90c16fbe84
__go_draw_axes__.m: Revert erroneous portion of changeset 10910 40cf7cc4ea62.
author | Ben Abbott <bpabbott@mac.com> |
---|---|
date | Wed, 25 Aug 2010 12:36:23 -0400 |
parents | 40cf7cc4ea62 |
children | 9abc67b4bd4f |
files | scripts/ChangeLog scripts/plot/__go_draw_axes__.m |
diffstat | 2 files changed, 12 insertions(+), 11 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,3 +1,8 @@ +2010-08-25 Ben Abbott <bpabbott@mac.com> + + * plot/__go_draw_axes__.m: Revert erroneous portion of changeset + 10910 40cf7cc4ea62. + 2010-08-24 Ben Abbott <bpabbott@mac.com> * plot/private/__actual_axis_position__.m, plot/__go_draw_axes__.m:
--- a/scripts/plot/__go_draw_axes__.m +++ b/scripts/plot/__go_draw_axes__.m @@ -23,7 +23,7 @@ ## Author: jwe -function __go_draw_axes__ (h, plot_stream, enhanced, mono, bg_is_set) +function __go_draw_axes__ (h, plot_stream, enhanced, mono, implicit_margin, bg_is_set) if (nargin >= 4 && nargin <= 6) @@ -51,6 +51,7 @@ else pos = axis_obj.position; endif + pos(1:2) = pos(1:2) - implicit_margin .* [0.75, 0.5]; if (__gnuplot_has_feature__ ("screen_coordinates_for_{lrtb}margin")) if (nd == 2 || all (mod (axis_obj.view, 90) == 0)) x = [1, 1]; @@ -58,14 +59,10 @@ ## 3D plots need to be sized down to fit in the window. x = 1.0 ./ sqrt([2, 2.5]); endif - fprintf (plot_stream, "set tmargin screen %.15g;\n", - pos(2)+pos(4)/2+x(2)*pos(4)/2); - fprintf (plot_stream, "set bmargin screen %.15g;\n", - pos(2)+pos(4)/2-x(2)*pos(4)/2); - fprintf (plot_stream, "set lmargin screen %.15g;\n", - pos(1)+pos(3)/2-x(1)*pos(3)/2); - fprintf (plot_stream, "set rmargin screen %.15g;\n", - pos(1)+pos(3)/2+x(1)*pos(3)/2); + fprintf (plot_stream, "set tmargin screen %.15g;\n", pos(2)+pos(4)/2+x(2)*pos(4)/2); + fprintf (plot_stream, "set bmargin screen %.15g;\n", pos(2)+pos(4)/2-x(2)*pos(4)/2); + fprintf (plot_stream, "set lmargin screen %.15g;\n", pos(1)+pos(3)/2-x(1)*pos(3)/2); + fprintf (plot_stream, "set rmargin screen %.15g;\n", pos(1)+pos(3)/2+x(1)*pos(3)/2); else ## FIXME -- nothing should change for gnuplot 4.2.x. fprintf (plot_stream, "set tmargin 0;\n"); @@ -104,8 +101,7 @@ fprintf (plot_stream, "set title \"%s\" %s %s", undo_string_escapes (tt), fontspec, __do_enhanced_option__ (enhanced, t)); - if (nd == 3 - && __gnuplot_has_feature__ ("screen_coordinates_for_{lrtb}margin")) + if (nd == 3 && __gnuplot_has_feature__ ("screen_coordinates_for_{lrtb}margin")) fprintf (plot_stream, " offset screen 0, screen %.3f;\n", pos(4)/5); else fprintf (plot_stream, ";\n");