bind package:brick

Binding constructor.
Construct a Binding. Modifier order is ignored. If modifiers are given and the binding is for a character key, it is forced to lowercase.
A key binding. The easiest way to express Bindings is to use the helper functions in this module that work with instances of ToBinding, e.g.
let ctrlB = ctrl 'b'
shiftX = shift 'x'
ctrlMetaK = ctrl $ meta 'k'
-- Or with Vty keys directly:
ctrlDown = ctrl KDown
Bind the event to the specified list of bindings.
An explicit configuration of key bindings for a key event.
The re-exporting catch-all module for the customizable keybindings API. To get started using this API, see the documentation in KeyDispatcher as well as the User Guide section on customizable keybindings.
The class of types that can form the basis of Bindings. This is provided to make it easy to write and modify bindings in less verbose ways.
Return all active key bindings for the specified event. This returns customized bindings if any have been set in the KeyConfig, no bindings if the event has been explicitly set to Unbound, or the default bindings if the event is absent from the customized bindings.
Returns the list of default bindings for the specified event, irrespective of whether the event has been explicitly configured with other bindings or set to Unbound.
A convenience function to return the first result of allActiveBindings, if any.
A convenience function to return the first result of allDefaultBindings, if any.
Look up the binding state for the specified event. This returns Nothing when the event has no explicitly configured custom BindingState.
The specific key binding that should trigger this handler.
The low-level INI parser for custom key bindings used by this module, exported for applications that use the config-ini package.
Parse custom key bindings from the specified INI file path. This does not catch or convert any exceptions resulting from I/O errors. See keybindingsFromIni for details.
Parse custom key bindings from the specified INI file using the provided event name mapping. Each line in the specified section can take the form
<event-name> = <"unbound"|[binding,...]>
where the event name must be a valid event name in the specified KeyEvents and each binding is valid as parsed by parseBinding. Returns Nothing if the named section was not found; otherwise returns a (possibly empty) list of binding states for each event in evs.
Parse a key binding string. Key binding strings specify zero or more modifier keys and a base key, separated by hyphens.
(modifier "-")* key
e.g. c-down, backspace, ctrl-shift-f1. where each modifier is parsed case-insensitively as follows: and key is parsed case-insensitively as follows:
Parse a key binding list into a BindingState. A key binding list either the string "unbound" or is a comma-separated list of Bindings parsed with parseBinding.
The attribute for keybinding lists in keybinding help Widgets.
The base attribute for Widget keybinding help.
Build a Widget displaying key binding information for a single related group of event handlers. This is provided for convenience so that basic help text for the application's event handlers can be produced and embedded in the UI. The resulting widget lists the key events (and keys) bound to the specified handlers, along with the events' names and the list of available key bindings for each handler.
Generate a Markdown document of sections indicating the key binding state for each event handler.
Generate a plain text document of sections indicating the key binding state for each event handler.
Pretty-print a Binding in the same format that is parsed by parseBinding.