0

I'm running SwayWM. I set the keyboard repeat delay and rate in ~/.config/sway/config as:

input * repeat_delay 180
input * repeat_rate 50

This works in everything except Qt5 applications. Qt5 applications use their own repeat delay and rate, and it is unaffected by the Sway settings.

How can I change the keyboard repeat delay and rate for Qt5 applications running under Wayland?

1 Answer 1

0

Update 2021-01-23: For some reason it works now. The bug is not marked as fixed and the code hasn't changed, so I don't know what the difference is. But the key repeat is fast now.


I found the source of the problem.

Qt5 is likely using libinput by default on Wayland (I have not confirmed this, but it seems likely). The source for qlibinputkeyboard.cpp contains hard-coded repeat settings:

const int REPEAT_DELAY = 500;
const int REPEAT_RATE = 100;

// ...

m_repeatTimer.setInterval(REPEAT_DELAY);
m_repeatTimer.start();

Yup, Qt5 with libinput implements its own repeat using its own hard-coded settings.

So, it seems that, to avoid this, it is necessary to either:

  1. Configure Qt5 to use something other than libinput (not sure how to do this); or
  2. Fix qlibinputkeyboard.cpp.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .