]> code.delx.au - gnu-emacs/blobdiff - src/termhooks.h
Add a cross ref to Optional Mode Line
[gnu-emacs] / src / termhooks.h
index 137e77ac2eff62b33bd9e7d52fc36e474d545202..d21d6ce588a17d6b371f2b13e3c018d399513d40 100644 (file)
@@ -1,14 +1,14 @@
 /* Parameters and display hooks for terminal devices.
 
-Copyright (C) 1985-1986, 1993-1994, 2001-2014 Free Software Foundation,
+Copyright (C) 1985-1986, 1993-1994, 2001-2016 Free Software Foundation,
 Inc.
 
 This file is part of GNU Emacs.
 
 GNU Emacs is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
-the Free Software Foundation, either version 3 of the License, or
-(at your option) any later version.
+the Free Software Foundation, either version 3 of the License, or (at
+your option) any later version.
 
 GNU Emacs is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -23,8 +23,11 @@ along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.  */
 
 /* Miscellanea.   */
 
+#include "lisp.h"
 #include "systime.h" /* for Time */
 
+struct glyph;
+
 INLINE_HEADER_BEGIN
 
 enum scroll_bar_part {
@@ -236,6 +239,11 @@ enum event_kind
   , NS_NONKEY_EVENT
 #endif
 
+#ifdef HAVE_XWIDGETS
+  /* events generated by xwidgets*/
+   , XWIDGET_EVENT
+#endif
+
 #ifdef USE_FILE_NOTIFY
   /* File or directory was changed.  */
   , FILE_NOTIFY_EVENT
@@ -243,6 +251,9 @@ enum event_kind
 
 };
 
+/* Bit width of an enum event_kind tag at the start of structs and unions.  */
+enum { EVENT_KIND_WIDTH = 16 };
+
 /* If a struct input_event has a kind which is SELECTION_REQUEST_EVENT
    or SELECTION_CLEAR_EVENT, then its contents are really described
    by `struct selection_input_event'; see xterm.h.  */
@@ -255,7 +266,7 @@ enum event_kind
 struct input_event
 {
   /* What kind of event was this?  */
-  ENUM_BF (event_kind) kind : 16;
+  ENUM_BF (event_kind) kind : EVENT_KIND_WIDTH;
 
   /* Used in scroll back click events.  */
   ENUM_BF (scroll_bar_part) part : 16;
@@ -380,6 +391,11 @@ struct terminal
     the selection-values.  */
   Lisp_Object Vselection_alist;
 
+  /* If a char-table, this maps characters to terminal glyph codes.
+     If t, the mapping is not available.  If nil, it is not known
+     whether the mapping is available.  */
+  Lisp_Object glyph_code_table;
+
   /* All fields before `next_terminal' should be Lisp_Object and are traced
      by the GC.  All fields afterwards are ignored by the GC.  */
 
@@ -687,6 +703,7 @@ extern struct terminal *get_named_terminal (const char *);
 extern struct terminal *create_terminal (enum output_method,
                                         struct redisplay_interface *);
 extern void delete_terminal (struct terminal *);
+extern Lisp_Object terminal_glyph_code (struct terminal *, int);
 
 /* The initial terminal device, created by initial_term_init.  */
 extern struct terminal *initial_terminal;