You are not logged in.

#1 2020-04-14 08:44:17

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

[SOLVED] How to keep mousekeys active for a long time?

Thx.

Mousekey can be activate by SHIFT+NUMLOCK. But it will auto disable after 2 minuite later.  And I have to press SHIFT+NUM again to activate it. 
How to do that mousekey will auto activate at xserver start?  Or, how to make mousekey not automatically shut down after 2 minutes?

Last edited by 2XEKmkZd4C6PeYdgmuiHL6xaj (2020-04-16 13:43:10)

Offline

#2 2020-04-14 13:38:33

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: [SOLVED] How to keep mousekeys active for a long time?

A search of the repos and aur for "mousekey" provides no results.  A google search also doesn't lead to any clear candidates.

What program/tool/package are you talking about?


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2020-04-14 13:45:56

loqs
Member
Registered: 2014-03-06
Posts: 18,055

Re: [SOLVED] How to keep mousekeys active for a long time?

Are you refering to using numeric keys to control the mouse as enabled by

setxkbmap -option keypad:pointerkeys

Offline

#4 2020-04-14 14:01:39

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

Does "xkbset mousekeys" stick? (doesn't require the xkbmap option)

Offline

#5 2020-04-15 06:33:50

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

loqs wrote:

Are you refering to using numeric keys to control the mouse as enabled by

setxkbmap -option keypad:pointerkeys

Yes,but I use confgure file to set.

/etc/X11/xorg.conf.d/20-enable-pointerkeys.conf

Section "InputClass"
    Identifier    "Keyboard Defaults"
    MatchIsKeyboard "yes"
    Option "XkbOptions" "keypad:pointerkeys"
EndSection
Section "ServerFlags"
    Option         "BlankTime" "0"
    Option         "StandbyTime" "0"
    Option         "SuspendTime" "0"
    Option         "OffTime" "0"
EndSection

Offline

#6 2020-04-15 06:36:58

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

Trilby wrote:

A search of the repos and aur for "mousekey" provides no results.  A google search also doesn't lead to any clear candidates.

What program/tool/package are you talking about?

Thank you for your attention. The mousekey is a xkb function.
https://wiki.archlinux.org/index.php/Xo … mouse_keys
https://en.wikipedia.org/wiki/Mouse_keys

Offline

#7 2020-04-15 06:45:38

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:

Does "xkbset mousekeys" stick? (doesn't require the xkbmap option)

No, I don’t know where to stick this

Offline

#8 2020-04-15 06:47:49

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

Hummwhat?

If you execute that command it will activate the mousekeys and the question is whether it then auto-deactivates as well or remains active (until you issue "xkbset -mousekeys")

Offline

#9 2020-04-15 07:25:38

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:

Hummwhat?

If you execute that command it will activate the mousekeys and the question is whether it then auto-deactivates as well or remains active (until you issue "xkbset -mousekeys")

I don't have the xkbset command, I just pressed shift + num to turn on the mousekeys.

Offline

#10 2020-04-15 07:35:39

seth
Member
Registered: 2012-09-03
Posts: 58,859

Offline

#11 2020-04-15 08:44:01

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

Thank you for your help, let me ask again, how to change this value :AccessX Timeout = 120.  I hope to make it permanent.

$ xkbset q exp
AccessX Timeout = 120

Offline

#12 2020-04-15 09:19:04

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

I find a wiki about accessX timeout:

https://wiki.archlinux.org/index.php/Ac … _xserverrc

I'm trying.

Offline

#13 2020-04-15 09:28:21

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

No. I don't know what configuration file to write this parameter into : accessX timeout ,
My linux Xorg knowledge is too scarce

Offline

#14 2020-04-15 09:35:38

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

Offline

#15 2020-04-15 12:24:14

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

How do you start X11 / your session?
xinit/startx or some Display Manager? (GDM,SDDM, …)?

xkbset exp 240

will set the expiration to 240 seconds and you can call this in any way shape or form your session allows for autostarting of stuff.

For the future, please don't bump, edit your last post (there's a link in the lower right corner of every post)  if nobody has responded so far.

Offline

#16 2020-04-15 12:37:10

loqs
Member
Registered: 2014-03-06
Posts: 18,055

Re: [SOLVED] How to keep mousekeys active for a long time?

What about removing the expiry of accessx with

xkbset exp -accessx

Offline

#17 2020-04-15 13:08:18

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

Ah, I probably misinterpreted "  hope to make it permanent." as "fix the value on the server"…
You can also "xkbset exp -mousekeys" to leave the other features untouched.

Offline

#18 2020-04-15 13:53:22

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:

Ah, I probably misinterpreted "  hope to make it permanent." as "fix the value on the server"…
You can also "xkbset exp -mousekeys" to leave the other features untouched.

I used this command but it has no effect. Mousekeys will automatically close after 2 minutes.

And I found a offical doc.  But i can't solve too.

https://www.x.org/releases/X11R7.7/doc/ … ut.3.xhtml

Offline

#19 2020-04-15 14:05:42

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

Run it, then post the output of "xkbset q exp"
You can use

xkbset exp -mousekeys; xkbset q exp | curl -F 'f:1=<-' ix.io

Also elaborate on your session (which desktop environment, which display manager.)
In doubt use

loginctl session-status | curl -F 'f:1=<-' ix.io

(Because if you're on gnome on wayland, this is all moot)

Offline

#20 2020-04-15 14:35:39

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:

Run it, then post the output of "xkbset q exp"
You can use

xkbset exp -mousekeys; xkbset q exp | curl -F 'f:1=<-' ix.io

Also elaborate on your session (which desktop environment, which display manager.)
In doubt use

loginctl session-status | curl -F 'f:1=<-' ix.io

(Because if you're on gnome on wayland, this is all moot)

$ xkbset exp -mousekeys; xkbset q exp | curl -F 'f:1=<-' ix.io
http://ix.io/2i9B

My DE is LXDE .  NO DM,  use startx start X. tongue

$ loginctl session-status | curl -F 'f:1=<-' ix.io
http://ix.io/2i9C

Offline

#21 2020-04-15 14:59:07

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

Upon Expiry Mouse-Keys will be: Off

My bad, "xkbset exp mousekeys" (w/o the dash) sets it to "On".

Offline

#22 2020-04-15 15:14:24

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:
Upon Expiry Mouse-Keys will be: Off

My bad, "xkbset exp mousekeys" (w/o the dash) sets it to "On".

Amazing!!! It's work!

You have helped me a lot!Thank you very much!  This problem has troubled me for more than two years.

Can I ask the finally question:   how to automatically open mousekeys when the keyboard is reinserted,or xserver start ?

Offline

#23 2020-04-15 19:55:12

seth
Member
Registered: 2012-09-03
Posts: 58,859

Re: [SOLVED] How to keep mousekeys active for a long time?

For the server startup, just put "xkbset mousekeys" into your xiitrc.

About keyboard insertion:
If the condition isn't device agnostic you'll probably have to go w/ a udev rule to run the command when you plug a keyboard, https://wiki.archlinux.org/index.php/Udev
I'm not aware of xkb options to default this to "on" that you could put into an xorg.conf.

Offline

#24 2020-04-16 11:07:06

2XEKmkZd4C6PeYdgmuiHL6xaj
Member
Registered: 2018-02-21
Posts: 20

Re: [SOLVED] How to keep mousekeys active for a long time?

seth wrote:

For the server startup, just put "xkbset mousekeys" into your xiitrc.

About keyboard insertion:
If the condition isn't device agnostic you'll probably have to go w/ a udev rule to run the command when you plug a keyboard, https://wiki.archlinux.org/index.php/Udev
I'm not aware of xkb options to default this to "on" that you could put into an xorg.conf.

I write a udev file :  /etc/udev/rules.d/keyboard.rules

SUBSYSTEM=="leds",ATTRS{idVendor}=="413c",ACTION=="add",RUN+="/usr/bin/xkbset exp mousekeys"

It's not work. I found it must run in X.  because:

# xkbset 
Unable to open display

How to type the RUN+=" " commond and let it work?

Offline

#25 2020-04-16 11:22:27

seth
Member
Registered: 2012-09-03
Posts: 58,859

Offline

Board footer

Powered by FluxBB