Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent Key Repeat from icewm-keys #175

Open
ninjacatz opened this issue Oct 31, 2024 · 2 comments
Open

Prevent Key Repeat from icewm-keys #175

ninjacatz opened this issue Oct 31, 2024 · 2 comments

Comments

@ninjacatz
Copy link

I've been trying for a while to figure out how to get IceWM keybinds set in the keys file to be single-press rather than repeating. Looking through all of the settings and the manual haven't yielded any information regarding this. Sometimes, you have a keybind that you REALLY don't want to trigger multiple times accidently. Am I missing something or is this not possible? Or maybe I am understanding the issue in the wrong way (it is not the responsibility of the WM)? Thank you

@gijsbers
Copy link
Contributor

gijsbers commented Nov 1, 2024

The XKeyEvent doesn't tell if it was due to a repetition or not. So icewm doesn't have that info.

The xset r command allows to disable repeat for some keys.

In a script you could use the following algorithm:

if [ file7 doesn't exists or the current time minus its modification time is greater than the repetition time ]
then do the work of your keybinding
else don't
fi
touch file7

@ninjacatz
Copy link
Author

Thank you for clarifying this is not an icewm problem. I have been able to wrap the worst offenders in constraints with help from your algorithm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants