(axe.info)Minibuffer
How to use the minibuffer
=========================
Commands corresponding to the two *Search:Text* operations plus
*Search:Line*, *Insert:File*, *File:SaveAs* and *File:Load* can be
entered directly into the minibuffer. The command names are styled
after those of the Unix editor ed and are
/regular-expression
?regular-expression
[0-9][0-9]*
r filename
w filename
e filename
In addition pipe and shell commands have been introduced. Their names
are `|' and `!' respectively.
Execution of pipe has the effect of replacing the selected text, if
any, in the editing buffer by the result of filtering by the command
specified in the remainder of the minibuffer. If no text is selected
then the output of running the command specified as the pipe argument
is inserted at the current insertion point.
Execution of shell has the effect of passing the whole buffer or the
selected text to the shell command specified as argument and displaying
the output, if any, of that command in a new aXe window, unless a `>'
occurs in the command, in which case it is assumed that the user wishes
to handle the output themself.
The command names must occur in column 1 of the minibuffer, and
whitespace preceding the argument of `r', `w', `e', `|' and `!'
commands is mandatory.
The minibuffer also recognises actions as commands. Thus it is not
necessary restart aXe with new key bindings to experiment with untried
features or to execute infrequently used actions - simply type them
into the minibuffer, e.g. new-window() [or simply new-window] or
new-window(load).
New action routines have been defined so that the minibuffer can be
enabled from the editing buffer. When they are used the normal editing
buffer translations are suspended and replaced by a minimal set of
editing bindings that take effect in the minibuffer, i.e it is not
necessary to move the mouse into the minibuffer to execute commands in
it. If they are found to be inadequate the mouse can always be moved
into the minibuffer to gain access to full range of Text Widget key
bindings. The names of the action routines are
mini-search
mini-insert
mini-saveas
mini-load
mini-pipe
mini-shell
mini-stuff
mini-search may be given an argument of `forward' or `backward'; the
default is forward. When the command is mini-insert, mini-saveas or
mini-load the minibuffer is initialised with the directory already
associated with the editing buffer. mini-pipe, mini-shell and
mini-stuff may be given arguments with which to initialise the
minibuffer, so frequently used filters and other minibuffer commands
can be set up via user defined key bindings. If the last mini-pipe,
mini-shell or mini-stuff argument ends with `\n' then the command will
be executed right away.
Four other action routines have been defined. They are
mini-clear
mini-select
mini-commit
mini-abort
mini-clear enables and flushes the minibuffer. There is no command
corresponding to *Search:Line* so mini-clear could be bound to a key for
the purpose as it would provide an empty minibuffer awaiting the entry
of a line number. mini-select enables the minibuffer without altering
it, so the previous command can then be repeated by simply hitting the
Return key. mini-commit executes the command in the minibuffer.
mini-abort is defined so that a minibuffer command can be aborted while
the accelerators are in effect. The default minibuffer translations and
accelerators (the bindings that get installed as the editing buffer
translations when the minibuffer is enabled via the above action
routines) have Return bound to mini-commit and mini-abort bound to both
Escape and `Ctrl-g'.
In all cases except mini-search, hitting the Return key causes
reinstatement of the editing buffer translations after execution of the
minibuffer command. The reason for this is so that repeated searches
can be made simply by continuing to hit the Return key. Thus it is
necessary to explicitly abort search operations.
Note that the caret is only displayed in the minibuffer when it is
active, either because the mouse pointer has been moved into it or
because it has been enabled by execution of one of the mini- action
routines, and further that the caret in the editing buffer is disabled
in the latter case, although it won't always be easy to spot that that
has happened.
Here are some typical bindings that might be used
Meta<Key>G: mini-clear()
Ctrl<Key>S: mini-search()
Ctrl<Key>R: mini-search(backward)
Ctrl<Key>X,<Key>B: mini-select()
Ctrl<Key>X,<Key>O: mini-select()
Ctrl<key>X,Ctrl<Key>F: mini-load()
Ctrl<Key>X,Ctrl<Key>I: mini-insert()
Ctrl<Key>X,Ctrl<Key>W: mini-saveas()
Ctrl<Key>X,Ctrl<Key>X: mini-pipe("sed 's/^/> /'\n")
<Key>Print: mini-shell(lpr -Pprinter\n)
The second last example will cause each line of the selected text to be
prefixed by `> ', i.e. it might be used to annotate a section of a mail
message or news article being replied to. It is best to quote the whole
argument to mini-pipe because of the way it would otherwise be split on
spaces and commas. aXe does try to piece the line together again but
can't know whether a split was as a result of a space or a comma; it
always assumes that it was a space.
The last example causes the selected text or the whole of the text in
the editing buffer to be queued for printing by printer `printer'. The
minibuffer menu provides a few ready-made examples that are likely to
be commonly used.
Minimenu- The minibuffer menu
automatically generated by info2www version 1.2.2.9