diff libinterp/corefcn/graphics.cc @ 17024:c358c6e7416b

Add test to graphics.cc for initial tightinset value. libinterp/corefcn/graphics.cc: Add test for the initial values of tightinset.
author Ben Abbott <bpabbott@mac.com>
date Sat, 20 Jul 2013 14:12:14 -0400
parents 350cad34b0f8
children 86067af51d5e
line wrap: on
line diff
--- a/libinterp/corefcn/graphics.cc	Sat Jul 20 10:56:24 2013 -0400
+++ b/libinterp/corefcn/graphics.cc	Sat Jul 20 14:12:14 2013 -0400
@@ -4028,6 +4028,28 @@
     update_outerposition ();
 }
 
+/*
+%!xtest
+%! unwind_protect
+%!   hf = figure (gcf (), "__graphics_toolkit__", "fltk", "visible", "off");
+%!   clf;
+%!   subplot(2,1,1); plot(rand(10,1)); subplot(2,1,2); plot(rand(10,1))
+%!   hax = findall (gcf (), "type", "axes");
+%!   positions = cell2mat (get (hax, "position"));
+%!   outerpositions = cell2mat (get (hax, "outerposition"));
+%!   looseinsets = cell2mat (get (hax, "looseinset"));
+%!   tightinsets = cell2mat (get (hax, "tightinset"));
+%!   subplot(2,1,1); plot(rand(10,1)); subplot(2,1,2); plot(rand(10,1))
+%!   hax = findall (gcf (), "type", "axes");
+%!   assert (cell2mat (get (hax, "position")), positions)
+%!   assert (cell2mat (get (hax, "outerposition")), outerpositions)
+%!   assert (cell2mat (get (hax, "looseinset")), looseinsets)
+%!   assert (cell2mat (get (hax, "tightinset")), tightinsets)
+%! unwind_protect_cleanup
+%!   close (hf);
+%! end_unwind_protect
+*/
+
 void
 axes::properties::set_text_child (handle_property& hp,
                                   const std::string& who,