resize message window horizontally to available space
authorMischa POSLAWSKY <netris@shiar.org>
Sun, 4 Mar 2007 10:17:43 +0000 (11:17 +0100)
committerMischa POSLAWSKY <netris@shiar.org>
Sun, 4 Mar 2007 10:17:43 +0000 (11:17 +0100)
curses.c

index 5856f65f1b8d13b6c8519d09b819108a136ec50a..2c4b87cd252415ab1428234355314462b0c20f71 100644 (file)
--- a/curses.c
+++ b/curses.c
@@ -293,7 +293,7 @@ void InitFields(void)
        messageWidth  = MIN(x - messageXPos - 2, MSG_WIDTH);
        messageHeight = MIN(y - messageYPos - 1, MSG_HEIGHT);
        if (messageHeight <= 0) {
-               messageWidth = 27;
+               messageWidth = MIN(x - statusXPos - 18, 27);
                messageHeight = y - 3;
                messageXPos = statusXPos + 16;
                messageYPos = 2;