Mercurial > hg > octave-nkf
comparison scripts/plot/patch.m @ 13247:e36c2f4ea8f5
Set clim correctly for patch objects:
src/graphics.cc: (update_axis_limits): set min_val correctly.
scripts/plot/patch.m: test for this fix.
author | Kai Habel <kai.habel@gmx.de> |
---|---|
date | Thu, 29 Sep 2011 12:31:39 +0200 |
parents | e81ddf9cacd5 |
children | e9f6a6edec42 |
comparison
equal
deleted
inserted
replaced
13246:0c69a564f2be | 13247:e36c2f4ea8f5 |
---|---|
170 %! assert (get (h, "marker"), get (0, "defaultpatchmarker")); | 170 %! assert (get (h, "marker"), get (0, "defaultpatchmarker")); |
171 %! assert (get (h, "markersize"), get (0, "defaultpatchmarkersize")); | 171 %! assert (get (h, "markersize"), get (0, "defaultpatchmarkersize")); |
172 %! unwind_protect_cleanup | 172 %! unwind_protect_cleanup |
173 %! close (hf); | 173 %! close (hf); |
174 %! end_unwind_protect | 174 %! end_unwind_protect |
175 | |
176 %!test | |
177 %! hf = figure ("visible", "off"); | |
178 %! c = 0.9; | |
179 %! unwind_protect | |
180 %! h = patch ([0 1 0], [0 1 1], c); | |
181 %! assert (get (gca, "clim"), [c - 1, c + 1]); | |
182 %! h = patch ([0 1 0], [0 1 1], 2 * c); | |
183 %! assert (get (gca, "clim"), [c, 2 * c]); | |
184 %! unwind_protect_cleanup | |
185 %! close (hf); | |
186 %! end_unwind_protect |