Can't create custom shortcuts for selecting text

Hi guys,

I’m trying to map the ujhk keys to serve as cursors because they are more convenient to me.

I’ve used the following code on my-init-texmacs.scm (I’m using the gnome look and feel)

But there is a problem: the gnome ujhk shortcuts work fine, the gnome A-hk work fine, but the gnome S-ujhk don’t work (the cursor doesn’t move, no text is selected), nor do the gnome A-S-hk

  ("gnome u" (kbd-up))
  ("gnome j" (kbd-down))
  ("gnome h" (kbd-left))
  ("gnome k" (kbd-right))
  ("gnome S-u" (kbd-select kbd-up))
  ("gnome S-j" (kbd-select kbd-down))
  ("gnome S-h" (kbd-select kbd-left))
  ("gnome S-k" (kbd-select kbd-right))
  ("gnome A-h" (traverse-left))
  ("gnome A-k" (traverse-right))
  ("gnome A-S-h" (kbd-select traverse-left))
  ("gnome A-S-k" (kbd-select traverse-right))

Compare this to the file generic/generic-kbd.scm which has the default shortcuts. There we find things like

("S-left" (kbd-select kbd-left))
  ("S-right" (kbd-select kbd-right))
  ("S-up" (kbd-select kbd-up))
  ("S-down" (kbd-select kbd-down))

so my keyboard bindings should issue the same commands :frowning:

Any ideas what’s going on?

You should rather use “gnome U” instead of “gnome S-u”.
Also be careful about definition order; the latest re-definition will prevail.