comparison scripts/plot/appearance/axis.m @ 18468:0bfa7798c496

imported patch axis
author Rik <rik@octave.org>
date Sat, 15 Feb 2014 20:09:32 -0800
parents d63878346099
children 00d684465379
comparison
equal deleted inserted replaced
18467:c5a101de2d88 18468:0bfa7798c496
195 ## The following line is a trick used to trigger the recalculation of 195 ## The following line is a trick used to trigger the recalculation of
196 ## aspect related magnitudes even if the aspect ratio is the same 196 ## aspect related magnitudes even if the aspect ratio is the same
197 ## (useful with the x11 gnuplot terminal after a window resize) 197 ## (useful with the x11 gnuplot terminal after a window resize)
198 set (ca, "dataaspectratiomode", "auto"); 198 set (ca, "dataaspectratiomode", "auto");
199 endif 199 endif
200 set (ca, "dataaspectratio", [1, 1, 1]); 200 set (ca, "dataaspectratio", [1, 1, 1], "plotboxaspectratio", [5 4 4]);
201
201 elseif (strcmpi (ax, "normal")) 202 elseif (strcmpi (ax, "normal"))
202 set (ca, "plotboxaspectratio", [1, 1, 1]); 203 ## Set plotboxaspectratio to something obtuse so that switching
203 set (ca, "plotboxaspectratiomode", "auto"); 204 ## back to "auto" will force a re-calculation.
205 set (ca, "plotboxaspectratio", [3 2 1]);
206 set (ca, "plotboxaspectratiomode", "auto",
207 "dataaspectratiomode", "auto");
204 208
205 ## axis limits 209 ## axis limits
206 elseif (len >= 4 && strcmpi (ax(1:4), "auto")) 210 elseif (len >= 4 && strcmpi (ax(1:4), "auto"))
207 if (len > 4) 211 if (len > 4)
208 if (any (ax == "x")) 212 if (any (ax == "x"))