Re: spanish/portuguese translations and texinfo tools



Hi Vadim,

About using the usual POSIX locale mechanism, that sounds 
great to me. I'm initially mostly interested in the info output
as used by describe. Can you outline the changes that would
be necessary to make describe and/or cl-info aware of locale-
specific info files?

On a related note here is a patch for $DESCRIBE which employs
a variable *MAXIMA-INFO-FILENAME* instead of a hard-coded
string (namely "maxima.info"). If you patch src/macdes.lisp and then
:lisp (setq *maxima-info-filename* "maxima_pt.info")
:lisp (setq cl-info::*info-paths* '(".../doc/info/pt/"))
(where ... leading up to doc/info/pt is replaced by something suitable)
then you can see the translated documentation for "? describe",
"? save", etc.

At present maxima_pt.info seems to confuse cl-info --
"? foo" seems to print everything from foo to the end of the file.

I also tried setting the filename and path to maxima.es.info and 
.../doc/info/es/, but ? returns nothing for items that should be there
(e.g., save, describe), and returns some confused text in other
cases (e.g. tex). 

Anyway this patch might be something others would enjoy trying out.

For what it's worth,
Robert Dodier

------------------------------ cut here ------------------------------
--- macdes.lisp 31 May 2005 02:56:24 -0000      1.23
+++ macdes.lisp 13 Jul 2005 03:14:15 -0000
@@ -127,12 +127,14 @@
 ;; tex, or viewed using info or gnu emacs or using a web browser.  All
 ;; versions of maxima have a builtin info retrieval mechanism.
 
+(defvar *maxima-info-filename* "maxima.info")
+
 (defmspec $describe (x)
   (setq x ($sconcat (cadr x)))
   (let ((cl-info::*prompt-prefix* *prompt-prefix*)
        (cl-info::*prompt-suffix* *prompt-suffix*))
     #-gcl
-    (cl-info:info x '("maxima.info") cl-info:*info-paths*)
+    (cl-info:info x (list *maxima-info-filename*) cl-info:*info-paths*)
     ;; Optimization: GCL's built-in info is much faster than our info
     ;; implementation. However, GCL's info won't respect out *prompt-
     ;; variables. Compromise by only calling our info when the prompts
@@ -141,13 +143,13 @@
     ;; GCL's info is not quite compatible (GCL 2.6.6) with recent
     ;; texinfo releases. -- ZW 01-Apr-05
     #+gcl
-    (cl-info:info x '("maxima.info") cl-info:*info-paths*)
+    (cl-info:info x (list *maxima-info-filename*) cl-info:*info-paths*)
     #+nil
     (if (and (string= *prompt-prefix* "") (string= *prompt-suffix* ""))
        (progn
          (setf system::*info-paths* cl-info:*info-paths*)
-         (system::info x '("maxima.info")))
-       (cl-info:info x '("maxima.info") cl-info:*info-paths*))))
+         (system::info x (list *maxima-info-filename*)))
+       (cl-info:info x (list *maxima-info-filename*) cl-info:*info-paths*))))
 
 (defun $apropos ( s ) 
   (cons '(mlist) (apropos-list s "MAXIMA")))