LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Desktop (https://www.linuxquestions.org/questions/linux-desktop-74/)
-   -   sticky keys held down to repeat (https://www.linuxquestions.org/questions/linux-desktop-74/sticky-keys-held-down-to-repeat-4175713849/)

Skaperen 06-24-2022 06:30 PM

sticky keys held down to repeat
 
i'm using sticky keys because it makes one handed CLI easier. but, when holding the non-modifier key down to repeat it the modification only applies to the first instance of the repeating sequence. what i would like to have happen is when i press the "Shift" key and release it then press the "z" key and hold it down for a few seconds before releasing it is to get "ZZZZZZZZ" instead of "Zzzzzzzz". what i get now is counter-intuitive to me. i think that the modification should persist until the modified key is released, at least in an extended mode of operation. is this possible to set or enable?

business_kid 06-25-2022 12:16 PM

What you seek is not on the keyboard, but is on the mouse. It's called 'copy & paste' there. In CLI, you can use gpm. Left button to copy, middle button to paste, any other mouse button (except on the taskbar) clears the copied text.

Modifiers allow 4 different characters to be displayed on each key. The usual modifiers are:
  1. No modifier
  2. Shift
  3. Right_Alt
  4. Right_Alt + Shift
Most layouts have some pre-configured, and you can configure more. I've configured a few for my own needs: 4 $ € ¢; = + ≠ ±; x X × ≅; l L ´ ¾; 3 £ © ³; 0 ) º °; etc. But being one handed myself, you have to be careful with the Right_Alt + Shift modifier, as not all keys may be accessible with 2 fingers already committed!

Skaperen 06-25-2022 06:21 PM

i'm finding that modifiers do accumulate. at least i can do Ctrl then Shift then + in xfce4-terminal to increase the font size. it's when i want to repeat that i have trouble if it's something modified like "R" or Ctrl-H.

the other thing i would like is a way to cancel modifiers. if i have pressed a modifier then decide i do not want to press the next thing and press an unmodified key, instead, i can't. if there was a "do nothing even if modified" key, that would solve it. i could press that to use away the modifiers i have pressed.

business_kid 06-26-2022 08:26 AM

The two I mentioned (Shift & Right Alt) are the key modifiers. Outside of that you're into program specific keyboard shortcuts. You're on yopur own there.


There's one other thing I should mention. In the keyboard mods, there 'dead' keys, most often used for accents. I've programmed a few of those, and very handy they are too. You press a dead key, and nothing happens, but you don't move forward a space. The next key you press should be the letter which is to get the accent. So I programmed in a few accents until I started running out of space. I still have to grep the keyboard file (/etc/X11/xkb/symbols/your_choice) occasionally.

Skaperen 06-26-2022 06:24 PM

i do not understand what you mean by "key modifiers". when you say "Shift" do you mean what i would refer to as "Left Shift"?

my /etc/X11/xkb is empty. there is no /etc/X11/xkb/symbols. what could that mean?

jailbait 06-26-2022 06:53 PM

Quote:

Originally Posted by Skaperen (Post 6363325)
what i would like to have happen is when i press the "Shift" key and release it then press the "z" key and hold it down for a few seconds before releasing it is to get "ZZZZZZZZ" instead of "Zzzzzzzz".

You can come close to what you want by using the "Caps Lock" key. The one difference is after the last "Z" you have to hit the "Caps Lock" key again to turn it off.

Skaperen 06-26-2022 07:24 PM

for upper case letters, that is exactly what i do. but that does not work for "$$$$$$$$$". for that i have to hold either Shift key down while repeating the 4/$ key.

business_kid 06-27-2022 06:07 AM

I've got very advanced with the Right_Alt & Shift keys. "$$$$$$$$$" is Left Shift + 4. I got programming before I got thinking, so ¹²³ are achieved by: Clockwise rotation 30°-45° of keyboard; thumb on Right Alt; middle finger on left Shift; Little finger on 1,2,3. That's more than a little insane. You really need a left hand for that sort of thing, but mine doesn't move. It's a battle of wits for us, especially as the numeric keypad doesn't do special characters.

I did manage to document my customised keymap, though.
Code:

`123456      78      90-=
¬!”£$%^      &*      ()_+
¦¡™©€§^(dead)¶”(dead)ªº–≠
123456      78      90-=
 ¹²³¢†‰      ⁊•      ·°—±

qw      ert y u io p[ ]
QW      ERT Y U IO P{ }
œ˙(dead)é®þ ¥ ú íó ‚“ ‘
qw      ert y u io  [ ]
Œ̇˙(dead)É‰Þ µ Ú ÍÓ  ” ’

asdfgh      jk      l ; ‘  #
ASDFGH      JK      L
áßðƒ©˙(dead)ı°(dead)´ … æ  «
asdfgh      j      k  ‘  # 
ÁẞР       ¼½      ¾ ‡  Æ »

\      z xc      v      b      n      m,./       
|      Z XC      V      B      N      M<>?
`(dead)〈 ׸(dead)ˇ(dead)¨(dead)~(dead)¯≤≥÷
\      z xc      v      b      n      m,./       
´(dead)  ≅¸                            „‚¿

The lines are:
  1. No modifiers pressed
  2. Shift only
  3. Right Alt only
  4. No Modifiers pressed (In gray)
  5. Right Alt + Shift
The repeat of the keys with no modifiers makes it easier to follow what the Right Alt_Shift keys are.

Skaperen 06-27-2022 08:37 PM

i totally cannot understand what you are doing. and, how do i rotate a keyboard that is part of a laptop on a riser frame?

business_kid 06-28-2022 03:47 AM

Quote:

Originally Posted by Skaperen (Post 6364009)
i totally cannot understand what you are doing. and, how do i rotate a keyboard that is part of a laptop on a riser frame?

To answer the second part, with great difficulty, I imagine. It certainly limits what you can do. I have a wireless keyboard.

Skaperen 06-29-2022 11:26 PM

i will assume the feature i want does not exist. if i ever get into hacking X source i'll look at input handling and see if i can change it. but, more likely, Wayland will be the big thing of the day. then, i wonder if sticky keys will even be around. but it least the source code should be simpler.

business_kid 06-30-2022 04:54 AM

There are programs or adaptions done for handling I/O for limited and even blind individuals.

I aquired bad habits, because as a youngster I got epilepsy. I was dismissed as handicapped. I rejected that and lived as normal a life as I could, being brought up short occasionally. I drove ran my own business, and raised a family. I've kept that attitude despite the stroke.


All times are GMT -5. The time now is 03:25 AM.