git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH v2] git-gui: Handle Ctrl + BS/Del in the commit msg
@ 2019-02-16  3:10 Ismael Luceno
  2019-02-20 20:05 ` Junio C Hamano
  0 siblings, 1 reply; 5+ messages in thread
From: Ismael Luceno @ 2019-02-16  3:10 UTC (permalink / raw)
  To: git; +Cc: brian m. carlson, Pat Thoyts, Ismael Luceno

- Control+BackSpace: Delete word to the left of the cursor.
- Control+Delete   : Delete word to the right of the cursor.

Originally introduced by BRIEF and Turbo Vision between 1985 and 1992,
they were adopted by most CUA-Compliant UIs, including those of: OS/2,
Windows, Mac OS, Qt, GTK, Open/Libre Office, Gecko, and GNU Emacs.

Signed-off-by: Ismael Luceno <ismael@iodev.co.uk>
---

Notes:
    Changes since v1:
    - Improved commit message.

 git-gui.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/git-gui.sh b/git-gui.sh
index 5bc21b878d41..e00d9a345294 100755
--- a/git-gui.sh
+++ b/git-gui.sh
@@ -3788,6 +3788,8 @@ bind $ui_comm <$M1B-Key-KP_Subtract> {show_less_context;break}
 bind $ui_comm <$M1B-Key-equal> {show_more_context;break}
 bind $ui_comm <$M1B-Key-plus> {show_more_context;break}
 bind $ui_comm <$M1B-Key-KP_Add> {show_more_context;break}
+bind $ui_comm <Control-Key-BackSpace> {%W delete {insert -1 chars wordstart} insert;break}
+bind $ui_comm <Control-Key-Delete> {%W delete insert {insert wordend};break}
 
 bind $ui_diff <$M1B-Key-x> {tk_textCopy %W;break}
 bind $ui_diff <$M1B-Key-X> {tk_textCopy %W;break}
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-03-04 14:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-16  3:10 [PATCH v2] git-gui: Handle Ctrl + BS/Del in the commit msg Ismael Luceno
2019-02-20 20:05 ` Junio C Hamano
2019-02-21  9:31   ` Ismael Luceno
2019-02-21 20:47     ` Junio C Hamano
2019-03-04 14:09       ` Ismael Luceno

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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).