aboutsummaryrefslogtreecommitdiffstats
path: root/config/bindings.go
Commit message (Collapse)AuthorAgeFilesLines
* binds: add account specific bindingsJonathan Bartlett2021-12-111-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using aerc for multiple accounts often bindings might differ slightly between accounts. For example: * Account A archives to one directory (:archive) * Account B archives to monthly directories (:archive month) Add account specific bindings to allow the user to add a "context" to a binding group using a context specifier and a regular expression. Currently the only context specifier is 'account'. The regular expression is validated against the accounts loaded from accounts.conf and the configuration fails to load if there are no matches. Contextual bindings are merged with global bindings, with contextual bindings taking precedence, when that context is active. Bindings are be configured using a generic pattern of 'view:context=regexp'. E.g.: # Globally Applicable Archiving [messages] A = :read<Enter>:archive<Enter> # Monthly Archiving for 'Mailbox' Account [messages:account=Mailbox$] A = :read<Enter>:archive month<Enter> In the above example all accounts matching the regular expression will archive in the monthly format - all others will use the global binding. Signed-off-by: Jonathan Bartlett <jonathan@jonnobrow.co.uk>
* bindings: support more modified keysRobin Jarry2021-10-281-4/+11
| | | | | | | | | | | | | | Add new supported keys: Ctrl+Enter Ctrl+Up Ctrl+Down Ctrl+Left Ctrl+Right Ctrl+PageUp Ctrl+PageDown Signed-off-by: Robin Jarry <robin@jarry.cc>
* bindings: prepare for more modifersRobin Jarry2021-10-281-155/+160
| | | | | | | | | | | | | | | | Prepare to support more modifiers in key bindings. tcell has some premade ctrl-modified keys but not all keys are supported. Other keys must be explicitly checked with a modifier mask. Update the KeyStroke type to carry a modifier mask. Update code accordingly. No functional change. Link: https://github.com/gdamore/tcell/blob/master/key.go#L265-L275 Link: https://github.com/gdamore/tcell/blob/master/key.go#L384-L419 Signed-off-by: Robin Jarry <robin@jarry.cc>
* update tcell to v2 and enable TrueColor supporty0ast2020-12-181-1/+1
| | | | | | | | | Also update to the tcell v2 PaletteColor api, which should keep the chosen theme of the user intact. Note, that if $TRUECOLOR is defined and a truecolor given, aerc will now stop clipping the value to one of the theme colors. Generally this is desired behaviour though.
* all: use fmt.Errorf for fomartting errorsWagner Riffel2019-09-041-1/+1
| | | | Signed-off-by: Wagner Riffel <wgrriffel@gmail.com>
* lowercase all key bindingsReto Brunner2019-07-171-32/+32
|
* Change ex command to C-x when using terminalDrew DeVault2019-05-241-2/+2
|
* Add distinct keybindings for each compose viewDrew DeVault2019-05-141-1/+1
|
* Rig up terminal keybinding groupDrew DeVault2019-03-211-0/+1
|
* Add context-specific keybindingsDrew DeVault2019-03-211-0/+10
|
* Add additional context to key binding setDrew DeVault2019-03-211-4/+14
|
* Fix special key bindings (e.g. <C-d>)Drew DeVault2019-03-151-1/+6
|
* Rig up key bindingsDrew DeVault2019-03-151-156/+156
|
* Implement key bindings subsystemDrew DeVault2019-03-151-0/+284
Which is not yet rigged up