This solution is so bad that the author prefered to edit Mutt's source code to get rid of ^G
Warning: This solution seems incompatiple with OSX, Emacs and other aplications that use Ctrl+G
After my first day at Mutt, I was almost using ^G in Vim by mistake...
Then I tried something that seems to work here, in i3 window manager and xfce-terminal.
Added this line to
bindsym --release Escape exec --no-startup-id xvkbd -xsendevent -text "\[Escape]\[Control]\[g]"
Had to use
"\[Escape]\[Control]\[g]" because only
"\[Control]\[g]" made it stop working in Vim.
If you are not using i3, I think you can use xbindkeys to run
xvkbd -xsendevent -text "\[Escape]\[Control]\[g]" when Esc is pressed.
It's not a beautiful solution... It can make your Esc key unusable in some programs, but at least here it seems ok.
I see now that the Ctrl+G part makes Vim shows position in file. Nothing too dramatic, for now.
This link seems to have a better solution, but for urxvt: