Skip to content

Commit

Permalink
Update documentation on the Linux console
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberShadow committed Nov 10, 2017
1 parent e692887 commit c6012a8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ You can configure it for `term-keys` as follows:
$ sudo loadkeys ~/term-keys.keymap
```

To reset the layout to the default one, run `sudo loadkeys -d`.

You will need to invoke `loadkeys` after every boot; alternatively, on
systemd distributions, you can add a `KEYMAP=` line to
`/etc/vconsole.conf`.
Expand All @@ -233,6 +235,8 @@ You can customize some settings affecting the generated `.keymap` files using th
Note that the `.keymap` files generated by `term-keys/linux-keymap` assume a QWERTY keyboard layout.
If you use another layout (AZERTY, Dvorak, Colemak...), you will need to customize `term-keys/mapping` and set the alphanumeric keynumbers accordingly.

Note also that Linux has a limitation on the number of customized keys. Custom key strings need to be assigned to "function keys", for which there are 256 slots by default (which includes the default strings for the F-keys and some other keys like Insert/Delete). This leaves about 234 slots for `term-keys`, which is sufficient for the default configuration, but may not be sufficient for a custom one, especially if you enable support for additional modifiers.

### st

[st](https://st.suckless.org/) is configured by editing its `config.h` and recompiling. The key sequences can be configured in this way as well.
Expand Down
2 changes: 1 addition & 1 deletion term-keys-linux.el
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ keyboard). Although most PC keyboards today only have 12
function keys, some keyboards/computers had more, and (also for
the purposes of key binding) the Linux kernel allows registering
character sequences for as many as 246 function keys (see output
for 'loadkeys -l' for the exact figure on your machine).
for 'dumpkeys -l' for the exact figure on your machine).
Crucially, these virtual keys provide the means to configure
arbitrary character sequences for any key combination, which is
necessary for term-keys to work.
Expand Down

0 comments on commit c6012a8

Please sign in to comment.