]> code.delx.au - gnu-emacs/blobdiff - src/font.h
(fast_looking_at): New function.
[gnu-emacs] / src / font.h
index 12781d953842b1986b272a8d29f84a1d0821d728..fb66c167efeb5a022fea491eab91a0bec936b554 100644 (file)
@@ -1,6 +1,6 @@
 /* font.h -- Interface definition for font handling.
-   Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc.
-   Copyright (C) 2006, 2007, 2008
+   Copyright (C) 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
+   Copyright (C) 2006, 2007, 2008, 2009
      National Institute of Advanced Industrial Science and Technology (AIST)
      Registration Number H13PRO009
 
@@ -547,10 +547,10 @@ struct font_driver
   void (*done_face) P_ ((FRAME_PTR f, struct face *face));
 
   /* Optional.
-     If FONT_ENTITY has a glyph for character C (Unicode code point),
-     return 1.  If not, return 0.  If a font must be opened to check
-     it, return -1.  */
-  int (*has_char) P_ ((Lisp_Object entity, int c));
+     If FONT (FONT-ENTITY or FONT-OBJECT) has a glyph for character C
+     (Unicode code point), return 1.  If not, return 0.  If FONT is
+     FONT-ENTITY and it must be opened to check it, return -1.  */
+  int (*has_char) P_ ((Lisp_Object font, int c));
 
   /* Return a glyph code of FONT for characer C (Unicode code point).
      If FONT doesn't have such a glyph, return FONT_INVALID_CODE.  */
@@ -653,8 +653,18 @@ struct font_driver
   /* Optional.
 
      If FONT is usable on frame F, return 0.  Otherwise return -1.
-   */
+     This method is used only for debugging.  If this method is NULL,
+     Emacs assumes that the font is usable on any frame.  */
   int (*check) P_ ((FRAME_PTR F, struct font *font));
+
+  /* Optional.
+
+     Return the number of variation glyphs of character C supported by
+     FONT.  VARIATIONS is an array of 256 elements.  If the variation
+     selector N (1..256) defines a glyph, that glyph code is stored in
+     the (N-1)th element of VARIATIONS.  */
+  int (*get_variation_glyphs) P_ ((struct font *font,
+                                  int c, unsigned variations[256]));
 };