octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave 2.9.18 available for ftp


From: John W. Eaton
Subject: Re: Octave 2.9.18 available for ftp
Date: Wed, 05 Dec 2007 15:50:36 -0500

On  5-Dec-2007, Michael Goffioul wrote:

| I just updated the CVS a couple a minutes ago (the octave version is
| still 2.9.18) and noticed I can't build the doc anymore: interpimages
| cannot create text version of plots. It fails with error:
| 
| Paramètre non valide - 'txt:interpft.txt'
| error: print: could not convert
| error: evaluating if command near line 385, column 5
| error: evaluating if command near line 381, column 3
| error: called from `print' in file
| `C:\Software\VCLibs\local\octave-vc8-debug\share\octave\2.9.18\m\plot\print.m'
| error: evaluating if command near line 24, column 3
| error: called from `interpimages' in file
| `C:\Sources\playground\c\octave-cvs\doc\interpreter\interpimages.m'
| 
| Basically, "interpimages" calls "print" with -dtxt argument and "print"
| tries to call "convert", because txt is not a know device. "convert" is
| not available, then the build fails.

Oops, please try the following patch.

jwe


doc/ChangeLog:

2007-12-05  John W. Eaton  <address@hidden>

        * interpreter/geometryimages.m (image_as_txt): New function.
        Use it to generate "figures" for Info format.
        * interpreter/interpimages.m: Likewise.
        * interpreter/sparseimages.m: Likewise.


Index: doc/interpreter/geometryimages.m
===================================================================
RCS file: /cvs/octave/doc/interpreter/geometryimages.m,v
retrieving revision 1.6
diff -u -u -r1.6 geometryimages.m
--- doc/interpreter/geometryimages.m    5 Dec 2007 01:18:41 -0000       1.6
+++ doc/interpreter/geometryimages.m    5 Dec 2007 20:49:29 -0000
@@ -26,6 +26,8 @@
          || strcmp (nm, "convhull") || strcmp (nm, "delaunay")
          || strcmp (nm, "triplot")))
     sombreroimage (nm, typ);
+  elseif (strcmp (typ, "txt"))
+    image_as_txt (nm);
   elseif (strcmp (nm, "voronoi"))
     rand("state",9);
     x = rand(10,1);
@@ -194,3 +196,13 @@
     end_unwind_protect
   endif
 endfunction
+
+## generate something for the texinfo @image command to process
+function image_as_txt(nm)
+  fid = fopen (sprintf ("%s.txt", nm), "wt");
+  fputs (fid, "\n");
+  fputs (fid, "+---------------------------------+\n");
+  fputs (fid, "| Image unavailable in text mode. |\n");
+  fputs (fid, "+---------------------------------+\n");
+  fclose (fid);
+endfunction
Index: doc/interpreter/interpimages.m
===================================================================
RCS file: /cvs/octave/doc/interpreter/interpimages.m,v
retrieving revision 1.5
diff -u -u -r1.5 interpimages.m
--- doc/interpreter/interpimages.m      5 Dec 2007 01:18:41 -0000       1.5
+++ doc/interpreter/interpimages.m      5 Dec 2007 20:49:29 -0000
@@ -21,7 +21,9 @@
   if (strcmp (typ, "png"))
     set (0, "defaulttextfontname", "*");
   endif
-  if (strcmp (nm, "interpft"))
+  if (strcmp (typ, "txt"))
+    image_as_txt (nm);
+  elseif (strcmp (nm, "interpft"))
     t = 0 : 0.3 : pi; dt = t(2)-t(1);
     n = length (t); k = 100;
     ti = t(1) + [0 : k-1]*dt*n/k;
@@ -74,3 +76,13 @@
   f = figure (1);
   set (f, "visible", "off");
 endfunction
+
+## generate something for the texinfo @image command to process
+function image_as_txt(nm)
+  fid = fopen (sprintf ("%s.txt", nm), "wt");
+  fputs (fid, "\n");
+  fputs (fid, "+---------------------------------+\n");
+  fputs (fid, "| Image unavailable in text mode. |\n");
+  fputs (fid, "+---------------------------------+\n");
+  fclose (fid);
+endfunction
Index: doc/interpreter/sparseimages.m
===================================================================
RCS file: /cvs/octave/doc/interpreter/sparseimages.m,v
retrieving revision 1.9
diff -u -u -r1.9 sparseimages.m
--- doc/interpreter/sparseimages.m      5 Dec 2007 01:18:41 -0000       1.9
+++ doc/interpreter/sparseimages.m      5 Dec 2007 20:49:29 -0000
@@ -262,3 +262,13 @@
     end_unwind_protect
   endif
 endfunction
+
+## generate something for the texinfo @image command to process
+function image_as_txt(nm)
+  fid = fopen (sprintf ("%s.txt", nm), "wt");
+  fputs (fid, "\n");
+  fputs (fid, "+---------------------------------+\n");
+  fputs (fid, "| Image unavailable in text mode. |\n");
+  fputs (fid, "+---------------------------------+\n");
+  fclose (fid);
+endfunction

reply via email to

[Prev in Thread] Current Thread [Next in Thread]