gcl-devel
[Top][All Lists]
Advanced

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

[Gcl-devel] Re: [Maxima] function/variable name completion via rlwrap


From: Camm Maguire
Subject: [Gcl-devel] Re: [Maxima] function/variable name completion via rlwrap
Date: 15 Dec 2005 09:04:27 -0500
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Greetings!

Robert Dodier <address@hidden> writes:

> Hi Camm,
> 
> > I see -- you mean maxima and lisp functions in the maxima package,
> > but using lisp like syntax.  This is correct.
> 
> Sorry, I wasn't clear enough. In Maxima built w/ GCL,
> when I type readt<tab> it completes to READTABLE.
> Likewise forma<tab> completes to FORMAT.
> Other strings complete to other symbols in the LISP package.
> It doesn't recognize symbols which exist in Maxima
> (such as $SAVE and $EXPAND) but not in Lisp.
> 
> > Would it be useful to provide a user hook to tailor readline
> > completion from within GCL?
> 
> Well, maybe not, since it wouldn't address readline
> capabilities for other Lisp flavors. But thanks for asking.
> 

Ah yes, I had forgotten about this.  Sometime ago, I put the following
in GCL for maxima's benefit:

 -- Variable: *READLINE-PREFIX*
     Package:SI

     A string implicitly prepended to input text for use in readline
     command completion.  If this string contains one or more colons,
     it is used to specify the default package and internal/external
     setting for searched symbols in the case that the supplied text
     itself contains no explicit package specification.  If this string
     contains characters after the colon(s), or contains no colons at
     all, it is treated as a symbol name prefix.  In this case, the
     prefix is matched first, then the supplied text, and the
     completion returned is relative to the supplied text itself, i.e.
     contains no prefix.  For example, the setting "maxima::$" will
     complete input text "int" according to the internal symbols in the
     maxima package of the form "maxima::$int...", and return
     suggestions to the user of the form "int...".


We could easily turn this into some sort of user callable function,
but even at present, for what it may be worth, you can complete maxima
functions only on top of GCL, AFAICS.

i.e.

:lisp (setq si::*readline-prefix* "maxima::$")

Take care,


> All the best,
> Robert Dodier
> 
> _______________________________________________
> Maxima mailing list
> address@hidden
> http://www.math.utexas.edu/mailman/listinfo/maxima
> 
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah




reply via email to

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