CursorStyle is the style of the cursor
in a given input mode/submode. String - Implements fmt.Stringer.
CursorStyle : expvar.Var
CursorStyle : fmt.Stringer
Engine is used to manage the main and local keymaps for the shell. ActiveCommand returns the sequence/command currently being ran. CancelPending is used by commands that have been registering themselves
as waiting for a pending operator, but have actually been called twice
in a row (eg. dd/yy in Vim mode). This removes those commands from queue. Commands returns the map of all command functions available to the shell.
This includes the builtin commands (emacs/Vim/history/completion/etc), as
well as any functions added by the user through Keymap.Register().
The keys of this map are the names of each corresponding command function. InputIsTerminator returns true when current input keys are one of
the configured or builtin "terminators", which can be configured
in .inputrc with the isearch-terminators variable. IsEmacs returns true if the main keymap is one of the emacs modes. IsPending returns true when invoked from within the command
that also happens to be the next in line of pending commands. Local returns the local keymap. Main returns the local keymap. NonIncrementalSearchStart is used to notify the keymap dispatchers
that are using a minibuffer, and that the set of valid commands
should be restrained to a few ones (self-insert/abort/rubout...). NonIncrementalSearchStop notifies the keymap dispatchers
that we stopped editing a non-incremental search minibuffer. Pending registers a command as waiting for another command to run first,
such as yank/delete/change actions, which accept/require a movement command. PendingCursor changes the cursor to pending mode,
and returns a function to call once done with it. PrintBinds displays a list of currently bound commands (and their sequences)
to the screen. If inputrcFormat is true, it displays it formatted such that
the output can be reused in an .inputrc file. PrintCursor prints the cursor for the given keymap mode,
either default value or the one specified in inputrc file. Register adds command functions to the list of available commands.
Each key of the map should be a unique name, not yet used by any
other builtin/user command, in order not to "overload" the builtins. ReloadConfig parses all valid .inputrc configurations and immediately
updates/reloads all related settings (editing mode, variables behavior, etc.) ResetLocal deactivates the local keymap of the shell. RunPending runs any command with pending execution. SetLocal sets the local keymap of the shell.
Valid builtin keymaps are:
- vi-opp, vi-visual. (used in commands like yank, change, delete, etc.)
- isearch, menu-select (used in search and completion). SetMain sets the main keymap of the shell.
Valid builtin keymaps are:
- emacs, emacs-meta, emacs-ctlx, emacs-standard.
- vi, vi-insert, vi-command, vi-move. UpdateCursor reprints the cursor corresponding to the current keymaps.
func NewEngine(keys *core.Keys, i *core.Iterations, opts ...inputrc.Option) (*Engine, *inputrc.Config)
func MatchLocal(eng *Engine) (bind inputrc.Bind, command func(), prefix bool)
func MatchMain(eng *Engine) (bind inputrc.Bind, command func(), prefix bool)
func github.com/reeflective/readline/internal/completion.NewEngine(h *ui.Hint, km *Engine, o *inputrc.Config) *completion.Engine
func github.com/reeflective/readline/internal/ui.NewPrompt(line *core.Line, cursor *core.Cursor, keymaps *Engine, opts *inputrc.Config) *ui.Prompt
Mode is a root keymap mode for the shell.
To each of these keymap modes is bound a keymap.
func (*Engine).Local() Mode
func (*Engine).Main() Mode
func (*Engine).PrintCursor(keymap Mode)
Package-Level Functions (total 3)
MatchLocal incrementally attempts to match cached input keys against the local keymap.
Returns the bind if matched, the corresponding command, and if we only matched by prefix.
MatchMain incrementally attempts to match cached input keys against the local keymap.
Returns the bind if matched, the corresponding command, and if we only matched by prefix.
NewEngine is a required constructor for the keymap modes manager.
It initializes the keymaps to their defaults or configured values.
Package-Level Constants (total 12)
Editor.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
Completion and search.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
These are the root keymaps used in the readline shell.
Their functioning is similar to how ZSH organizes keymaps.
The pages are generated with Goldsv0.8.2. (GOOS=linux GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds.