mirror of
https://github.com/niri-wm/niri.git
synced 2026-06-24 02:01:18 +07:00
Change default repeat to 600
660 comes from Xorg, but feels kind of slow. The wlroots and sway default is 600, which is a little better. The 25 repeat interval matches between Xorg (where it is defined in terms of interval, rather than rate) and wlroots.
This commit is contained in:
@@ -3,14 +3,6 @@
|
|||||||
|
|
||||||
input {
|
input {
|
||||||
keyboard {
|
keyboard {
|
||||||
// Control the repeat rate of the keyboard.
|
|
||||||
|
|
||||||
// Repeat delay in milliseconds.
|
|
||||||
repeat-delay 660
|
|
||||||
|
|
||||||
// Repeat rate in characters per second.
|
|
||||||
repeat-rate 25
|
|
||||||
|
|
||||||
xkb {
|
xkb {
|
||||||
// You can set rules, model, layout, variant and options.
|
// You can set rules, model, layout, variant and options.
|
||||||
// For more information, see xkeyboard-config(7).
|
// For more information, see xkeyboard-config(7).
|
||||||
@@ -19,6 +11,11 @@ input {
|
|||||||
// layout "us,ru"
|
// layout "us,ru"
|
||||||
// options "grp:win_space_toggle,compose:ralt,ctrl:nocaps"
|
// options "grp:win_space_toggle,compose:ralt,ctrl:nocaps"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// You can set the keyboard repeat parameters. The defaults match wlroots and sway.
|
||||||
|
// Delay is in milliseconds before the repeat starts. Rate is in characters per second.
|
||||||
|
// repeat-delay 600
|
||||||
|
// repeat-rate 25
|
||||||
}
|
}
|
||||||
|
|
||||||
// Next sections contain libinput settings.
|
// Next sections contain libinput settings.
|
||||||
|
|||||||
+4
-5
@@ -30,10 +30,9 @@ pub struct Input {
|
|||||||
pub struct Keyboard {
|
pub struct Keyboard {
|
||||||
#[knuffel(child, default)]
|
#[knuffel(child, default)]
|
||||||
pub xkb: Xkb,
|
pub xkb: Xkb,
|
||||||
// The default value represents the one used by Xorg.
|
// The defaults were chosen to match wlroots and sway.
|
||||||
#[knuffel(child, unwrap(argument), default = 660)]
|
#[knuffel(child, unwrap(argument), default = 600)]
|
||||||
pub repeat_delay: u16,
|
pub repeat_delay: u16,
|
||||||
// The default value represents the one used by Xorg.
|
|
||||||
#[knuffel(child, unwrap(argument), default = 25)]
|
#[knuffel(child, unwrap(argument), default = 25)]
|
||||||
pub repeat_rate: u8,
|
pub repeat_rate: u8,
|
||||||
}
|
}
|
||||||
@@ -250,7 +249,7 @@ mod tests {
|
|||||||
r#"
|
r#"
|
||||||
input {
|
input {
|
||||||
keyboard {
|
keyboard {
|
||||||
repeat-delay 660
|
repeat-delay 600
|
||||||
repeat-rate 25
|
repeat-rate 25
|
||||||
xkb {
|
xkb {
|
||||||
layout "us,ru"
|
layout "us,ru"
|
||||||
@@ -285,7 +284,7 @@ mod tests {
|
|||||||
options: Some("grp:win_space_toggle".to_owned()),
|
options: Some("grp:win_space_toggle".to_owned()),
|
||||||
..Default::default()
|
..Default::default()
|
||||||
},
|
},
|
||||||
repeat_delay: 660,
|
repeat_delay: 600,
|
||||||
repeat_rate: 25,
|
repeat_rate: 25,
|
||||||
},
|
},
|
||||||
touchpad: Touchpad {
|
touchpad: Touchpad {
|
||||||
|
|||||||
Reference in New Issue
Block a user