(Fexpand_abbrev): Remove unused variables.
[bpt/emacs.git] / src / terminfo.c
CommitLineData
d427b66a
JB
1/* Interface from Emacs to terminfo.
2 Copyright (C) 1985, 1986 Free Software Foundation, Inc.
3
4This file is part of GNU Emacs.
5
6GNU Emacs is free software; you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
fc91b8cb 8the Free Software Foundation; either version 2, or (at your option)
d427b66a
JB
9any later version.
10
11GNU Emacs is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with GNU Emacs; see the file COPYING. If not, write to
3b7ad313
EN
18the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19Boston, MA 02111-1307, USA. */
d427b66a 20
d676eef3 21#include <config.h>
495de6e9 22#include "lisp.h"
d676eef3 23
d427b66a
JB
24/* Define these variables that serve as global parameters to termcap,
25 so that we do not need to conditionalize the places in Emacs
26 that set them. */
27
28char *UP, *BC, PC;
d676eef3 29
ba5971b3
RS
30#if defined (HAVE_LIBNCURSES) && ! defined (NCURSES_OSPEED_T)
31short ospeed;
32#else
515b04d0 33#if defined (HAVE_TERMIOS_H) && defined (LINUX)
d676eef3 34#include <termios.h>
825e7e55
RS
35/* HJL's version of libc is said to need this on the Alpha.
36 On the other hand, DEC OSF1 on the Alpha needs ospeed to be a short. */
d676eef3
RS
37speed_t ospeed;
38#else
9f80a1c8 39short ospeed;
d676eef3 40#endif
ba5971b3 41#endif
d427b66a 42
d427b66a
JB
43/* Interface to curses/terminfo library.
44 Turns out that all of the terminfo-level routines look
45 like their termcap counterparts except for tparm, which replaces
46 tgoto. Not only is the calling sequence different, but the string
47 format is different too.
48*/
49
50char *
51tparam (string, outstring, len, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9)
52 char *string;
53 char *outstring;
54 int arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9;
55{
56 char *temp;
57 extern char *tparm();
58
59 temp = tparm (string, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9);
60 if (outstring == 0)
495de6e9 61 outstring = ((char *) (xmalloc ((strlen (temp)) + 1)));
d427b66a
JB
62 strcpy (outstring, temp);
63 return outstring;
64}