]> code.delx.au - gnu-emacs/blobdiff - src/frame.h
Merge from emacs--devo--0
[gnu-emacs] / src / frame.h
index 290aed3266ecb4417f84f9ca1c29318e9fa2699d..db60700c5ad07a635e970340cb808245735ccb5c 100644 (file)
@@ -1,5 +1,6 @@
 /* Define frame-object for GNU Emacs.
-   Copyright (C) 1993, 1994, 1999, 2000, 2001 Free Software Foundation, Inc.
+   Copyright (C) 1993, 1994, 1999, 2000, 2001, 2002, 2003, 2004,
+                 2005, 2006, 2007 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -71,7 +72,7 @@ enum text_cursor_kinds
 
 #if !defined(HAVE_X_WINDOWS)
 
-#define PIX_TYPE int
+#define PIX_TYPE unsigned long
 
 /* A (mostly empty) x_output structure definition for building Emacs
    on Unix and GNU/Linux without X support.  */
@@ -92,6 +93,10 @@ extern struct x_output tty_display;
 
 #endif /* ! MSDOS && ! WINDOWSNT && ! MAC_OS */
 
+#ifdef USE_FONT_BACKEND
+struct font_driver_list;
+#endif /* USE_FONT_BACKEND */
+
 struct frame
 {
   EMACS_INT size;
@@ -221,6 +226,7 @@ struct frame
   /* Margin at the top of the frame.  Used to display the tool-bar.  */
   int tool_bar_lines;
 
+  int n_tool_bar_rows;
   int n_tool_bar_items;
 
   /* A buffer for decode_mode_line. */
@@ -254,6 +260,9 @@ struct frame
   /* Size of the frame window in pixels.  */
   int pixel_height, pixel_width;
 
+  /* Dots per inch of the screen the frame is on.  */
+  double resx, resy;
+
   /* These many pixels are the difference between the outer window (i.e. the
      left and top of the window manager decoration) and FRAME_X_WINDOW. */
   int x_pixels_diff, y_pixels_diff;
@@ -299,6 +308,11 @@ struct frame
   }
   output_data;
 
+#ifdef USE_FONT_BACKEND
+  /* List of font-drivers available on the frame. */
+  struct font_driver_list *font_driver_list;
+#endif /* USE_FONT_BACKEND */
+
   /* Total width of fringes reserved for drawing truncation bitmaps,
      continuation bitmaps and alike.  The width is in canonical char
      units of the frame.  This must currently be the case because window
@@ -467,6 +481,13 @@ struct frame
   /* Set to non-zero if this frame has already been hscrolled during
      current redisplay.  */
   unsigned already_hscrolled_p : 1;
+
+  /* Set to non-zero when current redisplay has updated frame.  */
+  unsigned updated_p : 1;
+
+  /* Set to non-zero to minimize tool-bar height even when
+     auto-resize-tool-bar is set to grow-only.  */
+  unsigned minimize_tool_bar_window_p : 1;
 };
 
 #ifdef MULTI_KBOARD
@@ -755,18 +776,11 @@ typedef struct frame *FRAME_PTR;
    (f)->visible = (f)->async_visible, \
    (f)->iconified = (f)->async_iconified)
 
-#define CHECK_FRAME(x)                                 \
-     do {                                              \
-       if (! FRAMEP (x))                               \
-         x = wrong_type_argument (Qframep, (x));       \
-     } while (0)
+#define CHECK_FRAME(x) \
+  CHECK_TYPE (FRAMEP (x), Qframep, x)
 
-#define CHECK_LIVE_FRAME(x)                            \
-     do {                                              \
-       if (! FRAMEP (x)                                        \
-          || ! FRAME_LIVE_P (XFRAME (x)))              \
-         x = wrong_type_argument (Qframe_live_p, (x)); \
-     } while (0)
+#define CHECK_LIVE_FRAME(x) \
+  CHECK_TYPE (FRAMEP (x) && FRAME_LIVE_P (XFRAME (x)), Qframe_live_p, x)
 
 /* FOR_EACH_FRAME (LIST_VAR, FRAME_VAR) followed by a statement is a
    `for' loop which iterates over the elements of Vframe_list.  The
@@ -1007,6 +1021,7 @@ extern Lisp_Object Qscreen_gamma;
 extern Lisp_Object Qline_spacing;
 extern Lisp_Object Qwait_for_wm;
 extern Lisp_Object Qfullscreen;
+extern Lisp_Object Qfont_backend;
 
 extern Lisp_Object Qleft_fringe, Qright_fringe;
 extern Lisp_Object Qheight, Qwidth;
@@ -1046,7 +1061,9 @@ extern void x_wm_set_icon_position P_ ((struct frame *, int, int));
 
 extern Lisp_Object x_new_font P_ ((struct frame *, char *));
 extern Lisp_Object x_new_fontset P_ ((struct frame *, Lisp_Object));
-
+#ifdef USE_FONT_BACKEND
+extern Lisp_Object x_new_fontset2 P_ ((struct frame *, int, Lisp_Object));
+#endif /* USE_FONT_BACKEND */
 
 /* These are in frame.c  */
 
@@ -1066,6 +1083,7 @@ extern void x_set_fullscreen P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_line_spacing P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_screen_gamma P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_font P_ ((struct frame *, Lisp_Object, Lisp_Object));
+extern void x_set_font_backend P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_fringe_width P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_border_width P_ ((struct frame *, Lisp_Object, Lisp_Object));
 extern void x_set_internal_border_width P_ ((struct frame *, Lisp_Object,