Skip to content

kozikow/keyremaplinux

Repository files navigation

Introduction

Define your keyboard layout as C++ class. Primarily focused on implementing my keyboard layout.

Why use it instead of xmodmap/xcape

Installation

Build keyremaplinux

git clone https://github.com/kozikow/keyremaplinux ~/keyremaplinux
cd ~/keyremaplinux
bazel build //keyremaplinux

Running on Linux

Run one-of:

sudo nice -n -20 ./bazel-bin/keyremaplinux/keyremaplinux kozikow_standard

Enable automatic restarts

sudo cp keyremaplinux.service /etc/systemd/system
sudo systemctl enable keyremaplinux.service
sudo systemctl restart keyremaplinux.service

Implementing the new layout

  1. Extend Remapper and implement function Remap.
  2. For example KozikowLayoutRemapper.
  3. In function Remap, consume and produce Linux input event from input.h. What you consume is what user have typed. What you produce is what OS will see.
  4. Event codes are defined in input-event-codes.h

Run tests

bazel test //keyremaplinux:all --test_output=errors

About

Define your keyboard layout as C++ class.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published