Hi,

 AG_Console autoscrolling currently behaves in an unintuitive way,
since it scrolls down by the number of lines added instead of always
showing the newest log messages as in most other programs that
have this feature, e.g. xterm -sb or other terminal emulators.

 The following small change to gui/console.c from agar 1.4.0
yields the expected behaviour for me.

 I reported this to bugzilla, bug #173.

--- console.c   2010-10-28 13:42:49.013183498 +0200
+++ console.c   2010-10-28 13:42:58.494542649 +0200
@@ -353,7 +353,7 @@
    ln->cFg = AG_ColorRGB(250,250,230);

    if (cons->flags & AG_CONSOLE_AUTOSCROLL)
-       cons->rOffs++;
+       cons->rOffs = cons->nLines - cons->rVisible;

    AG_ObjectUnlock(cons);
    return (ln);

Best regards,

 Fabian Svara

_______________________________________________
Agar mailing list
[email protected]
http://libagar.org/lists.html

Reply via email to