Commit 9910e595 authored by Paul Eggert's avatar Paul Eggert

GLYPH_CODE_FACE returns EMACS_INT, not int.

* dispextern.h (merge_faces):
* xfaces.c (merge_faces):
* xdisp.c (get_next_display_element):
(next_element_from_display_vector): Don't assume EMACS_INT fits in int.
parent 2638320e
2011-06-13 Paul Eggert <eggert@cs.ucla.edu>
GLYPH_CODE_FACE returns EMACS_INT, not int.
* dispextern.h (merge_faces):
* xfaces.c (merge_faces):
* xdisp.c (get_next_display_element):
(next_element_from_display_vector): Don't assume EMACS_INT fits in int.
* character.h (CHAR_VALID_P): Remove unused parameter.
* fontset.c, lisp.h, xdisp.c: All uses changed.
......
......@@ -3163,7 +3163,7 @@ int face_at_string_position (struct window *w, Lisp_Object string,
EMACS_INT pos, EMACS_INT bufpos,
EMACS_INT region_beg, EMACS_INT region_end,
EMACS_INT *endptr, enum face_id, int mouse);
int merge_faces (struct frame *, Lisp_Object, int, int);
int merge_faces (struct frame *, Lisp_Object, EMACS_INT, int);
int compute_char_face (struct frame *, int, Lisp_Object);
void free_all_realized_faces (Lisp_Object);
extern Lisp_Object Qforeground_color, Qbackground_color;
......
......@@ -5819,7 +5819,8 @@ get_next_display_element (struct it *it)
display. Then, set IT->dpvec to these glyphs. */
Lisp_Object gc;
int ctl_len;
int face_id, lface_id = 0 ;
int face_id;
EMACS_INT lface_id = 0;
int escape_glyph;
/* Handle control characters with ^. */
......@@ -6374,7 +6375,7 @@ next_element_from_display_vector (struct it *it)
it->face_id = it->dpvec_face_id;
else
{
int lface_id = GLYPH_CODE_FACE (gc);
EMACS_INT lface_id = GLYPH_CODE_FACE (gc);
if (lface_id > 0)
it->face_id = merge_faces (it->f, Qt, lface_id,
it->saved_face_id);
......
......@@ -6223,7 +6223,8 @@ face_at_string_position (struct window *w, Lisp_Object string,
*/
int
merge_faces (struct frame *f, Lisp_Object face_name, int face_id, int base_face_id)
merge_faces (struct frame *f, Lisp_Object face_name, EMACS_INT face_id,
int base_face_id)
{
Lisp_Object attrs[LFACE_VECTOR_SIZE];
struct face *base_face;
......
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