Re: Key bindings
Charlie Gordon <[email protected]> Sun, 28 Aug 2022 01:21:21 +0200
| Newsgroups | gmane.editors.qemacs.devel |
|---|---|
| Message-ID | <[email protected]> |
--Apple-Mail=_60EF6D9A-2D1E-4372-9B44-C4A14EB127A8 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Hello Marc, Thank you for your feedback. I am using a Mac too, but I run qemacs in iTerm2, which I recommend as a = terminal application on macOS. The escape sequences for Home and End were bogus, I fixed them and added = support for the Control, Shift and Alt prefixes for the cursor movement = keys. Let me know if is works fine on your system Regarding F1, the terminal indeed sends ESC O P, which is recognised as = the key `f1` and bound to the command help-for-help, which is somewhat = different from the emacs binding where `f1` is a prefix key equivalent = to C-h. It is surprising that `f1` seems to invoke goto-tag, which is bound to = `C-x ,` and `M-f1` which for some obscure reason is not produced by the keyboard when hitting Alt Fn F1, = but can be obtained with ESC F1. The key decoding has been substantially improved and unrecognised = sequences are reported. You can also use C-h d to invoke toggle-trace-mode that displays the = *trace* buffer with information about the bytes received from the terminal, the key conversions, the = commands invoked, the bytes sent to the shell process and the escape sequences received from the = process. This is quite useful to debug keyboard and VT100 emulation issues. Best regard Chqrlie > On 27 Aug 2022, at 06:14, Marc Wilson <[email protected]> wrote: >=20 > The key bindings available via C-h b shows >=20 > beginning-of-line : C-a, home =20 >=20 > But Home does not go to beginning-of-line. It instead acts as = backward-word. >=20 > It also shows >=20 > beginning-of-buffer : M-<, C-home >=20 > And C-home is again backward-word. >=20 > Also, what is qemacs looking for that signifies F1? In macOS = Terminal.app, F1 is ESC-O-P, hitting F1 qemacs produces the message = =E2=80=9CNo tag=E2=80=9D. Can that =E2=80=9CPress F1 for help message = be customized or disabled? It looks like canned text in qe.c. >=20 > Thanks. >=20 > --=20 > Marc Wilson > [email protected] <mailto:[email protected]> --Apple-Mail=_60EF6D9A-2D1E-4372-9B44-C4A14EB127A8 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 <html><head><meta http-equiv=3D"Content-Type" content=3D"text/html = charset=3Dutf-8"></head><body style=3D"word-wrap: break-word; = -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" = class=3D"">Hello Marc,<div class=3D""><br class=3D""></div><div = class=3D"">Thank you for your feedback.</div><div class=3D""><br = class=3D""></div><div class=3D"">I am using a Mac too, but I run qemacs = in iTerm2, which I recommend as a terminal application on = macOS.</div><div class=3D""><br class=3D""></div><div class=3D"">The = escape sequences for Home and End were bogus, I fixed them and added = support for the Control, Shift and Alt prefixes for the cursor movement = keys.</div><div class=3D""><br class=3D""></div><div class=3D"">Let me = know if is works fine on your system</div><div class=3D""><br = class=3D""></div><div class=3D"">Regarding F1, the terminal indeed sends = ESC O P, which is recognised as the key `f1` and bound to the command = help-for-help, which is somewhat different from the emacs binding where = `f1` is a prefix key equivalent to C-h.</div><div class=3D""><br = class=3D""></div><div class=3D"">It is surprising that `f1` seems to = invoke goto-tag, which is bound to `C-x ,` and `M-f1` which for = some</div><div class=3D"">obscure reason is not produced by the keyboard = when hitting Alt Fn F1, but can be obtained with ESC F1.</div><div = class=3D""><br class=3D""></div><div class=3D"">The key decoding has = been substantially improved and unrecognised sequences are = reported.</div><div class=3D""><br class=3D""></div><div class=3D"">You = can also use C-h d to invoke toggle-trace-mode that displays the *trace* = buffer with information</div><div class=3D"">about the bytes received = from the terminal, the key conversions, the commands invoked, the = bytes</div><div class=3D"">sent to the shell process and the escape = sequences received from the process. This is quite = useful</div><div class=3D"">to debug keyboard and VT100 emulation = issues.</div><div class=3D""><br class=3D""></div><div class=3D"">Best = regard</div><div class=3D""><br class=3D""></div><div = class=3D"">Chqrlie</div><div class=3D""><br class=3D""><div><blockquote = type=3D"cite" class=3D""><div class=3D"">On 27 Aug 2022, at 06:14, Marc = Wilson <<a href=3D"mailto:[email protected]" = class=3D"">[email protected]</a>> wrote:</div><br = class=3D"Apple-interchange-newline"><div class=3D""><div = style=3D"font-family: Helvetica; font-size: 12px; font-style: normal; = font-variant-caps: normal; font-weight: normal; letter-spacing: normal; = text-align: start; text-indent: 0px; text-transform: none; white-space: = normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D"">The= key bindings available via C-h b shows<br class=3D""></div><div = style=3D"font-family: Helvetica; font-size: 12px; font-style: normal; = font-variant-caps: normal; font-weight: normal; letter-spacing: normal; = text-align: start; text-indent: 0px; text-transform: none; white-space: = normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><br= class=3D""></div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D"">beginning-of-line : C-a, = home <br class=3D""></div><div style=3D"font-family: = Helvetica; font-size: 12px; font-style: normal; font-variant-caps: = normal; font-weight: normal; letter-spacing: normal; text-align: start; = text-indent: 0px; text-transform: none; white-space: normal; = word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><br = class=3D""></div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D"">But Home does not go to = beginning-of-line. It instead acts as backward-word.<br = class=3D""></div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D""><br class=3D""></div><div = style=3D"font-family: Helvetica; font-size: 12px; font-style: normal; = font-variant-caps: normal; font-weight: normal; letter-spacing: normal; = text-align: start; text-indent: 0px; text-transform: none; white-space: = normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D"">It = also shows<br class=3D""></div><div style=3D"font-family: Helvetica; = font-size: 12px; font-style: normal; font-variant-caps: normal; = font-weight: normal; letter-spacing: normal; text-align: start; = text-indent: 0px; text-transform: none; white-space: normal; = word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><br = class=3D""></div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D"">beginning-of-buffer : = M-<, C-home<br class=3D""></div><div style=3D"font-family: Helvetica; = font-size: 12px; font-style: normal; font-variant-caps: normal; = font-weight: normal; letter-spacing: normal; text-align: start; = text-indent: 0px; text-transform: none; white-space: normal; = word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><br = class=3D""></div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D"">And C-home is again = backward-word.</div><div style=3D"font-family: Helvetica; font-size: = 12px; font-style: normal; font-variant-caps: normal; font-weight: = normal; letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D""><br class=3D""></div><div = style=3D"font-family: Helvetica; font-size: 12px; font-style: normal; = font-variant-caps: normal; font-weight: normal; letter-spacing: normal; = text-align: start; text-indent: 0px; text-transform: none; white-space: = normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" = class=3D"">Also, what is qemacs looking for that signifies F1? In = macOS Terminal.app, F1 is ESC-O-P, hitting F1 qemacs produces the = message =E2=80=9CNo tag=E2=80=9D. Can that =E2=80=9CPress F1 for = help message be customized or disabled? It looks like canned text = in qe.c.</div><div style=3D"font-family: Helvetica; font-size: 12px; = font-style: normal; font-variant-caps: normal; font-weight: normal; = letter-spacing: normal; text-align: start; text-indent: 0px; = text-transform: none; white-space: normal; word-spacing: 0px; = -webkit-text-stroke-width: 0px;" class=3D""><br class=3D""></div><div = style=3D"font-family: Helvetica; font-size: 12px; font-style: normal; = font-variant-caps: normal; font-weight: normal; letter-spacing: normal; = text-align: start; text-indent: 0px; text-transform: none; white-space: = normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" = class=3D"">Thanks.<br class=3D""></div><div style=3D"font-family: = Helvetica; font-size: 12px; font-style: normal; font-variant-caps: = normal; font-weight: normal; letter-spacing: normal; text-align: start; = text-indent: 0px; text-transform: none; white-space: normal; = word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><br = class=3D""></div><div id=3D"sig39065985" style=3D"font-family: = Helvetica; font-size: 12px; font-style: normal; font-variant-caps: = normal; font-weight: normal; letter-spacing: normal; text-align: start; = text-indent: 0px; text-transform: none; white-space: normal; = word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=3D""><div = class=3D"signature">-- <br class=3D""></div><div = class=3D"signature">Marc Wilson<br class=3D""></div><div = class=3D"signature"><a href=3D"mailto:[email protected]" = class=3D"">[email protected]</a></div></div></div></blockquote></div><br = class=3D""></div></body></html>= --Apple-Mail=_60EF6D9A-2D1E-4372-9B44-C4A14EB127A8--