Commit 0bd4cc79 authored by Kenichi Handa's avatar Kenichi Handa

(LGLYPH_FROM, LGLYPH_TO, LGLYPH_SET_FROM)

(LGLYPH_SET_TO): New macros.
(LGLYPH_XOFF, LGLYPH_YOFF, LGLYPH_WADJUST): Check if adjustment
element of G is vector or not.
(font_at): Extern it.
parent 10d16101
......@@ -255,21 +255,25 @@ struct composition;
#define LGSTRING_LENGTH(lgs) (ASIZE ((lgs)) - 1)
#define LGSTRING_GLYPH(lgs, idx) AREF ((lgs), (idx) + 1)
#define LGLYPH_FROM(g) AREF ((g), 0)
#define LGLYPH_TO(g) AREF ((g), 1)
#define LGLYPH_CHAR(g) AREF ((g), 2)
#define LGLYPH_CODE(g) AREF ((g), 3)
#define LGLYPH_WIDTH(g) AREF ((g), 4)
#define LGLYPH_ADJUSTMENT(g) AREF ((g), 5)
#define LGLYPH_SET_FROM(g, val) ASET ((g), 0, (val))
#define LGLYPH_SET_TO(g, val) ASET ((g), 1, (val))
#define LGLYPH_SET_CHAR(g, val) ASET ((g), 2, (val))
#define LGLYPH_SET_CODE(g, val) ASET ((g), 3, (val))
#define LGLYPH_SET_WIDTH(g, val) ASET ((g), 4, (val))
#define LGLYPH_SET_ADJUSTMENT(g, val) ASET ((g), 5, (val))
#define LGLYPH_XOFF(g) (NILP (LGLYPH_ADJUSTMENT (g)) ? 0 \
: XINT (AREF (LGLYPH_ADJUSTMENT (g), 0)))
#define LGLYPH_YOFF(g) (NILP (LGLYPH_ADJUSTMENT (g)) ? 0 \
: XINT (AREF (LGLYPH_ADJUSTMENT (g), 1)))
#define LGLYPH_WADJUST(g) (NILP (LGLYPH_ADJUSTMENT (g)) ? 0 \
: XINT (AREF (LGLYPH_ADJUSTMENT (g), 2)))
#define LGLYPH_XOFF(g) (VECTORP (LGLYPH_ADJUSTMENT (g)) \
? XINT (AREF (LGLYPH_ADJUSTMENT (g), 0)) : 0)
#define LGLYPH_YOFF(g) (VECTORP (LGLYPH_ADJUSTMENT (g)) \
? XINT (AREF (LGLYPH_ADJUSTMENT (g), 1)) : 0)
#define LGLYPH_WADJUST(g) (VECTORP (LGLYPH_ADJUSTMENT (g)) \
? XINT (AREF (LGLYPH_ADJUSTMENT (g), 2)) : 0)
#define FONT_INVALID_CODE 0xFFFFFFFF
......@@ -470,6 +474,8 @@ extern int font_unparse_fcname P_ ((Lisp_Object font, int pixel_size,
char *name, int bytes));
extern void register_font_driver P_ ((struct font_driver *driver, FRAME_PTR f));
extern void free_font_driver_list P_ ((FRAME_PTR f));
extern Lisp_Object font_at P_ ((int c, EMACS_INT pos, struct face *face,
struct window *w, Lisp_Object object));
extern struct font *font_prepare_composition P_ ((struct composition *cmp));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment