]> Dogcows Code - chaz/openbox/blobdiff - openbox/config.c
make a config option for the inactive osd font
[chaz/openbox] / openbox / config.c
index 0d28be2cb8d1568f59559249478fee2e89040c68..6bdae9fffbd3b11dde405a17a63606a598e4d30f 100644 (file)
@@ -34,6 +34,7 @@ guint    config_focus_delay;
 gboolean config_focus_raise;
 gboolean config_focus_last;
 gboolean config_focus_under_mouse;
+gboolean config_unfocus_leave;
 
 ObPlacePolicy  config_place_policy;
 gboolean       config_place_center;
@@ -56,7 +57,8 @@ RrFont *config_font_activewindow;
 RrFont *config_font_inactivewindow;
 RrFont *config_font_menuitem;
 RrFont *config_font_menutitle;
-RrFont *config_font_osd;
+RrFont *config_font_activeosd;
+RrFont *config_font_inactiveosd;
 
 guint   config_desktops_num;
 GSList *config_desktops_names;
@@ -504,6 +506,8 @@ static void parse_focus(xmlNodePtr node, gpointer d)
         config_focus_last = obt_parse_node_bool(n);
     if ((n = obt_parse_find_node(node, "underMouse")))
         config_focus_under_mouse = obt_parse_node_bool(n);
+    if ((n = obt_parse_find_node(node, "unfocusOnLeave")))
+        config_unfocus_leave = obt_parse_node_bool(n);
 }
 
 static void parse_placement(xmlNodePtr node, gpointer d)
@@ -602,8 +606,12 @@ static void parse_theme(xmlNodePtr node, gpointer d)
             font = &config_font_menutitle;
         else if (obt_parse_attr_contains(n, "place", "MenuItem"))
             font = &config_font_menuitem;
+        else if (obt_parse_attr_contains(n, "place", "ActiveOnScreenDisplay"))
+            font = &config_font_activeosd;
         else if (obt_parse_attr_contains(n, "place", "OnScreenDisplay"))
-            font = &config_font_osd;
+            font = &config_font_activeosd;
+        else if (obt_parse_attr_contains(n, "place","InactiveOnScreenDisplay"))
+            font = &config_font_inactiveosd;
         else
             goto next_font;
 
@@ -926,6 +934,7 @@ void config_startup(ObtParseInst *i)
     config_focus_raise = FALSE;
     config_focus_last = TRUE;
     config_focus_under_mouse = FALSE;
+    config_unfocus_leave = FALSE;
 
     obt_parse_register(i, "focus", parse_focus, NULL);
 
@@ -1032,7 +1041,8 @@ void config_shutdown(void)
     RrFontClose(config_font_inactivewindow);
     RrFontClose(config_font_menuitem);
     RrFontClose(config_font_menutitle);
-    RrFontClose(config_font_osd);
+    RrFontClose(config_font_activeosd);
+    RrFontClose(config_font_inactiveosd);
 
     for (it = config_desktops_names; it; it = g_slist_next(it))
         g_free(it->data);
This page took 0.024241 seconds and 4 git commands to generate.