Skip to content

Commit

Permalink
Mystery of backspace bug solved: ocaml-community/lambda-term#57
Browse files Browse the repository at this point in the history
  • Loading branch information
fpierre committed Mar 24, 2018
1 parent ebfb329 commit 8a182fc
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/gufoConsole.ml
Original file line number Diff line number Diff line change
Expand Up @@ -761,13 +761,12 @@ let completion shell_env hist cur_expr =

let handle_key_event term shell_env hist cur_expr akey =
match akey.LTerm_key.code with
(* | Char uchar when (UChar.uint_code uchar) = 0x0068 *)
(*Ugly hack, I don't know why this key match backspace.
* I have posted on lambda-term about the issue:
| Char uchar when ((UChar.uint_code uchar) = 0x0068 && akey.LTerm_key.control)
(*It looks some conventions allows CTRL-H to del char, and some GUI Terms
* remap backspace to CTRL-H...
* https://github.com/diml/lambda-term/issues/57
*
* *)
(* -> delete term cur_expr *)
-> delete term shell_env hist cur_expr
| Char uchar when ((UChar.uint_code uchar) = 0x0020) &&
(akey.LTerm_key.control)
->
Expand Down

0 comments on commit 8a182fc

Please sign in to comment.