]> code.delx.au - gnu-emacs/blobdiff - src/frame.h
(Fget_char_property): Update call to overlays_at.
[gnu-emacs] / src / frame.h
index 442a0e32ac5943ae58d338b090a3c0cc3e828384..729cbf9e577eb1910dfc41ab886f145b642fdbc2 100644 (file)
@@ -55,6 +55,33 @@ enum vertical_scroll_bar_type
   vertical_scroll_bar_right
 };
 
+#if !defined(MSDOS) && !defined(WINDOWSNT) && !defined(macintosh)
+
+#if !defined(HAVE_X_WINDOWS)
+
+#define PIX_TYPE int
+
+/* A (mostly empty) x_output structure definition for building Emacs
+   on Unix and GNU/Linux without X support.  */
+struct x_output
+{
+  PIX_TYPE background_pixel;
+  PIX_TYPE foreground_pixel;
+};
+
+#define FRAME_INTERNAL_BORDER_WIDTH(f) 0
+
+#endif /* ! HAVE_X_WINDOWS */
+
+
+#define FRAME_FOREGROUND_PIXEL(f) ((f)->output_data.x->foreground_pixel)
+#define FRAME_BACKGROUND_PIXEL(f) ((f)->output_data.x->background_pixel)
+
+/* A structure describing a termcap frame display.  */
+extern struct x_output tty_display;
+
+#endif /* ! MSDOS && ! WINDOWSNT && ! macintosh */
+
 struct frame
 {
   EMACS_INT size;
@@ -273,16 +300,10 @@ struct frame
   /* Asynchronous input handlers change these, and
      FRAME_SAMPLE_VISIBILITY copies them into visible and iconified.
      See FRAME_SAMPLE_VISIBILITY, below.  */
-#ifdef __STDC__
-  volatile
-#endif
-  char async_visible, async_iconified;
+  volatile char async_visible, async_iconified;
 
   /* Nonzero if this frame should be redrawn.  */
-#ifdef __STDC__
-  volatile
-#endif
-  char garbaged;
+  volatile char garbaged;
 
   /* True if frame actually has a minibuffer window on it.
      0 if using a minibuffer window that isn't on this frame.  */
@@ -338,11 +359,6 @@ struct frame
   /* The baud rate that was used to calculate costs for this frame.  */
   int cost_calculation_baud_rate;
 
-  /* A pointer to the data structure containing all information of
-     fontsets associated with this frame.  See the comments in
-     fontset.h for more detail.  */
-  struct fontset_data *fontset_data;
-
   /* Nonzero if the mouse has moved on this display
      since the last time we checked.  */
   char mouse_moved;
@@ -351,6 +367,9 @@ struct frame
      SCREEN_GAMMA) where viewing_gamma is 0.4545 and SCREEN_GAMMA is a
      frame parameter.  0 means don't do gamma correction.  */
   double gamma;
+
+  /* Additional space to put between text lines on this frame.  */
+  int extra_line_spacing;
 };
 
 #ifdef MULTI_KBOARD
@@ -361,7 +380,7 @@ struct frame
 
 typedef struct frame *FRAME_PTR;
 
-#define XFRAME(p) ((struct frame *) XPNTR (p))
+#define XFRAME(p) (eassert (GC_FRAMEP(p)),(struct frame *) XPNTR (p))
 #define XSETFRAME(a, b) (XSETPSEUDOVECTOR (a, b, PVEC_FRAME))
 
 /* Given a window, return its frame as a Lisp_Object.  */
@@ -539,7 +558,6 @@ typedef struct frame *FRAME_PTR;
 #define FRAME_CONDEMNED_SCROLL_BARS(f) ((f)->condemned_scroll_bars)
 #define FRAME_MENU_BAR_ITEMS(f) ((f)->menu_bar_items)
 #define FRAME_COST_BAUD_RATE(f) ((f)->cost_calculation_baud_rate)
-#define FRAME_FONTSET_DATA(f) ((f)->fontset_data)
 
 /* Return a pointer to the face cache of frame F.  */
 
@@ -581,19 +599,18 @@ typedef struct frame *FRAME_PTR;
    (f)->visible = (f)->async_visible, \
    (f)->iconified = (f)->async_iconified)
 
-#define CHECK_FRAME(x, i)                      \
-     if (! FRAMEP (x))                         \
-       x = wrong_type_argument (Qframep, (x)); \
-     else                                      \
-       (void) 0
+#define CHECK_FRAME(x, i)                              \
+     do {                                              \
+       if (! FRAMEP (x))                               \
+         x = wrong_type_argument (Qframep, (x));       \
+     } while (0)
 
 #define CHECK_LIVE_FRAME(x, i)                         \
-     if (! FRAMEP (x)                                  \
-        || ! FRAME_LIVE_P (XFRAME (x)))                \
-       x = wrong_type_argument (Qframe_live_p, (x));   \
-     else                                              \
-       (void) 0
-
+     do {                                              \
+       if (! FRAMEP (x)                                        \
+          || ! FRAME_LIVE_P (XFRAME (x)))              \
+         x = wrong_type_argument (Qframe_live_p, (x)); \
+     } while (0)
 
 /* FOR_EACH_FRAME (LIST_VAR, FRAME_VAR) followed by a statement is a
    `for' loop which iterates over the elements of Vframe_list.  The
@@ -659,13 +676,13 @@ extern Lisp_Object Vterminal_frame;
 extern Lisp_Object selected_frame;
 
 /* Value is a pointer to the selected frame.  If the selected frame
-   isn't life, abort.  */
+   isn't live, abort.  */
 
 #define SELECTED_FRAME()                               \
      ((FRAMEP (selected_frame)                         \
        && FRAME_LIVE_P (XFRAME (selected_frame)))      \
       ? XFRAME (selected_frame)                                \
-      : (struct frame *) (abort (), 0))
+      : (abort (), (struct frame *) 0))
 
 \f
 /***********************************************************************