From: <and...@us...> - 2010-04-28 22:54:09
|
Revision: 10944 http://plplot.svn.sourceforge.net/plplot/?rev=10944&view=rev Author: andrewross Date: 2010-04-28 22:54:03 +0000 (Wed, 28 Apr 2010) Log Message: ----------- Fix up octave stripc function so that interactive example p11 works (missing call to pladv) Fix up example p12 so that it can by run non-interactively (for example 20) Update test_octave_interactive script so that the device is honoured even for examples which call figure internally. Previously some examples always used xwin, whatever device was called. Update comments on failing xwin and qtwidget examples. Modified Paths: -------------- trunk/bindings/octave/PLplot/stripc.m trunk/examples/octave/p12.m trunk/examples/octave/p20.m trunk/plplot_test/test_octave_interactive.sh.in Modified: trunk/bindings/octave/PLplot/stripc.m =================================================================== --- trunk/bindings/octave/PLplot/stripc.m 2010-04-28 19:49:58 UTC (rev 10943) +++ trunk/bindings/octave/PLplot/stripc.m 2010-04-28 22:54:03 UTC (rev 10944) @@ -48,6 +48,10 @@ colline(3) = 3; colline(4) = 4; + if ( plglevel == 1 ) + pladv(0); + end + id = plstripc("bcnst", "bcnstv", xmin, xmax, xjump, ymin, ymax, __pl.legend_xpos(strm), __pl.legend_ypos(strm), Modified: trunk/examples/octave/p12.m =================================================================== --- trunk/examples/octave/p12.m 2010-04-28 19:49:58 UTC (rev 10943) +++ trunk/examples/octave/p12.m 2010-04-28 22:54:03 UTC (rev 10944) @@ -12,7 +12,7 @@ ## ## This file is part of plplot_octave. -function p12 +function p12(fg) global pl_automatic_replot t = pl_automatic_replot; @@ -23,11 +23,13 @@ x=0:0.1:4; plot(x,exp(x)); text(1,20,"Click Here -> + "); - [x y]=ginput(1); - if (round(x) != 2 || round(y) != 20) - text(x,y,"You missed!") - else - text(x,y,"ouch! Gently!") + if (!nargin) + [x y]=ginput(1); + if (round(x) != 2 || round(y) != 20) + text(x,y,"You missed!") + else + text(x,y,"ouch! Gently!") + endif endif legend("on"); Modified: trunk/examples/octave/p20.m =================================================================== --- trunk/examples/octave/p20.m 2010-04-28 19:49:58 UTC (rev 10943) +++ trunk/examples/octave/p20.m 2010-04-28 22:54:03 UTC (rev 10944) @@ -47,7 +47,7 @@ subwindow(4 ,3) p14(1) subwindow(1 ,2) - p12 + p12(1) subwindow(4, 4) p17(1) oneplot; Modified: trunk/plplot_test/test_octave_interactive.sh.in =================================================================== --- trunk/plplot_test/test_octave_interactive.sh.in 2010-04-28 19:49:58 UTC (rev 10943) +++ trunk/plplot_test/test_octave_interactive.sh.in 2010-04-28 22:54:03 UTC (rev 10944) @@ -58,33 +58,27 @@ # slowness issue # with that device). # The following comments are for -dev qtwidget. -# 11 (many invalid limits); # 12 (hangs); # 14 (looks pretty to start but then segfaults); # 17 (error: plrb: device is not xor capable); -# 18 (pthread_mutex_lock.c:285:) -# 19 (failed to exit properly); -# 20 (failed to exit properly); -# 21 (plot was just dark background) +# 18 (hangs); +# The issues with 12, 17 and 18 are all because qtwidget does not handle plGetCursor # -dev wxwidgets had similar issues except possibly for examples 18 # and 19 which seemed fine, but there is no way to tell for sure with # second wxwidgets example (no matter what) always segfaulting. # -dev xwin worked except for the following: -# 11 (many invalid limits); -# 14 (locked xterm); -# 19 (failed to exit properly); -# 20 (failed to exit properly); -# 21 (plot was just dark background) -# Drop everything that fails to work for -dev xwin except for 21. +# 14 (animation does not work right); -for i=[1:10 12:13 15:18 21]; +plsetopt("dev","$device"); +for i=[1:21]; if (verbose_test) printf("p%d\n",i); endif #figure(i,"$device",sprintf("${OUTPUT_DIR}/p%d%%n.$dsuffix",i)); figure(i,"$device"); + plsetopt("dev","$device"); feval(sprintf("p%d",i)) closefig endfor This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |