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

Re: *print-lines* etc during apropos printout



    Date: Mon, 10 Feb 92 20:19:12 GMT
    From: Miles Bader <miles@cogsci.edinburgh.ac.uk>
    
    I think it would be a good thing to bind *print-lines*, *print-length*, etc.,
    to reasonable values (or maybe have an *aprops-print-lines*) while apropos
    is printing out...

I'll take this opportunity to plug my version of APROPOS, inspired by
the TICL version.  At the end of this message, the doc-string for
APROPOS followed by the list of ``short cut'' functions that are
defined by /usr/rfb/lisp/apropos.lisp on h.gp.cs.cmu.edu.

It supports the following customization variables:
 *apropos-default-duplicates*
 *apropos-default-inherited*
 *apropos-default-internal*
 *apropos-default-keywords*
 *apropos-default-sorted*
 *apropos-line-length*
 *apropos-print-case*

Caveat:  It doesn't know about XP.

It's portable (I've compiled and run in it CMUCL, Lucid, Allegro, TICL
and Symbolics CL).  It compiles in Python version 1.0(15a), VM version
SPARCstation/Sun 4 (from CMUCL 15a), without errors.  The only
warnings involve redefining APROPOS and APROPOS-LIST.  It's optimizes
speed in common situations at the expense of code size.

The source is in the public domain.  If you don't have access and
would like it, send me mail.

			Rick


------------------------- APROPOS doc string -------------------------

APROPOS (Pattern &optional Package &key Print Result Boundp Fboundp
    Key Test Test-Not Duplicates Internal Inherited Keywords Sorted)

PATTERN may be either a suitable argument to STRING or a list of patterns.
PACKAGE may be a package, a suitable argument to STRING that names
  a package, or a list of packages and/or names.
PRINT, RESULT, BOUNDP, FBOUNDP, INTERNAL, INHERITED, DUPLICATES and KEYWORDS
  may be any lisp object.
KEY may either be NIL or a function that accepts a single symbol argument.
TEST, and TEST-NOT each may be either NIL or a function that accepts a
  single argument which will be the result of calling KEY on a symbol or a
  symbol if KEY is not specified.

APROPOS returns no values unless RESULT is specified in which case it
  returns a list of the matching symbols, where ``matching'' is defined as
  meeting all of the following conditions:
    If PATTERN is a suitable argument to STRING, its string must be a
      subsequence of the symbol's name with respect to #'CHAR-EQUAL.
    If PATTERN is a list of sub-patterns, each of the sub-patterns must
      match.  If, in turn, one of the sub-patterns is a list of patterns,
      one of those patterns must match.  This and/or nesting may be
      arbitrarily deep.
    If PACKAGE is specified, the symbol must exist in (one of) the package(s).
    When neither BOUNDP nor FBOUNDP are NIL, the symbol must satisfy one of
      the predicates #'BOUNDP and #'FBOUNDP.
    When BOUNDP is NIL and FBOUNDP is not, the symbol must satisfy the
      predicate #'FBOUNDP.
    Unless FBOUNDP is NIL and BOUNDP is not, the symbol must satisfy the
      predicate #'BOUNDP.
    If TEST is specified, it must return something other than NIL when
      called on the symbol, or on the result of calling KEY on the symbol
      when KEY is specified.
    If TEST-NOT is specified, it must return NIL when called on the symbol,
      or on the result of calling KEY on the symbol when KEY is specified.
    Unless DUPLICATES is NIL, the symbol must not have matched previously.
    If KEYWORDS is NIL and the :PACKAGE argument is not specified as being the
      KEYWORD package, the symbol must not be in the KEYWORD package.

As a side effect, unless PRINT is NIL, a short description of each
  matching symbol will be printed."

------------------------- APROPOS short cuts -------------------------

;;;    Function:         Print    Result    BoundP    FBoundP
;;;      APROPOS           T        NIL       NIL       NIL
;;;      APROPOS-LIST     NIL        T        NIL       NIL
;;;      APROPOSB          T        NIL        T        NIL
;;;      APROPOSB-LIST    NIL        T         T        NIL
;;;      APROPOSBF         T        NIL        T         T
;;;      APROPOSBF-LIST   NIL        T         T         T
;;;      APROPOSF          T        NIL       NIL        T
;;;      APROPOSF-LIST    NIL        T        NIL        T
;;;      APROPOSFB         T        NIL        T         T
;;;      APROPOSFB-LIST   NIL        T         T         T