public inbox for gdb-prs@sourceware.org help / color / mirror / Atom feed
From: "memo.salas at gmail dot com" <sourceware-bugzilla@sourceware.org> To: gdb-prs@sourceware.org Subject: [Bug tui/15163] Vi settings within ~/.inputrc prevent entering/exiting TUI via C-x a Date: Fri, 05 Jun 2015 02:11:00 -0000 [thread overview] Message-ID: <bug-15163-4717-dOWfpPo2fR@http.sourceware.org/bugzilla/> (raw) In-Reply-To: <bug-15163-4717@http.sourceware.org/bugzilla/> https://sourceware.org/bugzilla/show_bug.cgi?id=15163 Memo Salas <memo.salas at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |memo.salas at gmail dot com --- Comment #4 from Memo Salas <memo.salas at gmail dot com> --- This is the workaround I found: in my ~/.inputrc , I added a line that looks like this: C-P: tui-switch-mode i.e. ctrl-p will do the switch. Then, in gdb's source, in the file gdb/tui/tui.c , I found the call that normally looks like this: rl_add_defun ("tui-switch-mode", tui_rl_switch_mode, -1); and changed the 3rd parameter (i.e. the key) to be a 16. Why 16? it's what the macro CTRL(X) will do for the letter I want to assign (i.e. ctrl-p in my case). After that, I can exit in vi-keys out of tui mode by pressing ctrl-p. So what is the real fix? It seems to me that a solution will have to do with changing the function "tui_initialize_readline", which is the one that is being called at startup in a way that it hardcodes a key of with value -1 to the "tui-switch-mode", so that the user can provide their own key for it. My question is why is there a -1 being assigned to that function right now in the first place. Does anybody know ? -- You are receiving this mail because: You are on the CC list for the bug.
next prev parent reply other threads:[~2015-06-05 2:11 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-02-20 16:51 [Bug tui/15163] New: " rhys.ulerich at gmail dot com 2013-02-25 13:02 ` [Bug tui/15163] " palves at redhat dot com 2013-02-25 16:18 ` rhys.ulerich at gmail dot com 2013-02-25 18:56 ` palves at redhat dot com 2015-06-05 2:11 ` memo.salas at gmail dot com [this message] 2015-06-08 6:53 ` memo.salas at gmail dot com 2015-07-26 21:45 ` vz-sourceware at zeitlins dot org 2020-04-12 23:02 ` thib at stammed dot net 2021-04-02 19:56 ` tromey at sourceware dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-15163-4717-dOWfpPo2fR@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=gdb-prs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).