Index: src/ui/root.cc
===================================================================
--- src/ui/root.cc	(revision 1062)
+++ src/ui/root.cc	(working copy)
@@ -144,14 +144,15 @@
     m_bindings['A']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 1);
     m_bindings[':']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -1);

-  } else {
+  } else if (strncasecmp(keyLayout.c_str(), "custom", 6) != 0){
     m_bindings['a']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 1);
     m_bindings['z']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -1);
     m_bindings['A']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 1);
     m_bindings['Z']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -1);
+
   }

-  if (strcasecmp(keyLayout.c_str(), "dvorak") != 0) {
+  if (strncasecmp(keyLayout.c_str(), "custom", 6) != 0){
     m_bindings['s']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 5);
     m_bindings['x']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -5);
     m_bindings['S']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 5);
@@ -162,7 +163,7 @@
     m_bindings['D']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 50);
     m_bindings['C']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -50);

-  } else {
+  } else if (strcasecmp(keyLayout.c_str(), "dvorak") == 0) {
     m_bindings['o']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 5);
     m_bindings['q']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -5);
     m_bindings['O']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 5);
@@ -172,8 +173,27 @@
     m_bindings['j']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -50);
     m_bindings['E']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 50);
     m_bindings['J']           = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -50);
+
   }

+  if (strncasecmp(keyLayout.c_str(), "custom", 6) == 0 && keyLayout.length() >= 19){
+    m_bindings[keyLayout[7]]  = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 1);
+    m_bindings[keyLayout[8]]  = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -1);
+    m_bindings[keyLayout[9]]  = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 1);
+    m_bindings[keyLayout[10]]  = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -1);
+
+    m_bindings[keyLayout[11]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 5);
+    m_bindings[keyLayout[12]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -5);
+    m_bindings[keyLayout[13]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 5);
+    m_bindings[keyLayout[14]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -5);
+
+    m_bindings[keyLayout[15]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), 50);
+    m_bindings[keyLayout[16]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_up_throttle), -50);
+    m_bindings[keyLayout[17]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), 50);
+    m_bindings[keyLayout[18]] = sigc::bind(sigc::mem_fun(*this, &Root::adjust_down_throttle), -50);
+
+  }
+
   m_bindings['\x0C']        = sigc::mem_fun(m_control->display(), &display::Manager::force_redraw); // ^L
   m_bindings['\x11']        = sigc::mem_fun(m_control, &Control::receive_normal_shutdown); // ^Q
 }

