diff options
author | Jesse Luehrs <doy@tozt.net> | 2014-04-05 14:59:07 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2014-04-05 14:59:07 -0400 |
commit | a4b7c2d96c12be570c1ce0e3af5ee2a9f3bf2d7e (patch) | |
tree | f4dc4b4459fb7a1f5043bd99d0ab6b3a521b5e08 | |
parent | d63232774dae78b0ee270a47671be9fd70d99969 (diff) | |
download | runes-a4b7c2d96c12be570c1ce0e3af5ee2a9f3bf2d7e.tar.gz runes-a4b7c2d96c12be570c1ce0e3af5ee2a9f3bf2d7e.zip |
make the canvas as big as the window
-rw-r--r-- | xlib.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -54,9 +54,11 @@ RunesWindow *runes_window_create() cairo_surface_t *runes_surface_create(RunesWindow *w) { Visual *vis; + XWindowAttributes attrs; + XGetWindowAttributes(w->dpy, w->w, &attrs); vis = DefaultVisual(w->dpy, DefaultScreen(w->dpy)); - return cairo_xlib_surface_create(w->dpy, w->w, vis, 240, 80); + return cairo_xlib_surface_create(w->dpy, w->w, vis, attrs.width, attrs.height); } void runes_window_prepare_input(RunesWindow *w) |