Set up the extended keys. More...
#include "config.h"#include <stdbool.h>#include <strings.h>#include "mutt/lib.h"#include "gui/lib.h"#include "extended.h"Go to the source code of this file.
Data Structures | |
| struct | Extkey |
| Map key names from NeoMutt's style to Curses style. More... | |
Functions | |
| const char * | ext_key_find (const char *key) |
| Find the curses name for a key. | |
| void | ext_keys_init (struct Mapping *key_names) |
| Initialise map of ncurses extended keys. | |
Variables | |
| static const struct Extkey | ExtKeys [] |
| Mapping between NeoMutt and Curses key names. | |
Set up the extended keys.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file extended.c.
| const char * ext_key_find | ( | const char * | key | ) |
Find the curses name for a key.
| key | Key name |
| ptr | Curses name |
Look up NeoMutt's name for a key and find the ncurses extended name for it.
Definition at line 93 of file extended.c.
| void ext_keys_init | ( | struct Mapping * | key_names | ) |
Initialise map of ncurses extended keys.
| key_names | Array of key name/value mappings to populate |
Determine the keycodes for ncurses extended keys and fill in the KeyNames array.
This function must be called after initscr(), or mutt_tigetstr() fails. This creates a bit of a chicken-and-egg problem because km_init() is called prior to start_curses(). This means that the default keybindings can't include any of the extended keys because they won't be defined until later.
Definition at line 114 of file extended.c.
|
static |
Mapping between NeoMutt and Curses key names.
Definition at line 48 of file extended.c.