/* 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
/* Miscellanea. */
+#include "lisp.h"
#include "systime.h" /* for Time */
+struct glyph;
+
INLINE_HEADER_BEGIN
enum scroll_bar_part {
, 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
};
+/* 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. */
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;
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. */
void (*delete_glyphs_hook) (struct frame *, int);
void (*ring_bell_hook) (struct frame *f);
- void (*toggle_invisible_pointer_hook) (struct frame *f, int invisible);
+ void (*toggle_invisible_pointer_hook) (struct frame *f, bool invisible);
void (*reset_terminal_modes_hook) (struct terminal *);
void (*set_terminal_modes_hook) (struct terminal *);
support overlapping frames, so there's no need to raise or lower
anything.
- If RAISE_FLAG is non-zero, F is brought to the front, before all other
- windows. If RAISE_FLAG is zero, F is sent to the back, behind all other
+ If RAISE_FLAG, F is brought to the front, before all other
+ windows. If !RAISE_FLAG, F is sent to the back, behind all other
windows. */
- void (*frame_raise_lower_hook) (struct frame *f, int raise_flag);
+ void (*frame_raise_lower_hook) (struct frame *f, bool raise_flag);
/* If the value of the frame parameter changed, this hook is called.
For example, if going from fullscreen to not fullscreen this hook
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;