Introduction
Introduction Statistics Contact Development Disclaimer Help
don't assume we get a ConfigureNotify event - sent - simple plaintext presentat…
git clone git://git.suckless.org/sent
Log
Files
Refs
README
LICENSE
---
commit 8b52c85dd1fb145b1012cd508ffd74465db7025a
parent 4ca44387e65a96a93b56ed1491f5f90c5e25d948
Author: Tony Lainson <[email protected]>
Date: Tue, 10 Nov 2015 14:54:16 +1100
don't assume we get a ConfigureNotify event
If the window manager maps our window at the requested size, we may not get a
ConfigureNotify event. This happens e.g. under ratpoison.
The result is that xw.uw and xw.uh are never set, so text is too small and
pngscale() tries to divide by 0.
Diffstat:
M sent.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/sent.c b/sent.c
@@ -506,8 +506,7 @@ void xinit()
die("Can't open display.");
xw.scr = XDefaultScreen(xw.dpy);
xw.vis = XDefaultVisual(xw.dpy, xw.scr);
- xw.w = DisplayWidth(xw.dpy, xw.scr);
- xw.h = DisplayHeight(xw.dpy, xw.scr);
+ resize(DisplayWidth(xw.dpy, xw.scr), DisplayHeight(xw.dpy, xw.scr));
xw.attrs.background_pixel = WhitePixel(xw.dpy, xw.scr);
xw.attrs.bit_gravity = CenterGravity;
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.