Date: 30 Oct 1999 16:34:09 -0500 From: Kevin Street <street@iname.com> To: "Peter S. Housel" <housel@cx281057-a.irvn1.occa.home.com> Cc: Brian Dean <brdean@unx.sas.com>, "Russell L. Carter" <rcarter@pinyon.org>, freebsd-current@FreeBSD.ORG Subject: Re: emacs / ncurses - problem somewhere Message-ID: <874sf8pm7i.fsf@mired.eh.local> In-Reply-To: "Peter S. Housel"'s message of "Fri, 29 Oct 1999 12:29:05 -0700" References: <199910291929.MAA35072@cx281057-a.irvn1.occa.home.com>
next in thread | previous in thread | raw e-mail | index | archive | help
"Peter S. Housel" <housel@cx281057-a.irvn1.occa.home.com> writes:
> > Ever since the libtermcap / libncurses consolidation, change emacs has
> > problems positioning the cursor and properly updating the screen for
> > character-only devices like the console. It also affects the display
> > in an xterm in non-X mode, i.e., when DISPLAY is *not* set.
> > ...
> I filed a bug report for this. I fixed it in Emacs with the following
> patch. I think it's a FreeBSD bug, though.
Good detective work, Peter. So is the bug in FreeBSD or Emacs? The
new man page for tgetstr says:
Bugs
If you call tgetstr to fetch ca or any other parameterized
string, be aware that it will be returned in terminfo
notation, not the older and not-quite-compatible termcap
notation. This won't cause problems if all you do with it
is call tgoto or tparm, which both expand terminfo-style.
Emacs tries to expand the string itself rather than by calling tparm
and we've surprised it by returning the string in terminfo style
rather than termcap style.
Here's an alternative patch that forces Emacs to use the library
versions of tparm and tgoto to do the decoding rather than rolling its
own. Put this in /usr/ports/editors/emacs20/patches/patch-ce
(although it really should get merged into patch-ca). It works by
using the module intended for Emacs running on terminfo machines
(ie. it uses terminfo.c rather than tparam.c). I tried this (briefly)
on -current and -stable and it seems to work ok.
$ cat /usr/ports/editors/emacs20/patches/patch-ce
--- src/Makefile.in.orig Sat Oct 30 15:52:15 1999
+++ src/Makefile.in Sat Oct 30 15:55:28 1999
@@ -546,7 +546,7 @@
#define LIBS_TERMCAP
termcapobj = termcap.o tparam.o
#else /* LIBS_TERMCAP */
-termcapobj = tparam.o
+termcapobj = terminfo.o
#endif /* LIBS_TERMCAP */
#endif /* ! defined (TERMINFO) */
--
Kevin Street
street@iname.com
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?874sf8pm7i.fsf>
