1 Language Model
2 Syntactic Forms
3 Datatypes
4 Structures
5 Classes and Objects
6 Units
7 Contracts
8 Pattern Matching
9 Control Flow
10 Concurrency
11 Macros
12 Input and Output
13 Reflection and Security
14 Operating System
15 Memory Management
16 Running PLT Scheme
Bibliography
Index
On this page:
help
Version: 4.0.2

 

16.3 Interactive Help

 (require scheme/help)

The help form documented in this section is provided by the scheme/help and scheme/init libraries, which means that it is available when mzscheme is started with no command-line arguments. It is not provided by scheme or scheme/base.

help

(help id)

(help id #:from module-path)

(help #:search datum ...)

Searches the documentation, and opens a web browser (using the user’s selected browser) to display the results. See net/sendurl for information on how the user’s browser is launched.

A simple help or (help) form opens this page.

A (help id) form looks for documentation specific to the current binding of id. For example,

  (require net/url)

  (help url->string)

opens a web browser to show the documentation for url->string from the net/url library.

For the purposes of help, a for-label require introduces a binding without actually executing the net/url library – for cases when you want to check documentation, but cannot or do not want to run the providing module.

  (require scheme/gui) ; does not work in mzscheme

  (require (for-label scheme/gui)) ; ok in mzscheme

  (help frame%)

If id has no for-label and normal binding, then help lists all libraries that are known to export a binding for id.

The (help id #:from module-path) variant is similar to (help id), but using only the exports of module-path. (The module-path module is required for-label in a temporary namespace.)

  (help frame% #:from scheme/gui) ; equivalent to the above

The (help #:search datum ...) form performs a general search. Searching uses strings; each string datum is used as-is, and any other form of datum is converted to a string using display. No datum is evaluated as an expression.

For example,

  (help #:search "web browser" firefox)

searches the documentation index for references that include the phrase “web browser” or “firefox.”