This doesn't check the validity of composition. */
-int
+bool
find_composition (ptrdiff_t pos, ptrdiff_t limit,
ptrdiff_t *start, ptrdiff_t *end,
Lisp_Object *prop, Lisp_Object object)
Lisp_Object, Lisp_Object,
Lisp_Object);
-int
+bool
composition_gstring_p (Lisp_Object gstring)
{
Lisp_Object header;
autocmp_chars (Lisp_Object rule, ptrdiff_t charpos, ptrdiff_t bytepos, ptrdiff_t limit, struct window *win, struct face *face, Lisp_Object string)
{
ptrdiff_t count = SPECPDL_INDEX ();
- FRAME_PTR f = XFRAME (WGET (win, frame));
+ FRAME_PTR f = XFRAME (win->frame);
Lisp_Object pos = make_number (charpos);
ptrdiff_t to;
ptrdiff_t pt = PT, pt_byte = PT_BYTE;
}
else
#endif /* not HAVE_WINDOW_SYSTEM */
- font_object = WGET (win, frame);
+ font_object = win->frame;
lgstring = Fcomposition_get_gstring (pos, make_number (to), font_object,
string);
if (NILP (LGSTRING_ID (lgstring)))
string. In that case, FACE must not be NULL.
If the character is composed, setup members of CMP_IT (id, nglyphs,
- from, to, reversed_p), and return 1. Otherwise, update
- CMP_IT->stop_pos, and return 0. */
+ from, to, reversed_p), and return true. Otherwise, update
+ CMP_IT->stop_pos, and return false. */
-int
-composition_reseat_it (struct composition_it *cmp_it, ptrdiff_t charpos, ptrdiff_t bytepos, ptrdiff_t endpos, struct window *w, struct face *face, Lisp_Object string)
+bool
+composition_reseat_it (struct composition_it *cmp_it, ptrdiff_t charpos,
+ ptrdiff_t bytepos, ptrdiff_t endpos, struct window *w,
+ struct face *face, Lisp_Object string)
{
if (endpos < 0)
endpos = NILP (string) ? BEGV : 0;
/* This is like find_composition, but find an automatic composition
instead. It is assured that POS is not within a static
composition. If found, set *GSTRING to the glyph-string
- representing the composition, and return 1. Otherwise, *GSTRING to
- Qnil, and return 0. */
+ representing the composition, and return true. Otherwise, *GSTRING to
+ Qnil, and return false. */
-static int
+static bool
find_automatic_composition (ptrdiff_t pos, ptrdiff_t limit,
ptrdiff_t *start, ptrdiff_t *end,
Lisp_Object *gstring, Lisp_Object string)
int c;
Lisp_Object window;
struct window *w;
- int need_adjustment = 0;
+ bool need_adjustment = 0;
window = Fget_buffer_window (Fcurrent_buffer (), Qnil);
if (NILP (window))