]> Dogcows Code - chaz/openbox/commitdiff
nicer output
authorDana Jansens <danakj@orodu.net>
Mon, 30 Dec 2002 06:46:19 +0000 (06:46 +0000)
committerDana Jansens <danakj@orodu.net>
Mon, 30 Dec 2002 06:46:19 +0000 (06:46 +0000)
src/bindings.cc
src/openbox.cc

index c4469bb186e82134f9fdef9cf15a94819ceaae0e..3e65c049eb79dc23a59d97c8ddba8f1360795f49 100644 (file)
@@ -21,7 +21,8 @@ static void print_branch(BindingTree *first, std::string str)
   while (p) {
     if (p->first_child)
       print_branch(p->first_child, str + " " + p->text);
-    printf("%d%s\n", p->id, (str + " " + p->text).c_str());
+    if (!p->chain)
+      printf("%d%s\n", p->id, (str + " " + p->text).c_str());
     BindingTree *s = p->next_sibling;
     delete p;
     p = s;
@@ -83,9 +84,8 @@ static BindingTree *buildtree(const OBBindings::StringVect &keylist, int id)
     p->chain = false;
   }
 
-  printf("<BUILDING>\n");
+  printf("BUILDING:\n");
   print_branch(ret, "");
-  printf("</BUILDING>\n");
   
   // successfully built a tree
   return ret;
index 952fca51dfaf7103a481ac40325dfba2d40ea4f2..2d13ba1b42b9294804fd7eae143dddb46a607fbb 100644 (file)
@@ -150,8 +150,8 @@ Openbox::Openbox(int argc, char **argv)
   _bindings = new OBBindings();
 
   OBBindings::StringVect v;
-//  v.push_back("C-x");
-//  v.push_back("C-y");
+  v.push_back("C-x");
+  v.push_back("C-y");
   v.push_back("v");
   _bindings->add(v, 1);
   v.clear();
@@ -160,6 +160,7 @@ Openbox::Openbox(int argc, char **argv)
   v.push_back("a");
   _bindings->add(v, 2);
 
+  printf("CHAINS:\n");
   _bindings->display();
   ::exit(0);
 
This page took 0.025559 seconds and 4 git commands to generate.