You are not logged in.

#1 2010-10-24 12:27:46

crom
Member
From: Germany
Registered: 2008-05-11
Posts: 43

Emulate F1 ... F10 or change tty shortcuts

Hi there,

I just received a tiny cordless keyboard that has no F1 - F10 keys. How could I change the behavior of changig ttys in arch or remap any other keys to the F-Keys below X11?

Thanks in advance,
Sebastian

Offline

#2 2010-10-24 13:15:34

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Emulate F1 ... F10 or change tty shortcuts

man chvt - how to change ttys

Offline

#3 2010-10-24 14:19:52

grizzeledtop
Member
From: Zurich, Switzerland
Registered: 2006-03-08
Posts: 30

Re: Emulate F1 ... F10 or change tty shortcuts

xmodmap is your tool, 'man xmodmap' will give you the insides, create your personal  "xmodmap -pke >>.myxmodemap" and modify it to your liking, then run it like so: 'xmodmap .myxmodmap', you can put that in .xinitrc;
check your keyboard with 'xev'.

Read the documentation to the tool 'xkeycaps'


You scratch my back, I'll ride on yours

Offline

#4 2010-10-24 14:37:56

Awebb
Member
Registered: 2010-05-06
Posts: 6,275

Re: Emulate F1 ... F10 or change tty shortcuts

xmodmap for changing tty behavior... What to do when there is no X?

Offline

#5 2010-10-24 20:35:44

grizzeledtop
Member
From: Zurich, Switzerland
Registered: 2006-03-08
Posts: 30

Re: Emulate F1 ... F10 or change tty shortcuts

Awebb wrote:

xmodmap for changing tty behavior... What to do when there is no X?

I think "...below X11" means "...under X11";  There's got to be a way of remapping the console keyboad, although I wouldn't know how.


You scratch my back, I'll ride on yours

Offline

#6 2010-10-24 21:04:35

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: Emulate F1 ... F10 or change tty shortcuts

loadkeys and dumpkeys are what you need to use to change the key layout outside of X. It's not nearly as clean and neat as it is with xmodmap. chvt is the best way to handle this.

You might also have some success with bind -x to call chvt with a keystroke. See 'help bind' from a bash terminal.

Last edited by falconindy (2010-10-24 21:05:21)

Offline

#7 2010-10-24 21:13:24

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Emulate F1 ... F10 or change tty shortcuts

I've just remembered that Alt + Left/Right arrow changes tty to the next / previous.

HTH

Offline

Board footer

Powered by FluxBB