Modify short key for kbd-right trigger error

Hi all, I tried to modify the arrow keys as bellow, all works except C-f, it has no response and there is error message in terminal, anyone know where is wrong?
xxx/TeXmacs-2.1-x86_64-pc-linux-gnu/TeXmacs/progs/kernel/gui/kbd-handlers.scm:27:3: Unbound variable: forward

(delayed
 (lazy-keyboard-force)
 (kbd-map ("C-b" (kbd-left)))
 (kbd-map ("C-f" (kbd-right)))
 (kbd-map ("C-p" (kbd-up)))
 (kbd-map ("C-n" (kbd-down))))

Hi @wztdream and welcome to the forum.

I am not able to replicate the issue—in my Windows installation your definitions work.

I think as a first step it could be useful to know whether you have other definitions in your initialization file (my-init-texmacs.scm).
Also, is the variable that the program says is unbound forward, forward? or forwards? (the last two with a question mark at the end) ?. I did not find any variable named forward in part of the source code written in the Scheme language (unbound variable is Scheme error).

I think as a first step it could be useful to know whether you have other definitions in your initialization file (my-init-texmacs.scm).

There is no other definitons in my-init-texmacs.scm, only above codes.

Also, is the variable that the program says is unbound forward , forward? or forwards? (the last two with a question mark at the end) ?

It is forward no question mark

. I did not find any variable named forward in part of the source code written in the Scheme language ( unbound variable is Scheme error).

It seems this is a bug, mybe typo, do you know how to debug Scheme? In emacs this kind of bug is very easy to locate by edbug or backtrace but seems there is no such tool in texmacs.

Just notices that above kdb setting actually have no effect at all. If I remove all the setting the results is the same.

C-b C-n etc works should just due to I enable emacs ‘look and feel’ in Edit/preference. And the error of C-f is related with the command that was bound by texmacs default.

I am using Kubuntu 20.04 and installed binary texmacs from here

So the question is:

  1. why my-init-texmacs.scm have no effect?
  2. why there is error in terminal?
  3. how to debug these issue?

I finally fond the root cause, this is my mistake, I have set an wrong command forward to C-f in Tools/Kerboard several days ago, but I forgot it. I guess this will override the settings in my-init-texmacs.smc

Happy that it works now. I have not yet been able to figure out where the Tools/Keyboard widget saves the commands given through it. Perhaps someone knows?

That seems to be $TEXMACS_HOME_DIR/system/shortcuts.scm