GDB (API)
/home/stan/gdb/src/gdb/gdb_curses.h
Go to the documentation of this file.
00001 /* Portable <curses.h>.
00002 
00003    Copyright (C) 2004-2013 Free Software Foundation, Inc.
00004 
00005    This file is part of GDB.
00006 
00007    This program is free software; you can redistribute it and/or modify
00008    it under the terms of the GNU General Public License as published by
00009    the Free Software Foundation; either version 3 of the License, or
00010    (at your option) any later version.
00011 
00012    This program is distributed in the hope that it will be useful,
00013    but WITHOUT ANY WARRANTY; without even the implied warranty of
00014    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015    GNU General Public License for more details.
00016 
00017    You should have received a copy of the GNU General Public License
00018    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
00019 
00020 #ifndef GDB_CURSES_H
00021 #define GDB_CURSES_H 1
00022 
00023 #ifdef __MINGW32__
00024 /* Windows API headers, included e.g. by serial.h, define MOUSE_MOVED,
00025    and so does PDCurses's curses.h, but for an entirely different
00026    purpose.  Since we don't use the Windows semantics of MOUSE_MOVED
00027    anywhere, avoid compiler warnings by undefining MOUSE_MOVED before
00028    including curses.h.  */
00029 #undef MOUSE_MOVED
00030 /* Likewise, KEY_EVENT is defined by ncurses.h, but also by Windows
00031    API headers.  */
00032 #undef KEY_EVENT
00033 #endif
00034 
00035 #if defined (HAVE_NCURSES_NCURSES_H)
00036 #include <ncurses/ncurses.h>
00037 #elif defined (HAVE_NCURSES_H)
00038 #include <ncurses.h>
00039 #elif defined (HAVE_CURSESX_H)
00040 #include <cursesX.h>
00041 #elif defined (HAVE_CURSES_H)
00042 #include <curses.h>
00043 #endif
00044 
00045 #if defined (HAVE_NCURSES_TERM_H)
00046 #include <ncurses/term.h>
00047 #elif defined (HAVE_TERM_H)
00048 #include <term.h>
00049 #else
00050 /* On MinGW, a real termcap library is usually not present.  Stub versions
00051    of the termcap functions will be built from windows-termcap.c.  Readline
00052    provides its own extern declarations when there's no termcap.h; do the
00053    same here for the termcap functions used in GDB.  */
00054 extern int tgetnum (const char *);
00055 #endif
00056 
00057 #endif /* gdb_curses.h */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines