summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2011-10-10 22:47:19 +0000
committerMaxime Coste <frrrwww@gmail.com>2011-10-10 22:47:19 +0000
commitf802a9f3bea1f3b1bfe2bc13b42706a287bbd8d5 (patch)
tree41acb8c55deaf810a907d7c5fc370cb6b0cdda26 /src
parent219709e472f4f7948d164316c8b24d4fb0505636 (diff)
Debug: add key integral value in the debug buffer on keystroke
Diffstat (limited to 'src')
-rw-r--r--src/main.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main.cc b/src/main.cc
index 0d78f437..e7693a8a 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -11,6 +11,7 @@
#include <unordered_map>
#include <map>
+#include <sstream>
#include <ncurses.h>
using namespace Kakoune;
@@ -569,7 +570,9 @@ int main(int argc, char* argv[])
try
{
char c = getch();
- write_debug(std::string("key ") + c + '\n');
+ std::ostringstream oss;
+ oss << "key " << int(c) << " (" << c << ")\n";
+ write_debug(oss.str());
if (isdigit(c))
count = count * 10 + c - '0';