]> git.sur5r.net Git - i3/i3/commitdiff
Bugfix: Draw bar at the correct position, handle expose events for bars
authorMichael Stapelberg <michael+x200@stapelberg.de>
Mon, 9 Mar 2009 07:24:05 +0000 (08:24 +0100)
committerMichael Stapelberg <michael+x200@stapelberg.de>
Mon, 9 Mar 2009 07:24:05 +0000 (08:24 +0100)
src/handlers.c
src/layout.c

index 5a7d5362735395742d5177b6c261eb0c6945cb50..016eacf0953d32393c8271053ceb9dda86f0a947 100644 (file)
@@ -549,6 +549,14 @@ int handle_expose_event(void *data, xcb_connection_t *conn, xcb_expose_event_t *
                                 render_container(conn, stack_win->container);
                                 return 1;
                         }
+
+                /* …or one of the bars? */
+                i3Screen *screen;
+                TAILQ_FOREACH(screen, virtual_screens, screens) {
+                        if (screen->bar == event->window) {
+                                render_layout(conn);
+                        }
+                }
                 return 1;
         }
 
index 14120ef06ec6f91a7c5274a3e046be7533f3728f..17c99a6a03dd65c1f72dfaf74e604274bf26121f 100644 (file)
@@ -532,7 +532,7 @@ void render_layout(xcb_connection_t *conn) {
                         }
 
                 render_bars(conn, r_ws, width, &height);
-                render_internal_bar(conn, r_ws, width, 18);
+                render_internal_bar(conn, r_ws, width, font->height + 6);
         }
 
         xcb_flush(conn);