diff options
| author | Karoly Lorentey | 2004-12-10 15:24:54 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2004-12-10 15:24:54 +0000 |
| commit | 4b89585ee70a1f64543a5851f07cf7e2d89c5c62 (patch) | |
| tree | 95c1775b6b83816892f010472c1a6d7e043b5ea7 /src | |
| parent | 97b977dbee4174dedbe2cfcb3e52d4e9c3c3cec9 (diff) | |
| parent | 593b351755c02c2f32c6717a026d12facf558ea8 (diff) | |
| download | emacs-4b89585ee70a1f64543a5851f07cf7e2d89c5c62.tar.gz emacs-4b89585ee70a1f64543a5851f07cf7e2d89c5c62.zip | |
Merged in changes from CVS trunk.
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-720
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-721
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-722
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-723
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-724
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-725
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-276
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 14 | ||||
| -rw-r--r-- | src/image.c | 14 | ||||
| -rw-r--r-- | src/xdisp.c | 40 |
3 files changed, 55 insertions, 13 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 28030aef0e3..38a079989be 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,17 @@ | |||
| 1 | 2004-12-08 Richard M. Stallman <rms@gnu.org> | ||
| 2 | |||
| 3 | * xdisp.c (get_next_display_element): Use `escape-glyph' for | ||
| 4 | control chars and escaped octal codes. | ||
| 5 | (Qescape_glyph): New variable. | ||
| 6 | (syms_of_xdisp): Initialize it. | ||
| 7 | (escape_glyph_face): New variable. | ||
| 8 | (redisplay_window): Initialize it. | ||
| 9 | |||
| 10 | 2004-12-07 Paul Eggert <eggert@cs.ucla.edu> | ||
| 11 | |||
| 12 | * image.c (our_fill_input_buffer, jpeg_load, CHECK_LIB_AVAILABLE) | ||
| 13 | (init_image): Use 1 rather than TRUE. TRUE's not always defined. | ||
| 14 | |||
| 1 | 2004-12-07 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> | 15 | 2004-12-07 Jan Dj,Ad(Brv <jan.h.d@swipnet.se> |
| 2 | 16 | ||
| 3 | * emacs.c (Fdump_emacs): Add ! defined (SYSTEM_MALLOC) around | 17 | * emacs.c (Fdump_emacs): Add ! defined (SYSTEM_MALLOC) around |
diff --git a/src/image.c b/src/image.c index d1925cf36e4..18ffc2db3a4 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -6378,7 +6378,7 @@ our_fill_input_buffer (cinfo) | |||
| 6378 | 6378 | ||
| 6379 | src->next_input_byte = buffer; | 6379 | src->next_input_byte = buffer; |
| 6380 | src->bytes_in_buffer = 2; | 6380 | src->bytes_in_buffer = 2; |
| 6381 | return TRUE; | 6381 | return 1; |
| 6382 | } | 6382 | } |
| 6383 | 6383 | ||
| 6384 | 6384 | ||
| @@ -6533,11 +6533,11 @@ jpeg_load (f, img) | |||
| 6533 | jpeg_memory_src (&cinfo, SDATA (specified_data), | 6533 | jpeg_memory_src (&cinfo, SDATA (specified_data), |
| 6534 | SBYTES (specified_data)); | 6534 | SBYTES (specified_data)); |
| 6535 | 6535 | ||
| 6536 | fn_jpeg_read_header (&cinfo, TRUE); | 6536 | fn_jpeg_read_header (&cinfo, 1); |
| 6537 | 6537 | ||
| 6538 | /* Customize decompression so that color quantization will be used. | 6538 | /* Customize decompression so that color quantization will be used. |
| 6539 | Start decompression. */ | 6539 | Start decompression. */ |
| 6540 | cinfo.quantize_colors = TRUE; | 6540 | cinfo.quantize_colors = 1; |
| 6541 | fn_jpeg_start_decompress (&cinfo); | 6541 | fn_jpeg_start_decompress (&cinfo); |
| 6542 | width = img->width = cinfo.output_width; | 6542 | width = img->width = cinfo.output_width; |
| 6543 | height = img->height = cinfo.output_height; | 6543 | height = img->height = cinfo.output_height; |
| @@ -7552,7 +7552,7 @@ gif_load (f, img) | |||
| 7552 | bg_color.blue = color.blue; | 7552 | bg_color.blue = color.blue; |
| 7553 | RGBBackColor (&bg_color); | 7553 | RGBBackColor (&bg_color); |
| 7554 | SetGWorld (old_port, old_gdh); | 7554 | SetGWorld (old_port, old_gdh); |
| 7555 | SetMovieActive (movie, TRUE); | 7555 | SetMovieActive (movie, 1); |
| 7556 | SetMovieGWorld (movie, ximg, NULL); | 7556 | SetMovieGWorld (movie, ximg, NULL); |
| 7557 | SampleNumToMediaTime (media, ino + 1, &time, NULL); | 7557 | SampleNumToMediaTime (media, ino + 1, &time, NULL); |
| 7558 | SetMovieTimeValue (movie, time); | 7558 | SetMovieTimeValue (movie, time); |
| @@ -7930,7 +7930,7 @@ DEFUN ("lookup-image", Flookup_image, Slookup_image, 1, 1, 0, "") | |||
| 7930 | define_image_type (image_type, init_lib_fn (libraries)) | 7930 | define_image_type (image_type, init_lib_fn (libraries)) |
| 7931 | #else | 7931 | #else |
| 7932 | #define CHECK_LIB_AVAILABLE(image_type, init_lib_fn, libraries) \ | 7932 | #define CHECK_LIB_AVAILABLE(image_type, init_lib_fn, libraries) \ |
| 7933 | define_image_type (image_type, TRUE) | 7933 | define_image_type (image_type, 1) |
| 7934 | #endif /* HAVE_NTGUI */ | 7934 | #endif /* HAVE_NTGUI */ |
| 7935 | 7935 | ||
| 7936 | DEFUN ("init-image-library", Finit_image_library, Sinit_image_library, 2, 2, 0, | 7936 | DEFUN ("init-image-library", Finit_image_library, Sinit_image_library, 2, 2, 0, |
| @@ -8114,8 +8114,8 @@ init_image () | |||
| 8114 | { | 8114 | { |
| 8115 | image_types = NULL; | 8115 | image_types = NULL; |
| 8116 | 8116 | ||
| 8117 | define_image_type (&xbm_type, TRUE); | 8117 | define_image_type (&xbm_type, 1); |
| 8118 | define_image_type (&pbm_type, TRUE); | 8118 | define_image_type (&pbm_type, 1); |
| 8119 | 8119 | ||
| 8120 | #ifdef MAC_OS | 8120 | #ifdef MAC_OS |
| 8121 | /* Animated gifs use QuickTime Movie Toolbox. So initialize it here. */ | 8121 | /* Animated gifs use QuickTime Movie Toolbox. So initialize it here. */ |
diff --git a/src/xdisp.c b/src/xdisp.c index eef40a1b5e4..c58e8088141 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -342,6 +342,11 @@ Lisp_Object Vvoid_text_area_pointer; | |||
| 342 | 342 | ||
| 343 | Lisp_Object Qtrailing_whitespace; | 343 | Lisp_Object Qtrailing_whitespace; |
| 344 | 344 | ||
| 345 | /* Name and number of the face used to highlight escape glyphs. */ | ||
| 346 | |||
| 347 | Lisp_Object Qescape_glyph; | ||
| 348 | int escape_glyph_face; | ||
| 349 | |||
| 345 | /* The symbol `image' which is the car of the lists used to represent | 350 | /* The symbol `image' which is the car of the lists used to represent |
| 346 | images in Lisp. */ | 351 | images in Lisp. */ |
| 347 | 352 | ||
| @@ -4921,6 +4926,21 @@ get_next_display_element (it) | |||
| 4921 | display. Then, set IT->dpvec to these glyphs. */ | 4926 | display. Then, set IT->dpvec to these glyphs. */ |
| 4922 | GLYPH g; | 4927 | GLYPH g; |
| 4923 | int ctl_len; | 4928 | int ctl_len; |
| 4929 | int face_id = escape_glyph_face; | ||
| 4930 | |||
| 4931 | /* Find the face id if `escape-glyph' unless we recently did. */ | ||
| 4932 | if (face_id < 0) | ||
| 4933 | { | ||
| 4934 | Lisp_Object tem = Fget (Qescape_glyph, Qface); | ||
| 4935 | if (INTEGERP (tem)) | ||
| 4936 | face_id = XINT (tem); | ||
| 4937 | else | ||
| 4938 | face_id = 0; | ||
| 4939 | /* If there's overflow, use 0 instead. */ | ||
| 4940 | if (FAST_GLYPH_FACE (FAST_MAKE_GLYPH (0, face_id)) != face_id) | ||
| 4941 | face_id = 0; | ||
| 4942 | escape_glyph_face = face_id; | ||
| 4943 | } | ||
| 4924 | 4944 | ||
| 4925 | if (it->c < 128 && it->ctl_arrow_p) | 4945 | if (it->c < 128 && it->ctl_arrow_p) |
| 4926 | { | 4946 | { |
| @@ -4930,10 +4950,10 @@ get_next_display_element (it) | |||
| 4930 | && GLYPH_CHAR_VALID_P (XINT (DISP_CTRL_GLYPH (it->dp)))) | 4950 | && GLYPH_CHAR_VALID_P (XINT (DISP_CTRL_GLYPH (it->dp)))) |
| 4931 | g = XINT (DISP_CTRL_GLYPH (it->dp)); | 4951 | g = XINT (DISP_CTRL_GLYPH (it->dp)); |
| 4932 | else | 4952 | else |
| 4933 | g = FAST_MAKE_GLYPH ('^', 0); | 4953 | g = FAST_MAKE_GLYPH ('^', face_id); |
| 4934 | XSETINT (it->ctl_chars[0], g); | 4954 | XSETINT (it->ctl_chars[0], g); |
| 4935 | 4955 | ||
| 4936 | g = FAST_MAKE_GLYPH (it->c ^ 0100, 0); | 4956 | g = FAST_MAKE_GLYPH (it->c ^ 0100, face_id); |
| 4937 | XSETINT (it->ctl_chars[1], g); | 4957 | XSETINT (it->ctl_chars[1], g); |
| 4938 | ctl_len = 2; | 4958 | ctl_len = 2; |
| 4939 | } | 4959 | } |
| @@ -4950,7 +4970,7 @@ get_next_display_element (it) | |||
| 4950 | && GLYPH_CHAR_VALID_P (XFASTINT (DISP_ESCAPE_GLYPH (it->dp)))) | 4970 | && GLYPH_CHAR_VALID_P (XFASTINT (DISP_ESCAPE_GLYPH (it->dp)))) |
| 4951 | escape_glyph = XFASTINT (DISP_ESCAPE_GLYPH (it->dp)); | 4971 | escape_glyph = XFASTINT (DISP_ESCAPE_GLYPH (it->dp)); |
| 4952 | else | 4972 | else |
| 4953 | escape_glyph = FAST_MAKE_GLYPH ('\\', 0); | 4973 | escape_glyph = FAST_MAKE_GLYPH ('\\', face_id); |
| 4954 | 4974 | ||
| 4955 | if (SINGLE_BYTE_CHAR_P (it->c)) | 4975 | if (SINGLE_BYTE_CHAR_P (it->c)) |
| 4956 | str[0] = it->c, len = 1; | 4976 | str[0] = it->c, len = 1; |
| @@ -4977,11 +4997,14 @@ get_next_display_element (it) | |||
| 4977 | XSETINT (it->ctl_chars[i * 4], escape_glyph); | 4997 | XSETINT (it->ctl_chars[i * 4], escape_glyph); |
| 4978 | /* Insert three more glyphs into IT->ctl_chars for | 4998 | /* Insert three more glyphs into IT->ctl_chars for |
| 4979 | the octal display of the character. */ | 4999 | the octal display of the character. */ |
| 4980 | g = FAST_MAKE_GLYPH (((str[i] >> 6) & 7) + '0', 0); | 5000 | g = FAST_MAKE_GLYPH (((str[i] >> 6) & 7) + '0', |
| 5001 | face_id); | ||
| 4981 | XSETINT (it->ctl_chars[i * 4 + 1], g); | 5002 | XSETINT (it->ctl_chars[i * 4 + 1], g); |
| 4982 | g = FAST_MAKE_GLYPH (((str[i] >> 3) & 7) + '0', 0); | 5003 | g = FAST_MAKE_GLYPH (((str[i] >> 3) & 7) + '0', |
| 5004 | face_id); | ||
| 4983 | XSETINT (it->ctl_chars[i * 4 + 2], g); | 5005 | XSETINT (it->ctl_chars[i * 4 + 2], g); |
| 4984 | g = FAST_MAKE_GLYPH ((str[i] & 7) + '0', 0); | 5006 | g = FAST_MAKE_GLYPH ((str[i] & 7) + '0', |
| 5007 | face_id); | ||
| 4985 | XSETINT (it->ctl_chars[i * 4 + 3], g); | 5008 | XSETINT (it->ctl_chars[i * 4 + 3], g); |
| 4986 | } | 5009 | } |
| 4987 | ctl_len = len * 4; | 5010 | ctl_len = len * 4; |
| @@ -11579,6 +11602,9 @@ redisplay_window (window, just_this_one_p) | |||
| 11579 | *w->desired_matrix->method = 0; | 11602 | *w->desired_matrix->method = 0; |
| 11580 | #endif | 11603 | #endif |
| 11581 | 11604 | ||
| 11605 | /* Force this to be looked up again for each redisp of each window. */ | ||
| 11606 | escape_glyph_face = -1; | ||
| 11607 | |||
| 11582 | specbind (Qinhibit_point_motion_hooks, Qt); | 11608 | specbind (Qinhibit_point_motion_hooks, Qt); |
| 11583 | 11609 | ||
| 11584 | reconsider_clip_changes (w, buffer); | 11610 | reconsider_clip_changes (w, buffer); |
| @@ -22150,6 +22176,8 @@ syms_of_xdisp () | |||
| 22150 | staticpro (&Qfontification_functions); | 22176 | staticpro (&Qfontification_functions); |
| 22151 | Qtrailing_whitespace = intern ("trailing-whitespace"); | 22177 | Qtrailing_whitespace = intern ("trailing-whitespace"); |
| 22152 | staticpro (&Qtrailing_whitespace); | 22178 | staticpro (&Qtrailing_whitespace); |
| 22179 | Qescape_glyph = intern ("escape-glyph"); | ||
| 22180 | staticpro (&Qescape_glyph); | ||
| 22153 | Qimage = intern ("image"); | 22181 | Qimage = intern ("image"); |
| 22154 | staticpro (&Qimage); | 22182 | staticpro (&Qimage); |
| 22155 | QCmap = intern (":map"); | 22183 | QCmap = intern (":map"); |