]> code.delx.au - gnu-emacs/commitdiff
(mac_atsu_font_face_attributes) [USE_ATSUI]: Add extern.
authorYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Fri, 15 Dec 2006 08:05:18 +0000 (08:05 +0000)
committerYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Fri, 15 Dec 2006 08:05:18 +0000 (08:05 +0000)
(Fmac_atsu_font_face_attributes) [USE_ATSUI]: New function.
(syms_of_macfns) [USE_ATSUI]: Defsubr it.

src/macfns.c

index 2df3b4e203e2bd69be33d2e003a3ff278eaab48e..521156a0de60920d921acbd116fd4ca20db934c6 100644 (file)
@@ -4597,6 +4597,30 @@ This is for internal use only.  Use `mac-font-panel-mode' instead.  */)
   return Qnil;
 }
 #endif
+
+#if USE_ATSUI
+extern Lisp_Object mac_atsu_font_face_attributes P_ ((ATSUFontID));
+
+DEFUN ("mac-atsu-font-face-attributes", Fmac_atsu_font_face_attributes,
+       Smac_atsu_font_face_attributes, 1, 1, 0,
+  doc: /* Return plist of face attributes and values for ATSU font ID.
+ID is specified by either an integer or a float.  */)
+     (id)
+     Lisp_Object id;
+{
+  ATSUFontID font_id;
+  Lisp_Object result;
+
+  check_mac ();
+  CHECK_NUMBER_OR_FLOAT(id);
+  font_id = NUMBERP (id) ? XINT (id) : (ATSUFontID) XFLOAT (id);
+  BLOCK_INPUT;
+  result = mac_atsu_font_face_attributes (font_id);
+  UNBLOCK_INPUT;
+  return result;
+}
+#endif
+
 \f
 /***********************************************************************
                            Initialization
@@ -4829,6 +4853,9 @@ Chinese, Japanese, and Korean.  */);
 #if USE_MAC_FONT_PANEL
   defsubr (&Smac_set_font_panel_visibility);
 #endif
+#if USE_ATSUI
+  defsubr (&Smac_atsu_font_face_attributes);
+#endif
 }
 
 /* arch-tag: d7591289-f374-4377-b245-12f5dbbb8edc