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

documentation strings and records



Eyvind Ness writes:

    What I want is a programmatic interface to the CP command "Show
    Documentation".

As you know from the responses so far, the DOCUMENTATION function
retrieves a documentation string and the "Show Documentation" command
displays a record from the documentation database. (Another command,
"Show Definition Documentation", retrieves a documentation string OR
directs you to the online documentation.)

In regards to a programmatic interface to "Show Documentation", if you
wanted to display the documentation for the DOCUMENTATION function, you
could use

(sage::lookup-manual-internal
  (sage:find-record-group-for-topic-and-type 'documentation 'function))

If you wanted to print the documentation, you could provide a printer
object as the second argument to SAGE::LOOKUP-MANUAL-INTERNAL.

Note that Lisp objects can be provided as symbols, whereas other topics
must be provided in quotation marks, e.g.,

(sage::lookup-manual-internal
  (sage:find-record-group-for-topic-and-type
    "How documentation is stored" "section"))

John Krieger (s9274@srl1.lanl.gov)
Westinghouse Savannah River Company