Subject: bug#17497: The text-mode menu looks very broken in emacs-24

From: Martin Trojer <[email-masked]>
Date: Wed, 18 Mar 2015 17:13:13 +0000

>From bdff1ff98d02f4307659c052d0b35a40a36f0706 Mon Sep 17 00:00:00 2001
From: Martin Trojer <[email-masked]>
Date: Wed, 18 Mar 2015 11:44:02 +0000
Subject: [PATCH] emacs bug #17497 fix

---
 src/cm.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/cm.c b/src/cm.c
index 474f280..ed17447 100644
--- a/src/cm.c
+++ b/src/cm.c
@@ -371,6 +371,16 @@ cmgoto (struct tty_display_info *tty, int row, int col)
       dcm = tty->Wcm->cm_abs;
     }

+    /* only use direct moves */
+    cost = 0;
+    p = (dcm == tty->Wcm->cm_habs
+         ? tgoto (dcm, row, col)
+         : tgoto (dcm, col, row));
+    emacs_tputs (tty, p, 1, evalcost);
+    emacs_tputs (tty, p, 1, cmputc);
+    curY (tty) = row, curX (tty) = col;
+    return;
+
   /*
    * In the following comparison, the = in <= is because when the costs
    * are the same, it looks nicer (I think) to move directly there.

On Wed, Mar 18, 2015 at 5:11 PM, Eli Zaretskii <[email-masked]> wrote:

> > Date: Wed, 18 Mar 2015 16:51:48 +0000
> > From: Martin Trojer <[email-masked]>
> >
> > I believe that snippet of code was from you :) I simply put that quoted
> snipped
> > in the cmgoto function as per your instructions. I'm sure this isn't the
> 'right
> > thing to do' since it completely bypasses the switch statement that
> tries to do
> > the cheapest cursor move.
>
> So what patch did you install, exactly, that fixed the problem?
>