From 1ad2415315c1e6dbcdfcd4a4b22b6fb93ccef1f2 Mon Sep 17 00:00:00 2001 From: PatR Date: Wed, 12 Jun 2019 17:57:24 -0700 Subject: [PATCH] tty bug with displaying long 'autodescribe' text Messages on tty which bypass message history weren't handling long lines properly. If the text wrapped to line 2, that continuation portion was left on the screen after whatever operation that put it here was finished. (To reproduce: assign a long name to a monster with a long type name so that the combined length exceeds the display width, then move the cursor over it with ';' or '/' while autodescribe is On.) --- doc/fixes36.3 | 5 ++++- win/tty/topl.c | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/doc/fixes36.3 b/doc/fixes36.3 index 3e711b77c..08e1c075a 100644 --- a/doc/fixes36.3 +++ b/doc/fixes36.3 @@ -1,4 +1,4 @@ -$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.51 $ $NHDT-Date: 1560185545 2019/06/10 16:52:25 $ +$NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.52 $ $NHDT-Date: 1560387439 2019/06/13 00:57:19 $ This fixes36.3 file is here to capture information about updates in the 3.6.x lineage following the release of 3.6.2 in May 2019. Please note, however, @@ -122,6 +122,9 @@ tty: re-do one optimization used when status conditions have all been removed and remove another that tried to check whether condition text to be displayed next was the same as the existing value; sometimes new status condition wouldn't be shown unless a screen redraw was forced +tty: message line anomaly: if autodecribe feedback wrapped to second line, + the wrapped portion wasn't erased when a shorter line was shown or + getpos was dismissed Windows: some startup error messages were not being delivered successfully diff --git a/win/tty/topl.c b/win/tty/topl.c index 3040c7ed4..0c6302250 100644 --- a/win/tty/topl.c +++ b/win/tty/topl.c @@ -1,4 +1,4 @@ -/* NetHack 3.6 topl.c $NHDT-Date: 1549333449 2019/02/05 02:24:09 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.44 $ */ +/* NetHack 3.6 topl.c $NHDT-Date: 1560387439 2019/06/13 00:57:19 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.45 $ */ /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */ /*-Copyright (c) Michael Allison, 2009. */ /* NetHack may be freely redistributed. See license for details. */ @@ -155,6 +155,9 @@ const char *str; home(); cl_end(); addtopl(str); + + if (ttyDisplay->cury && ttyDisplay->toplin != 3) + more(); } }