man mred (Commandes) - The PLT Graphical Scheme implementation
NAME
mred - The PLT Graphical Scheme implementation
SYNOPSIS
mred [ X option ... ] [ option ... ] [ argument ... ]
DESCRIPTION
MrEd is the PLT's graphical Scheme implementation. It embeds and extends MzScheme with a graphical user interface (GUI) toolbox.
DrScheme is the graphical development environment for creating MzScheme and MrEd applications.
X OPTIONS
MrEd accepts the following standard X flags : -display disp, -geometry geom, -bg color, -background color, -fg color, -foreground color, -fn font, -font font, -iconic, -name name, -rv, -reverse, +rv, -selectionTimeout time, -synchronous, -title name, -xnllanguage lang, -xrm file. These flags must appear before all other flags.
STARTUP FILE AND EXPRESSION OPTIONS
- -e expr
- --eval expr
- Evaluates expr after MrEd starts.
- -f file
- --load file
- Loads file after MrEd starts.
- -d file
- --load-cd file
- Load/cds file after MrEd starts.
- -t file
- --require file
- Requires file after MrEd starts.
- -F
- --Load
Loads all remaining arguments after MrEd starts.- -D
- --Load-cd
Load/cds all remaining arguments after MrEd starts.- -T
- --Require
Requires all remaining arguments after MrEd starts.- -l file
- --mzlib file
- Same as -e '(require (lib "c filec "))'.
- -L file coll
- Same as -e '(require (lib "c filec " "c collc "))'.
- -M coll
- Same as -e '(require (lib "c collc .ss" "c collc "))'.
- -r
- --script
- Script mode: use as last flag for scripts. Same as -fmv-.
- -i
- --script-cd
- Like -r, but also sets the directory. Same as -dmv-.
- -u
- --require-script
- Like -r, but requires a module. Same as -tmv-.
- -Z
- --nogui
- Skip "class.ss" and "mred.ss" require.
- -z
- --stdio
- Use stdio REPL. Same as -ve '(read-eval-print-loop)'.
- -w
- --awk
- Same as -l awk.ss.
- -k n m
- Load executable-embedded code from file offset n to m.
- -C
- --main
- Like -r, then calls `main' with a list of argument strings. The first string in the list is the name of the loaded file, and the rest of the list contains leftover command-line arguments.
INITIALIZATION OPTIONS
- -x
- --no-lib-path
- Skips trying to set current-library-collection-paths.
- -q
- --no-init-file
- Skips trying to load "~/.mredrc".
- -A
- --no-argv
- Skips defining `argv' and `program'.
LANGUAGE SETTING OPTIONS
- -g
- --case-sens
- Identifiers and symbols are initially case-sensitive.
- -s
- --set-undef
- Set! works on undefined identifiers.
MISCELLANEOUS OPTIONS
- --
No argument following this switch is used as a switch.- -p
- --persistent
- Catches AIX SIGDANGER (low page space) signal. (AIX only)
- -m
- --mute-banner
- Suppresses -v/--version text.
- -v
- --version
- Suppresses the read-eval-print loop and prints version information.
- -V
- --yield
- Like -v, also suppresses (yield 'wait).
- -h
- --help
- Shows help for command-line arguments and exits, ignoring other switches.
- -Rfile
- --restore file
- Restores an image; must be the only switch. (Special versions only)
OPTION CONVENTIONS
Multiple single-letter switches can be collapsed, with arguments placed after the collapsed switches; the first collapsed switch cannot be --. E.g.: -vfme file expr is the same as -v -f file -m -e expr.
Extra arguments following the last switch are put into the Scheme global variable `argv' as a vector of strings. The name used to start MrEd is put into the global variable `program' as a string.
Extra arguments after a --restore file are returned as a vector of strings to the continuation of the `write-image-to-file' call that created the image.
Expressions/files are evaluated/loaded in order as provided, including calls to main implied by --main, embedded segments loaded by -k, and so on. An uncaught exception during an evaluation/load causes later evaluations/loads to be skipped.
The current-library-collections-paths parameter is automatically set before any expressions/files are evaluated/loaded, unless the -x or --no-lib-path switch is used.
EXECUTABLE NAME
If the executable name has the form scheme-c dialectc , then the command line is effectively prefixed with -qAeC '(require (lib "init.ss" "script-lang" "c dialectc "))' The first actual command-line argument thus serves as the name of a file to load. The file should define main, which is called with the command-line arguments---starting with the loaded file name---as a list of immutable strings.
FILES
The file "~/.mredrc" is loaded before any provided expressions/files are evaluated/loaded, unless the -q or --no-init-file switch is used.
The library collections search path is read from the PLTCOLLECTS environment variable (as a colon-separated list of paths). Wherever the empty path appears appears in PLTCOLLECTS, it is replaced with the default collections directory. If PLTCOLLECTS is not defined, the default collections directory is used as the only element in the search path.
MrEd looks for the default collections directory as one of the following (tried in order):
- The path in the environment variable PLTHOME is checked for a "collects" subdirectory.
- If MrEd was invoked with an absolute pathname, the directory of the invoked executable is checked. If the executable is a link, the directory of the referenced file is also checked, recursively following links. The parent directories and the parent's parent directories are also checked (in case MrEd is in a "bin" directory or a ".bin/c platformc " directory).
- If MrEd is invoked with a relative pathname, the directories in the PATH environment variable containing a file with the name of the program as invoked (usually "MrEd") are checked. Links and parent directories are followed as in the first case.
- The "/usr/local/lib/plt/collects" directory is tried.
FURTHER INFORMATION
For further information on MrEd, please consult the on-line documentation and other information available at
http://www.plt-scheme.org/software/mred/
BUGS
Submit bug reports via http://bugs.plt-scheme.org/ (encouraged) or by e-mail to bugs@plt-scheme.org (discouraged)
AUTHOR
MrEd was implemented by Matthew Flatt (mflatt@plt-scheme.org), Robert Bruce Findler (robby@plt-scheme.org), and John Clements (clements@plt-scheme.org), based on MzScheme.