(uninstall): Ignore exit code of `rm'.
[emacs.git] / src / ChangeLog
blob4efbe4c8b24c1c5fa9b5276ca6ebc806c858a451
1 2001-02-02  Gerd Moellmann  <gerd@gnu.org>
3         * xdisp.c (get_next_display_element): Fix case of empty
4         display table entry.
6 2001-02-02  Eli Zaretskii  <eliz@is.elta.co.il>
8         * editfns.c (Fconstrain_to_field): Doc fix.
10         * xfaces.c (Fclear_face_cache): Rename the `thorougly' argument
11         into `thoroughly', to make it consistent with the doc string.
13         * window.c (Fenlarge_window, Fshrink_window): Doc fix.
15 2001-02-01  Gerd Moellmann  <gerd@gnu.org>
17         * search.c (search_buffer): Call set_search_regs with a byte
18         position, not a character position.
20         * xfns.c (x_set_tool_bar_lines): Do nothing if frame is
21         minibuffer-only,
23 2001-02-01  Eli Zaretskii  <eliz@is.elta.co.il>
25         * frame.c (Fmodify_frame_parameters): Doc fix.
27 2001-01-31  Gerd Moellmann  <gerd@gnu.org>
29         * frame.h (EMACS_FRAME_H_INCLUDED): Use an include blocker
30         identifier which is not reserved by Standard C.
31         
32         * frame.h (FRAME_RIGHT_SCROLL_BAR_WIDTH): New define.
34         * window.c (enum window_part): New enumeration.
35         (Qleft_fringe, Qright_fringe): Replace Qleft_bitmap_area and
36         Qright_bitmap_area.
37         (coordinates_in_window): Return an enumerator from enum
38         window_part.  Fix handling of right scroll bar.
39         (Fcoordinates_in_window_p): Doc fix.  Return `left-fringe' and
40         `right-fringe' instead of `left-bitmap-area' and
41         `right-bitmap-area'.  Use enumerators from enum window_part
42         instead of hard-coded integers.
43         (check_window_containing, window_from_coordinates): Use
44         enumerators from enum window_part instead of hard-coded integers.
45         (syms_of_window): Replace Qleft_bitmap_area and
46         Qright_bitmap_area.with Qleft_fringe and Qright_fringe.
48 2001-01-31  Eli Zaretskii  <eliz@is.elta.co.il>
50         * editfns.c (Fformat_time_string): Doc fix.
52 2001-01-31  Stefan Monnier  <monnier@cs.yale.edu>
54         * keymap.c (Fwhere_is_internal): Use the first valid binding
55         if no ascii binding is found (when firstonly is t).
57 2001-01-31  Gerd Moellmann  <gerd@gnu.org>
59         * window.c (Fscroll_right, Fscroll_left): Use interactive_p
60         instead of Finteractive_p.
62         * lisp.h (interactive_p): Add prototype.
64         * eval.c (interactive_p): New function.
65         (Finteractive_p): Use it.
67         * alloc.c (Fmake_list): Add a QUIT in the loop; unroll the loop.
69 2001-01-31  Dave Love  <fx@gnu.org>
71         * .gdbinit (hook-run): Define to run xreload.
73         * textprop.c (Fset_text_properties): Fix newline in doc string.
75 2001-01-30  Gerd Moellmann  <gerd@gnu.org>
77         * xdisp.c (build_desired_tool_bar_string, syms_of_xdisp): Use
78         DEFAULT_TOOL_BAR_BUTTON_MARGIN and DEFAULT_TOOL_BAR_BUTTON_RELIEF.
80         * dispextern.h (Vtool_bar_button_margin:): Declare extern.
81         (DEFAULT_TOOL_BAR_BUTTON_MARGIN, DEFAULT_TOOL_BAR_BUTTON_RELIEF) 
82         (DEFAULT_TOOL_BAR_IMAGE_HEIGHT): New defines.
84         * xfns.c (Fx_create_frame): Add the tool bar height to the frame
85         height.
87 2001-01-30  Dave Love  <fx@gnu.org>
89         * bytecode.c (Fbyte_code) <Bgeq>: Add BEFORE_POTENTIAL_GC and
90         AFTER_POTENTIAL_GC.
92 2001-01-29  Gerd Moellmann  <gerd@gnu.org>
94         * bytecode.c (Fbyte_code) <Bcurrent_column>: Add
95         BEFORE_POTENTIAL_GC and AFTER_POTENTIAL_GC.
97 2001-01-29  Eli Zaretskii  <eliz@is.elta.co.il>
99         * textprop.c (Fset_text_properties): Doc fix.
101 2001-01-29  Gerd Moellmann  <gerd@gnu.org>
103         * xdisp.c (forward_to_next_line_start): Remove xassert.
105 2001-01-29  Jason Rumney  <jasonr@gnu.org>
107         * w32term.c (x_draw_row_bitmaps): Delay obtaining HDC to avoid
108         returning without releasing it.
110 2001-01-29  Kenichi Handa  <handa@etl.go.jp>
112         * w32fns.c (w32_font_match): Allocate three more bytes to regex
113         for '^', '$', and '\0'.
115 2001-01-28  Andrew Choi  <akochoi@i-cable.com>
117         * fontset.c (fontset_pattern_regexp): Allocate three more bytes to
118         regex for '^', '$', and '\0'.
120         * alloc.c (allocate_string) [macintosh]: Call check_string_bytes
121         only if current_sblock has been initialized.
123         * frame.c (Fdelete_frame) [macintosh]: Allow deletion of initial
124         terminal frame even if it is the only visible frame.
126 2001-01-28  Kenichi Handa  <handa@etl.go.jp>
128         * fontset.c (font_family_registry): Even if FONTNAME conform to
129         XLFD, if it specifies other fields than family and registry,
130         return FONTANME.  New argument FORCE if nonzero cancel that
131         feature.
132         (fontset_font_pattern): Call font_family_registry with FORCE 1 for
133         a signle byte character.  Don't set FAMILY part to nil here.  It
134         is handled by the caller choose_face_font.
135         (Fnew_fontset): Call font_family_registry with FORCE 0.
136         (Fset_fontset_font): Likewise.
138 2001-01-27  Gerd Moellmann  <gerd@gnu.org>
140         * xdisp.c (display_line): Don't treat a newline as fitting
141         on the line.
143 2001-01-26  Gerd Moellmann  <gerd@gnu.org>
145         * window.c (size_window): Set the window's orig_top to nil when
146         changing heights, so that a future shrink_mini_window won't
147         restore a bogus height.
149         * frame.c (do_switch_frame): If selected frame has a mini-window,
150         resize that to exact size.
152         * dispnew.c (adjust_glyph_matrix): Always clear desired matrices.
154         * xdisp.c (display_line): Simplify check for glyphs fitting
155         entirely in the line.
157         * xfns.c (xic_style): New variable.
158         (create_frame_xic): Move static variable to global scope for
159         the case that `static' gets defined away.
161 2001-01-26  Kenichi Handa  <handa@etl.go.jp>
163         * coding.c (decode_coding): Set a flag for inhibiting
164         inconsistent eol.
165         (code_convert_region): Always set saved_coding_symbol.
166         (decode_coding_string): Likewise.  Update coding->symbol when we
167         encounter a inconsistent eol by the same way as
168         code_convert_region.
170 2001-01-25  Gerd Moellmann  <gerd@gnu.org>
172         * xfns.c (x_set_tool_bar_lines): Use x_clear_area instead of
173         XClearArea.
175         * xterm.c (x_after_update_window_line): Don't clear if frame's
176         internal border width is zero.
177         (x_clear_area): New function.
178         (x_after_update_window_line, x_clear_end_of_line)
179         (x_scroll_bar_create, x_scroll_bar_set_handle)
180         (XTset_vertical_scroll_bar, x_erase_phys_cursor): Use x_clear_area
181         instead of XClearArea.
183         * xterm.h (x_clear_area): Add prototype.
185         * xfns.c (Fx_file_dialog): Remove a workaround for Lesstif
186         which doesn't seem necessary anymore with Lesstif 0.92.
188 2001-01-25  Dave Love  <fx@gnu.org>
190         * puresize.h (BASE_PURESIZE): Up to 720000.
192         * keymap.c (Fwhere_is_internal): Declare gcpro3, gcpro4.
194 2001-01-25  Gerd Moellmann  <gerd@gnu.org>
196         * xdisp.c (echo_area_display): Don't call redisplay_internal
197         when Emacs is shutting down.  We can't run hooks etc. that
198         would be necessary to do a redisplay.
200         * lread.c (read_integer): Use type EMACS_INT instead of int.
202 2001-01-25  Eli Zaretskii  <eliz@is.elta.co.il>
204         * ccl.c (ccl_driver): Fix last change.
206 2001-01-25  Kenichi Handa  <handa@etl.go.jp>
208         * ccl.h (sturct ccl_program): New member suppress_error.
210         * ccl.c (ccl_driver): If ccl->suppress_error is nonzero, don't
211         insert error message to the output.
212         (setup_ccl_program): Initialize ccl->suppress_error to 0.
214         * coding.h (struct coding_system): New member suppress_error.
216         * coding.c (ccl_coding_driver): Setup ccl->suppress_error.
217         (Fset_terminal_coding_system_internal): Set the member
218         suppress_error to 1.
219         (Fset_safe_terminal_coding_system_internal): Likewise.
221 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
223         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
224         as if it was a `charset'.
226 2001-01-24  Gerd Moellmann  <gerd@gnu.org>
228         * keymap.c (Fwhere_is_internal): Don't nreverse the cached
229         value in where_is_cache; the next lookup in the cache returns
230         something bogus if we do.
232 2001-01-24  Eli Zaretskii  <eliz@is.elta.co.il>
234         * xdisp.c (syms_of_xdisp) <Stool_bar_lines_needed>: Don't defsubr
235         if HAVE_WINDOW_SYSTEM isn't defined.
237 2001-01-24  Gerd Moellmann  <gerd@gnu.org>
239         * fns.c (sweep_weak_table): Fix code taking items out of
240         the hash collision chain.  Some cleanup.
242         * xterm.c (x_new_font): Don't change a tooltip's size.
244         * xfns.c (x_create_tip_frame): Prevent changing the tooltip's
245         background color by specifying a color for the default font
246         in .Xdefaults.
248 2001-01-24  Kenichi Handa  <handa@etl.go.jp>
250         * ccl.c (CCL_READ_CHAR): Change the argument name from r to REG as
251         a workaround for SunOS 4's cc.
252         (CCL_CALL_FOR_MAP_INSTRUCTION): Use "if (1)..." not "do {...".
253         (CCL_SUCCESS, CCL_SUSPEND, CCL_INVALID_CMD): Likewise.
254         (ccl_driver) <CCL_ReadMultibyteChar2>: Remove unnecessay "do"
255         statement.
257 2001-01-23  Gerd Moellmann  <gerd@gnu.org>
259         * xterm.c (x_set_window_size_1): New function extracted from
260         x_set_window_size.
261         (x_set_window_size): Use it.
262         (x_set_window_size) [USE_X_TOOLKIT]: Handle case that window
263         doesn't have a widget, like tooltips.
265 2001-01-23  Eli Zaretskii  <eliz@is.elta.co.il>
267         * window.c (syms_of_window) <scroll-preserve-screen-position>: Doc
268         fix.
270 2001-01-23  Kenichi Handa  <handa@etl.go.jp>
272         * fns.c (Fset_char_table_default): Fix to make sub char-table
273         correctly.
275 2001-01-22  Gerd Moellmann  <gerd@gnu.org>
277         * xdisp.c (build_desired_tool_bar_string): Make sure we have
278         a desired tool bar string, even if there are no tool bar
279         items.
280         
281         * xdisp.c (Ftool_bar_lines_needed): New function.
282         (syms_of_xdisp): Defsubr it.
284         * editfns.c (Fformat): Don't extend text properties from arguments
285         to padding chars in the result.
287 2001-01-20  Eli Zaretskii  <eliz@is.elta.co.il>
289         * s/msdos.h (GC_MARK_STACK): Define to GC_MAKE_GCPROS_NOOPS.
291 2001-01-20  Andrew Innes  <andrewi@gnu.org>
293         * w32term.c (w32_ring_bell): Only support visible bell on w32
294         frames.
295         (w32_initialize): Don't set term hooks that aren't actually needed
296         in windowed mode.
298         * xfaces.c (realize_default_face):
299         (realize_face):
300         (realize_tty_face): Remove references to FRAME_W32_CONSOLE_P.
302         * xdisp.c (handle_single_display_prop): Remove references to
303         FRAME_W32_CONSOLE_P.
305         * dispnew.c (Fredraw_frame): Remove reference to
306         FRAME_W32_CONSOLE_P.
308         * frame.h (output_method): Remove output_w32_console method.
309         (FRAME_W32_CONSOLE_P): Remove macro.
311         * frame.c (Qw32_console): Remove variable.
312         (Fframep): Remove references to it.
313         (syms_of_frame): Ditto.
314         (Fframe_parameters): Remove references to FRAME_W32_CONSOLE_P.
316         * term.c (FRAME_TERMCAP_P) [WINDOWSNT]: Reinstate original
317         redefinition.
319 2001-01-20  Kenichi Handa  <handa@etl.go.jp>
321         * editfns.c (Fformat): Use lisp_string_width instead of strwidth.
323 2001-01-19  Andrew Innes  <andrewi@gnu.org>
325         * w32.c (init_environment): Add a version-independent site-lisp
326         directory to EMACSLOADPATH, after the version dependent one.
328 2001-01-19  Gerd Moellmann  <gerd@gnu.org>
330         * editfns.c (Fbuffer_substring): Doc fix.
332         * xdisp.c (message_dolog, message2, message2_nolog): Rename
333         parameter LEN to NBYTES.
335 2001-01-19  Kenichi Handa  <handa@etl.go.jp>
337         * charset.c (strwidth): Use c_string_width.
338         (c_string_width): New function.
339         (lisp_string_width): New arguments PRECISION, NCHARS, NBYTES.
340         Caller changed.
342         * charset.h (c_string_width, lisp_string_width): Extern them.
344         * doprnt.c (doprnt1): Get byte length of Lisp string correctly. 
346         * indent.c (check_composition): Check validity of composition.
348         * xdisp.c (store_frame_title): Pay attention to width of non-ASCII
349         characters by calling c_string_width.
350         (x_consider_frame_title): Get byte length of frame tile string
351         correctly.
352         (display_mode_element): Pay attention to width of non-ASCII
353         characters by calling strwidth.
355 2001-01-18  Gerd Moellmann  <gerd@gnu.org>
357         * xfns.c (Qcancel_timer): New variable.
358         (syms_of_xfns): Initialize and staticpro it.
359         (Fx_hide_tip, Fx_show_tip): Use it.
360         (Fx_show_tip): Make sure to set tip_timer to nil when canceling
361         the timer.
362         (toplevel): Lisp code for generating parts of syms_of_xfns removed.
364         * window.c (Fwindow_live_p): Use WINDOW_LIVE_P.
366         * window.h (WINDOW_LIVE_P): New macro.
368         * window.c (window_size_fixed): New variable.
369         (syms_of_window): Add a DEFVAR_BOOL for window-size-fixed, for
370         the doc string.
372         * eval.c (specbind): If binding a per-buffer variable which
373         doesn't have a buffer-local value in the current buffer, change
374         the global value by changing the value of the symbol bound in all
375         buffers not having their own value, to make it consistent with
376         what happens with other buffer-local variables.
378         * xterm.c (x_initialize): Set char_ins_del_ok to 1.
380         * xdisp.c (forward_to_next_line_start): Stop at end of buffer
381         when searching for a newline.
383 2001-01-18  Kenichi Handa  <handa@etl.go.jp>
385         * xdisp.c (display_string): Fix previous change.
387 2001-01-18  Jason Rumney  <jasonr@gnu.org>
389         * w32term.c (x_produce_stretch_glyph): Only use Qspace when
390         GLYPH_DEBUG is defined.
391         (x_produce_glyphs): Don't xassert `it->descent > 0'; this isn't
392         true for images with `:ascent 100'.
393         (x_set_mouse_face_gc): If the last used mouse face has gone in the
394         meantime, use face MOUSE_FACE_ID.
395         If first glyph isn't a character glyph, use the ASCII NUL
396         character to determine the face.
397         (expose_area): Do not treat left margin specially.
398         (note_mode_line_highlight): If no local_map, check global keymap.
399         (note_mouse_highlight): Initialize overlay.
400         (clear_mouse_face): Don't return if tip_frame is
401         non-nil.
402         (show_scroll_bars): Remove unused function.
403         (w32_read_socket) [WM_KILLFOCUS]: Set help_echo to Qnil.
404         (x_draw_bar_cursor): Remove extra test for out of bounds cursor.
405         Clip to row.
406         (x_erase_phys_cursor): Don't apply XWINDOW to variable that may be
407         nil.
408         (x_free_frame_resources): Unload relief colors.
410 2001-01-17  Gerd Moellmann  <gerd@gnu.org>
412         * xdisp.c (forward_to_next_line_start): Avoid calling
413         get_next_display_element when the newline is already found.  This
414         may change the iterator's position, when its current position is
415         equal to the iterator's stop_charpos.
417         * dispnew.c (direct_output_for_insert): If char_ins_del_ok is
418         zero, use this method only at the end of a line.
420         * xfaces.c (x_face_list_fonts): Don't BLOCK_INPUT around the 
421         call to x_list_fonts.  Call x_list_fonts with SIZE -1 only
422         if SCALABLE_FONTS_P is set.
423         
424         * xfaces.c (x_face_list_fonts): Call x_list_fonts with SIZE -1,
425         so that scalable fonts are included.
427         * xterm.c (x_list_fonts): Allow scalable fonts if SIZE is < 0,
428         In the cache, use a key containing the information if scalable
429         fonts are included.
430         (x_load_font): Adapt to change of keys in the font cache.
432 2001-01-17  Kim F. Storm  <storm@filanet.dk>
433         
434         * xfaces.c (x_face_list_fonts): Use x_list_fonts instead of
435         XListFonts to take advantage of font caching.
437         * xterm.c (x_list_fonts): Ensure caching font information when
438         called for a null frame, which is the case frequently when Emacs
439         starts.
441 2001-01-17  Gerd Moellmann  <gerd@gnu.org>
443         * xfns.c (QCconversion): Replaces QCalgorithm.
445         * w32fns.c (QCconversion): Replaces QCalgorithm.  Update copyright.
447         * xdisp.c (build_desired_tool_bar_string): Use :conversion instead
448         of :algorithm.
449         
450         * xdisp.c (redisplay_tool_bar): Change tool bar's height when
451         not everything could be displayed.
453         * line.h, x-list-font.c: Files removed because unused.
455 2001-01-17  Andrew Innes  <andrewi@gnu.org>
457         * dired.c (directory_files_internal): Convert result from readdir
458         to a unibyte string initially, to avoid possible misinterpretation
459         of some bytes as the internal form of Emacs characters.
461 2001-01-17  Kenichi Handa  <handa@etl.go.jp>
463         * fns.c (concat): Be sure to avoid putting the same `composition'
464         property on the adjacent regions.
466 2001-01-16  Gerd Moellmann  <gerd@gnu.org>
468         * window.c (Fset_window_hscroll): Don't set window's min_hscroll
469         here.
470         (Fscroll_right, Fscroll_left): Set it here instead, if called
471         interactively.
473         * buffer.c (Fset_buffer_modified_p): Set buffer's
474         prevent_redisplay_optimizations_p flag.
476         * dispnew.c, callproc.c, fns.c, keyboard.c, process.c, sunfns.c,
477         * sysdep.c, vmsproc.c, xselect.c: Call
478         redisplay_preserve_echo_area with additional arg.
480         * dispextern.h, lisp.h (redisplay_preserve_echo_area): Change
481         prototype.
482         
483         * xdisp.c (redisplay_preserve_echo_area): Add parameter
484         FROM_WHERE, for debugging.
486 2001-01-16  Kenichi Handa  <handa@etl.go.jp>
488         * ccl.c (Fregister_ccl_program): Handle the return value of
489         resolve_symbol_ccl_program correctly.
490         (CCL_Extension): Fix typo (originally CCL_Extention).  Caller
491         changed.
493 2001-01-15  Gerd Moellmann  <gerd@gnu.org>
495         * xterm.c (x_set_mouse_face_gc): If the last used mouse face
496         has gone in the meantime, use face MOUSE_FACE_ID.
497         
498         * xterm.c (x_connection_closed) [USE_X_TOOLKIT]: If
499         x_display_info_for_display returns null, don't try to close
500         the display; we didn't open it.
502         * dispnew.c (save_or_restore_current_matrices): Function removed.
503         (save_current_matrix, restore_current_matrix): New functions.
504         (adjust_frame_glyphs_for_frame_redisplay): Use them to save and
505         restore the frame's current matrix.  Due to the glyph pointer
506         setup done in adjust_glyph_matrix, there is no easy way to make
507         saving the current matrix in the desired matrix generally correct,
508         so don't try it.
510 2001-01-15  Kenichi Handa  <handa@etl.go.jp>
512         * xdisp.c (insert_left_trunc_glyphs): Overwrite padding glyphs by
513         truncation glyphs.
514         (display_line): Optimize for wide characters.
515         (display_string): Don't try to display a multi-column character
516         partially.  On ttys, produce more than one truncation glyph for
517         multi-column characters that don't fit on the line.
519 2001-01-13  Kenichi Handa  <handa@etl.go.jp>
521         * md5.c (WORDS_BIG_ENDIAN) [__BYTE_ORDER == __BIG_ENDIAN]: Define
522         it instead of WORDS_BIGENDIAN.  Caller changed.
524 2001-01-13  Jason Rumney  <jasonr@gnu.org>
526         * w32fns.c (Fimage_size, image_ascent, lookup_image)
527         (IMAGE_POSITIVE_INTEGER_VALUE_OR_PAIR, parse_image_spec)
528         (xbm_format, xpm_format, pbm_format, png_format, jpeg_format) 
529         (tiff_format, gif_format, gs_format): Adapt to change of image
530         margins.
532         * w32term.c (x_produce_image_glyph, x_draw_image_foreground) 
533         (x_draw_image_relief, x_draw_image_foreground_1) 
534         (x_draw_image_glyph_string): Adapt to change of image margins.
536         * w32.c (init_environment, sys_shutdown, sys_pipe): Remove unused
537         variables.
539         * w32bdf.c (search_file_line, get_cached_font_char)
540         (cache_char_offset, create_offscreen_bitmap): Remove unused variables.
542         * w32inevt.c (w32_console_toggle_lock_key): Add parentheses.
544         * w32fns.c (x_to_w32_color, x_set_icon_name, xlfd_strip_height)
545         (w32_list_synthesized_fonts, lookup_image, Fx_file_dialog)
546         (Fw32_send_sys_command): Remove unused variables.
547         (w32_msg_pump): Add parentheses.
549         * w32term.c (w32_fill_rect, w32_read_socket, x_bitmap_icon)
550         (x_new_fontset, x_calc_absolute_position, x_iconify_frame):
551         Add parentheses.
553 2001-01-12  Gerd Moellmann  <gerd@gnu.org>
555         * xdisp.c (Vtool_bar_button_margin): Replaces tool_bar_button_margin.
556         (build_desired_tool_bar_string): Handle Vtool_bar_button_margin
557         being a pair of margins.
558         (syms_of_xdisp): Change DEFVAR_INT of tool-bar-button-margins
559         to DEFVAR_LISP.  Extend doc.
561         * xfns.c (Fimage_size, image_ascent): Adapt to the change of image
562         margins.
563         (lookup_image): If `:margin MARGIN' is specified, and MARGIN is a
564         pair of integers `(X . Y)', use X for the horizontal and Y for the
565         vertical margin.
566         (IMAGE_POSITIVE_INTEGER_VALUE_OR_PAIR): New enumerator.
567         (parse_image_spec): Check it.
568         (xbm_format, xpm_format, pbm_format, png_format, jpeg_format) 
569         (tiff_format, gif_format, gs_format): Use
570         IMAGE_POSITIVE_INTEGER_VALUE_OR_PAIR for :margin.
572         * xterm.c (x_produce_image_glyph, x_draw_image_foreground) 
573         (x_draw_image_relief, x_draw_image_foreground_1) 
574         (x_draw_image_glyph_string): Adapt to the change of image margins.
576         * dispextern.h (struct image): Replace member `margin' with
577         `hmargin' and `vmargin'.
579         * xdisp.c (Fdump_tool_bar_row) [GLYPH_DEBUG]: Add parameters ROW
580         and GLYPHS.
582         * dispnew.c (update_text_area): Put code which decrements the
583         stop position when the row's face extends to the end of the
584         line in #if 0.
586         * xfns.c (x_set_mouse_color): Fix color allocation.
588         * keyboard.c: Call get_local_map with new argument list.
590         * intervals.c (get_local_map): Change TYPE to Lisp_Object.
592         * intervals.h (enum map_property): Removed.
593         (get_local_map): Change prototype.
595         * keymap.c: Call get_local_map with new argument list.
596         (Fwhere_is_internal): Rename parameter XKEYMAP to KEYMAP.
598 2001-01-11  Gerd Moellmann  <gerd@gnu.org>
600         * xdisp.c (build_desired_tool_bar_string): Correct the computation
601         of the size needed for the tool bar string.  For the last image,
602         use a `display' property that reaches to the end of the string.
604         * xselect.c (selection_request_dpyinfo): New variable.
605         (x_handle_selection_request): Set it.
606         (x_selection_request_lisp_error): Don't call
607         x_decline_selection_request if selection request's display has
608         been closed.
610         * xfaces.c (x_free_colors, x_free_dpy_colors) [DEBUG_X_COLORS]: Do
611         the unregister_colors before calling XFreeColors.
613 2001-01-10  Dave Love  <fx@gnu.org>
615         * Makefile.in (${etc}DOC): Depend on ${shortlisp} and
616         ${SOME_MACHINE_LISP}, not ${lisp}.
618 2001-01-10  Gerd Moellmann  <gerd@gnu.org>
620         * xdisp.c (display_line): On ttys, produce more than one
621         truncation glyph for multi-column characters that don't fit on the
622         line.
624         * xselect.c (x_reply_selection_request): Add a comment.
626         * xfns.c (Fx_backspace_delete_keys_p): Use XkbGetMap and
627         XkbGetNames instead of XkbGetKeyboard.
629 2001-01-10  Dave Love  <fx@gnu.org>
631         * sysdep.c (random): Revert the declaration.
633 2001-01-09  Gerd Moellmann  <gerd@gnu.org>
635         * lisp.h (STRING_BYTES) [GC_CHECK_STRING_BYTES]: Call
636         function string_bytes.
637         (GC_CHECK_STRING_BYTES): Moved here from alloc.c.
639         * alloc.c (CHECK_STRING_BYTES) [GC_CHECK_STRING_BYTES]: New macro.
640         (check_sblock, string_bytes) [GC_CHECK_STRING_BYTES]: New functions.
641         (check_string_bytes) [GC_CHECK_STRING_BYTES]: Add parameter ALL_P.
642         (allocate_string) [GC_CHECK_STRING_BYTES]: Always check strings in
643         the current sblock.
644         (mark_object) [GC_CHECK_STRING_BYTES]: Use CHECK_STRING_BYTES.
645         (gc_sweep) [GC_CHECK_STRING_BYTES]: Call check_string_bytes
646         after sweeping strings, and at the end.
647         (GC_CHECK_STRING_BYTES): Moved to lisp.h.
649         * alloc.c (Fgarbage_collect): Use a record_unwind_protect to
650         ensure that pop_message is called.
652         * keyboard.c (Fexecute_extended_command): Use a
653         record_unwind_protect to ensure that pop_message is called.
655         * lisp.h (push_message_unwind): Add prototype.
657         * xdisp.c (push_message_unwind): New function.
659         * fileio.c (do_auto_save_unwind): Do the pop_message here
660         instead of in Fdo_auto_save.
661         (Fdo_auto_save): Don't call pop_message.
663 2001-01-08  Ken Raeburn  <raeburn@gnu.org>
665         * xfns.c (xpm_load) [!ALLOC_XPM_COLORS]: Declare local variable I
666         in inner block.
668 2001-01-08  Gerd Moellmann  <gerd@gnu.org>
670         * window.c (window_scroll_pixel_based): Adjust glyph matrices
671         when increasing window's vscroll.
673         * macros.c (Qkbd_macro_termination_hook): New variable.
674         (syms_of_macros): Initialize and staticpro it.
675         (pop_kbd_macro): Run kbd-macro-termination-hook.
677         * xterm.c (XTread_socket) <LeaveNotify>: Set help_echo to nil.
679 2001-01-07  Dave Love  <fx@gnu.org>
681         * keyboard.c (Fread_key_sequence_vector):  Avoid newline in
682         arglist, for documentation's sake.
684 2001-01-06  Andrew Innes  <andrewi@gnu.org>
686         * makefile.w32-in (clean): Delete $(COMPILER_TEMP_FILES) instead
687         of *.pdb.
689 2001-01-05  Andrew Innes  <andrewi@gnu.org>
691         * term.c (update_end): Don't check updating_frame; for some reason
692         this can be 0 sometimes, such as after dismissing a popup menu,
693         and isn't necessary given the explicit frame argument.
695 2001-01-05  Gerd Moellmann  <gerd@gnu.org>
697         * sysdep.c: Don't prototype srandom; it takes an unsigned argument
698          on some systems, and an unsigned long on others, like FreeBSD 4.1.
700 2001-01-04  Gerd Moellmann  <gerd@gnu.org>
702         * xterm.c (clear_mouse_face): Don't return if tip_frame is
703         non-nil.
705         * xfns.c (x_create_tip_frame): Preserve the value of
706         face_change_count around the creation of the tip frame.
707         
708         * xfns.c (last_show_tip_args): New variable.
709         (compute_tip_xy): New function.
710         (Fx_show_tip): Reuse an existing tip frame, if possible.
711         (syms_of_xfns): Initialize and staticpro last_show_tip_args.
713 2001-01-04  Dave Love  <fx@gnu.org>
715         * editfns.c (Fformat): Doc fix.
717         * systime.h (set_file_times): Prototype.
719         * widget.h (EmacsFrameSetCharSize_): Prototype.
721         * sysdep.c (random, srandom): Declare explicitly.
723         * dispextern.h (move_it_vertically_backward): Declare.
725 2001-01-04  Gerd Moellmann  <gerd@gnu.org>
727         * xfns.c (x_create_tip_frame): Call face-set-after-frame-default,
728         like in Fx_create_frame.
730         * xfaces.c (set_font_frame_param): Don't do anything for
731         non-graphical frames.
733         * window.c (Fdelete_other_windows): Set window's window_end_valid
734         to nil when changing the window's start.  Don't change the
735         window's start when its top position hasn't changed.  If we do,
736         this will set the window's optional_new_start, which act's like a
737         force_start during redisplay with C-x 1 M-> under particular
738         circumstances (see report from Per Starback to emacs-pretest-bug
739         from 2000-12-13.).
741 2001-01-03  Gerd Moellmann  <gerd@gnu.org>
743         * xdisp.c (forward_to_next_line_start): Reset it->c if taking the
744         short cut at the start of the function.  Add an assertion.
745         (reseat_at_next_visible_line_start): Add an assertion.
747         * window.c (Frecenter): When changing the window start, set the
748         window's window_end_valid to nil.
749         (Fwindow_end): Fix window-end computation when UPDATE is non-nil.
751         * dispextern.h (move_it_past_eol): Add prototype.
753         * xdisp.c (move_it_past_eol): New function.
755         * window.c (Fwindow_end): Doc fix.
757 2001-01-03  Dave Love  <fx@gnu.org>
759         * dired.c (Ffile_attributes): Fix last change, removing BSD4_3
760         kluge.
762 2001-01-03  Gerd Moellmann  <gerd@gnu.org>
764         * xdisp.c (try_window_reusing_current_matrix): Fix bug setting
765         the enabled_p flag of the glyph row at window_end_vpos to 0.
766         (handle_single_display_prop): Fix last change.
768 2001-01-02  Richard M. Stallman  <rms@caffeine.ai.mit.edu>
770         * window.c (Frecenter): Doc fix.
772 2001-01-02  Andrew Innes  <andrewi@gnu.org>
774         * term.c (FRAME_TERMCAP_P) [WINDOWSNT]: Remove redefinition.
776         * frame.h (output_method): Add output_w32_console method.
777         (FRAME_W32_CONSOLE_P): New macro.
779         * frame.c (make_terminal_frame) [WINDOWSNT]: Make terminal frames
780         use output_w32_console method.
781         (Qw32_console): New Lisp_Object.
782         (Fframep): Return it.
783         (syms_of_frame): Init it.
784         (Fframe_parameters): Report w32console as font for w32_console
785         frames.
787         * xfaces.c (realize_default_face): Set face foreground and
788         background to unspecified for w32_console frames.
789         (realize_face): Realize face cache for w32_console frames.
790         (realize_tty_face): Accept w32_console frames.
792         * xdisp.c (handle_single_display_prop): Return if frame is
793         w32_console.
794         (init_iterator) [WINDOWSNT]: Initialize frame face cache if
795         necessary, even if running interactively.
797         * dispnew.c (Fredraw_frame): Call set_terminal_modes for
798         w32_console frames.
800         * w32term.c (x_update_begin): 
801         (x_update_end): 
802         (x_clear_frame): 
803         (x_ins_del_lines): 
804         (x_change_line_highlight): 
805         (x_delete_glyphs): 
806         (w32_ring_bell): 
807         (x_update_begin): 
808         (x_update_end): 
809         (w32_reassert_line_highlight): 
810         (w32_frame_rehighlight): 
811         (w32_frame_raise_lower): Do nothing if not w32 frame.
813         * w32xfns.c (get_frame_dc): Abort if called on a non-w32 frame.
815         * w32fns.c (Fx_display_color_cells): Determine correct value, when
816         system doesn't tell us directly.
817         (Fx_display_visual_class): Implement properly.
819 2001-01-02  Gerd Moellmann  <gerd@gnu.org>
821         * window.c (Frecenter): Handle centering in graphical frames
822         specially.  Centering on the basis of line counts doesn't work
823         reliably with variable-height lines.
824         
825 2001-01-02  Eli Zaretskii  <eliz@is.elta.co.il>
827         * widget.c (EmacsFrameSetCharSize): Remove unused variables `ac'
828         and al[].
830         * composite.c (run_composition_function): Remove unused variable
831         `val'.
832         (update_compositions): Remove unused variable `hook'.
834         * intervals.c (get_local_map): Remove unused variable `tem'.
836         * doprnt.c (doprnt1): Remove unused variable `size'.
838         * fns.c (Flength): Remove unused variable `tail'.
839         (Fdelete): Remove unused variable `size'.
841         * editfns.c (Ftranspose_regions): Remove unused variables `gcpro1'
842         and `gcpro2'.
844         * doc.c (Fsnarf_documentation): Remove unused variables `fun' and
845         `tem'.
847         * data.c (find_symbol_value): Remove extra 3rd argument in the
848         call to swap_in_symval_forwarding.
850         * undo.c (Fprimitive_undo): Remove unused block-scope variable
851         `end'.
853         * search.c (shrink_regexp_cache): Remove unused variable `cpp'.
854         (trivial_regexp_p): Remove unused variable `c'.
855         (boyer_moore): Remove unused variable `k'.
857         * indent.c (current_column): Remove unused variable `stopchar'.
858         (Fcompute_motion): Remove unused variable `contin'.
860         * casefiddle.c (casify_object): Remove unused variable `tolen'.
862         * dired.c (directory_files_internal): Fix a typo in a comment.
863         Remove an unused variable `handler'.
864         (file_name_completion): Remove unused function-scope variable
865         `dp'.
866         (Ffile_attributes) <dirname, sdir>: Make declarations conditioned
867         on BSD4_2.
869         * fileio.c (e_write): Remove unused variable
870         `require_encoding_p'.
872         * marker.c (Fmarker_position): Remove unused variables `pos', `i',
873         and `buf'.
874         (Fmarker_insertion_type): Remove unused variable `buf'.
876         * insdel.c (make_gap): Remove unused variable `result'.
878         * keyboard.c (record_char): Remove unused function-scope variable
879         `help'.
880         (kbd_buffer_get_event): Remove unused block-scope variable `idx'.
881         (menu_bar_items): Remove unused function-scope variable `tem'.
883         * fontset.c (fontset_ref): Remove unused variable `i'.
884         (fontset_set): Remove unused variables `j' and `tmp'.
885         (make_fontset): Remove unused variables `i', `j', `elt' and
886         `base_elt'.
887         (make_fontset_for_ascii_face): Remove unused variable `name'.
888         (fs_load_font): Remove unused variable `font_idx'.
889         (fs_query_fontset): Remove unused function-local variable
890         `fontset'.
891         (list_fontsets): Remove unused variable `tail'.
892         (Fnew_fontset): Remove unused variables `family' and `registry'.
893         (accumulate_font_info): Remove unused variable `tmp'.
894         (Ffontset_font): Remove unused variable `id'.
895         (syms_of_fontset): Remove unused variable `i'.
897         * xfns.c (x_display_info_for_name): Cast 0 to "char *" in the call
898         to x_term_init.
899         (lookup_image): Remove unused variable `file'.
900         (xbm_load): Remove unused variables `bitmap_data', `height', and
901         `width'.  Remove function-local variable `i', leave the
902         block-local one.
903         (gif_load): Remove unused variable `inc'.
905         * xterm.c (XTread_socket): Remove unused variables `p' and
906         `pend'.
907         (XTread_socket) <LeaveNotify>: Remove unused variable `frame',
908         leave only the one in the inner block.
910         * xfaces.c (face_fontset, realize_default_face): Remove unused
911         variable `fontset'.
912         (face_at_buffer_position): Remove unused variable `multibyte_p'.
914         * term.c (encode_terminal_code): Remove unused variable `c'.
916         * ccl.c (Fccl_execute): Cast ccl_driver parameters to `unsigned
917         char *' instead of `char *'.
919         * category.c (Fcategory_docstring): Remove unused variable `doc'.
920         (Fget_unused_category): Remove unused variable
921         `docstring_vector'.
922         (Fchar_category_set): Remove unused variables `val', `charset',
923         `c1' and `c2'.
925         * coding.c (detect_coding_iso2022, setup_coding_system): Remove
926         unused variable `i'.
927         (detect_coding_mask): Remove unused variable `idx'.
928         (detect_coding): Remove unused variable `i'.
929         (ccl_coding_driver): Remove unused variable `result'.
930         (run_pre_post_conversion_on_str): Remove unused variable `prev'.
931         (decode_coding_string): Remove unused variables `to' and
932         `gcpro1'.
933         (encode_coding_string): Remove unused variables `gcpro1' and
934         `saved_coding_symbol'.
935         (Ffind_coding_systems_region_internal): Remove function-local
936         variable args[], leave only the block-local one.
937         (code_convert_region1): Remove unused variable `len'.
939         * charset.c (char_printable_p): Remove unused variable `chars'.
940         (Fsplit_char, Fchar_bytes): Remove unused variable `val'.
941         (str_to_multibyte): Remove unused variable `c'.
943         * window.c (size_window): Remove block-local variable `min_size'.
945         * xdisp.c (make_cursor_line_fully_visible): Remove unused variable
946         `header_line_height'.
947         (append_space, extend_face_to_end_of_line): Declare `saved_what'
948         enum display_element_type.
950 2001-01-02  Gerd Moellmann  <gerd@gnu.org>
952         * xterm.c (x_connection_closed): Catch X errors around all
953         statements that call X.  Save away the error message in a local
954         copy.
955         
956         * xterm.c (x_connection_closed): Set handling_signal to 0 at
957         the start.
959         * xdisp.c (pos_visible_p): Take into account that CHARPOS maybe
960         in or at the start of invisible text.
962         * dispnew.c (update_window): Don't check_current_matrix_flags.
964 2001-01-01  Jason Rumney  <jasonr@gnu.org>
966         * w32fns.c (x_figure_window_size): Do not allow new_height and
967         new_width of frame to override specified values.
969 2000-12-30  Kenichi Handa  <handa@etl.go.jp>
971         * composite.c (find_composition): Fix a code for searching
972         backward.
974 2000-12-29  Gerd Moellmann  <gerd@gnu.org>
976         * dispnew.c (check_current_matrix_flags) [GLYPH_DEBUG]: New
977         function.
978         (update_window) [GLYPH_DEBUG]: Call it.
979         (scrolling_window): Prevent including current rows which are below
980         what's displayed in the window.
982         * xdisp.c (try_window_reusing_current_matrix)
983         <new start <= old start>:  Disable rows in the current matrix
984         which are below the window after scrolling.
985         
986         * xdisp.c (move_it_by_lines): Don't do optimizations if NEED_Y_P
987         is zero.  It's not worth the complexity.
988         (invisible_text_between_p): Put in #if 0 because unused.
990 2000-12-28  Gerd Moellmann  <gerd@gnu.org>
992         * xfns.c (Fx_backspace_delete_keys_p): Check library and server
993         XKB versions.  Call XkbFreeKeyboard with 2nd arg 0.
995         * keyboard.c (echo_char): If C is an integer, always call
996         push_key_description.  Former code could signal an invalid
997         character error.
999         * keymap.c (push_key_description): Add parameter FORCE_MULTIBYTE.
1000         If set, print multibyte text.
1001         (Fsingle_key_description): Call push_key_description with
1002         FORCE_MULTIBYTE set.
1003         (describe_buffer_bindings): Likewise.
1005         * lisp.h (push_key_description): Add prototype.
1007         * xdisp.c (echo_area_display): Bind redisplay-dont-pause to t
1008         around the call to redisplay_internal.
1010         * xfns.c: Use #if GLYPH_DEBUG instead of #ifdef GLYPH_DEBUG.
1012         * dispnew.c: Use #if GLYPH_DEBUG instead of #ifdef GLYPH_DEBUG.
1014 2000-12-28  Kenichi Handa  <handa@etl.go.jp>
1016         * ccl.c (CCL_WRITE_CHAR): Check variable `extra_bytes'.
1017         (ccl_driver): New local variable `extra_bytes'.
1019         * ccl.h (struct ccl_spec): New member eight_bit_carryover.
1021         * coding.c (setup_coding_system): Initialize
1022         coding->spec.ccl.eight_bit_carryover.
1023         (ccl_coding_driver): Pay attention to carried over 8-bit bytes.
1025 2000-12-28  Kenichi Handa  <handa@etl.go.jp>
1027         * coding.c (SAFE_ONE_MORE_BYTE): New macro.
1028         (DECODE_EMACS_MULE_COMPOSITION_CHAR): New macro.
1029         (DECODE_EMACS_MULE_COMPOSITION_RULE): New macro.
1030         (decode_composition_emacs_mule): New function.
1031         (decode_coding_emacs_mule): Decode composition sequence by calling
1032         decode_composition_emacs_mule.
1033         (ENCODE_COMPOSITION_EMACS_MULE): New macro.
1034         (encode_coding_emacs_mule): Changed from macro to function.  If
1035         a text contains compositions, encode them correctly.
1036         (setup_coding_system): Set coding->commong_flags for emacs-mule so
1037         that decoding and encoding are required.
1039 2000-12-27  Gerd Moellmann  <gerd@gnu.org>
1041         * xfaces.c (PT_PER_INCH): New macro.
1042         (xlfd_point_size): Compute real point size from font's pixel size.
1043         (pixel_point_size, build_scalable_font_name): Use PT_PER_INCH
1044         instead of 72.
1046         * .gdbinit: Comment out the line pointing to the Lesstif source
1047         directory.
1049         * window.c (Frecenter): Use displayed_window_lines instead
1050         of window_internal_height.
1052         * xterm.c (syms_of_xterm): DEFVAR_LISP x-toolkit-scroll-bars
1053         instead of x-toolkit-scroll-bars-p.
1054         (Vx_toolkit_scroll_bars): Renamed from x_toolkit_scroll_bars_p.
1056         * w32term.c (syms_of_xterm): DEFVAR_LISP x-toolkit-scroll-bars
1057         instead of x-toolkit-scroll-bars-p.
1058         (Vx_toolkit_scroll_bars): Renamed from x_toolkit_scroll_bars_p.
1059         
1060         * dispnew.c (struct redisplay_history) [GLYPH_DEBUG]: New.
1061         (REDISPLAY_HISTORY_SIZE) [GLYPH_DEBUG]: New macro.
1062         (redisplay_history, history_idx, history_tick) [GLYPH_DEBUG]: New
1063         variables.
1064         (add_window_display_history, add_frame_display_history) 
1065         (Fdump_redisplay_history) [GLYPH_DEBUG]: New functions.
1066         (build_frame_matrix_from_leaf_window): Remove unused code.
1067         (build_frame_matrix_from_leaf_window) [GLYPH_DEBUG]: Add to
1068         redisplay history.
1069         (update_frame) [GLYPH_DEBUG]: Add to redisplay history.
1070         (update_window) [GLYPH_DEBUG]: Likewise.
1071         (syms_of_display): Defsubr dump-redisplay-history.
1073 2000-12-23  Gerd Moellmann  <gerd@gnu.org>
1075         * keyboard.c (echo_prompt): Always set current_kboard->echoptr to
1076         the end of the prompt.  Set echo_after_prompt to the offset
1077         of echoptr in echobuf.
1079         * xdisp.c (init_from_display_pos): Pop until the iterator's
1080         stack is empty; there may be frames for stretch or images
1081         on the stack.
1083         * dispnew.c (save_frame_matrix, restore_frame_matrix): Removed.
1084         (save_or_restore_current_matrix): New function for the same
1085         purpose, but more efficient.
1086         (adjust_frame_glyphs_for_frame_redisplay): Use it.
1088 2000-12-23  Eli Zaretskii  <eliz@is.elta.co.il>
1090         * xdisp.c (syms_of_xdisp): Fix last change.
1092 2000-12-23  Gerd Moellmann  <gerd@gnu.org>
1094         * xdisp.c (syms_of_xdisp): Doc fix.
1096         * xdisp.c (redisplay_window): Remove label restore_buffers;
1097         use finish_scroll_bars instead to make sure that scroll bars
1098         are redeemed.  If we don't do this, flickering can result from
1099         scroll bars being destroyed and recreated.
1101 2000-12-22  Jason Rumney  <jasonr@gnu.org>
1103         * w32term.c (w32_draw_bitmap): Fix drawing so it does not appear
1104         in the wrong colors when the foreground is not black.
1105         (expose_window): Don't redraw the window that's currently being
1106         updated.
1108 2000-12-22  Gerd Moellmann  <gerd@gnu.org>
1110         * window.c (size_window): When setting the window's too_small_ok
1111         flag, compare old size with minimum size depending on WIDTH_P,
1112         don't compare with window_min_width.
1113         
1114         * window.c (delete_window): Simplify somewhat.
1115         (Fset_window_configuration): Don't SET_FRAME_GARBAGED after
1116         freeing window matrices.  The flag windows_or_buffers_changed is
1117         set, so the next redisplay will consider all windows; this should
1118         suffice.
1120 2000-12-22  Kenichi Handa  <handa@etl.go.jp>
1122         * coding.c (ccl_coding_driver): Initialize ccl->cr_consumed.
1124         * ccl.h (struct ccl_program): New member cr_consumed.
1126         * ccl.c (CCL_WRITE_CHAR): Don't handle EOL conversion here.
1127         (CCL_READ_CHAR): Handle EOL conversion here.
1128         (ccl_driver) <CCL_ReadMultibyteChar2>: Likewise.
1130 2000-12-21  Gerd Moellmann  <gerd@gnu.org>
1132         * xdisp.c (Fdump_glyph_row) [GLYPH_DEBUG]: Add optional arg
1133         GLYPHS.
1135         * dispextern.h (GLYPH_EQUAL_P): Also compare pixel widths,
1136         otherwise tabs of different size compare equal.
1138         * callint.c (Fcall_interactively): Prevent a compiler warning.
1140         * print.c (print_unwind): Return nil.
1141         (PRINTDECLARE): Initialize all local variables.
1142         (print_preprocess): Add a default case.
1144         * lisp.h (Qinhibit_point_motion_hooks): Declare extern.
1146         * undo.c (Fprimitive_undo): Bind `inhibit-point-motion-hooks' to t.
1148         * window.c (delete_window, Fsplit_window) 
1149         (Fset_window_configuration): Calls to ensure_frame_matrix removed.
1151         * dispextern.h (ensure_frame_matrix): Function declaration removed.
1153         * dispnew.c (ensure_frame_matrix): Removed.
1154         (save_frame_matrix, restore_frame_matrix): New functions.
1155         (adjust_frame_glyphs_for_frame_redisplay): Use them.
1157         * xdisp.c (dump_glyph_row, dump_glyph_matrix, Fdump_glyph_matrix)
1158         [GLYPH_DEBUG]: Extended to dump glyphs in short form.
1160 2000-12-21  Andrew Innes  <andrewi@gnu.org>
1162         * w32term.c (x_update_begin): Regenerate the palette here, rather
1163         than for each window.
1165         * w32xfns.c (select_palette): Avoid calling SelectPalette if
1166         palette is NULL, since this corrupts memory!  Also get
1167         display_info reference from frame.
1169 2000-12-21  Jason Rumney  <jasonr@gnu.org>
1171         * w32bdf.c (w32_init_bdf_font): Fix test for valid bmp heap.
1173         * w32term.c (x_draw_hollow_cursor): Delay obtaining the frame's DC
1174         to avoid returning without releasing it.
1176 2000-12-21  Kenichi Handa  <handa@etl.go.jp>
1178         * keymap.c (push_key_description): Don't convert eight-bit-control
1179         and eight-bit-graphic to multibyte character.
1181         * charset.c (Fmake_char_internal): If CHARSET doesn't have a
1182         generic character and CODE1 is nil, return the smallest character
1183         in CHARSET.
1185 2000-12-20  Dave Love  <fx@gnu.org>
1187         * s/osf5-0.h (NSIG): Don't redefine.
1189 2000-12-20  Stefan Monnier  <monnier@cs.yale.edu>
1191         * keymap.c (where_is_internal): Check ascii_sequence_p rather than
1192         excluding menu-bar and tool-bar.
1193         (Fwhere_is_internal): Check ascii_sequence_p when looking up the cache.
1194         (menu_item_p): Remove.
1195         (where_is_internal_1): Don't ignore menu-items.
1197 2000-12-20  Gerd Moellmann  <gerd@gnu.org>
1199         * xdisp.c (hscroll_window_tree): Take window's min_hscroll
1200         into account.
1202         * window.c (make_window): Initialize window's min_hscroll.
1203         (Fset_window_hscroll): Set window's hscroll and min_hscroll.
1204         (set_window_buffer, temp_output_buffer_show): Set min_hscroll
1205         to zero.
1206         (struct saved_window): New member min_hscroll.
1207         (SAVED_WINDOW_VECTOR_SIZE): Set to 17.
1208         (Fset_window_configuration): Set window's min_hscroll.
1209         (save_window_save): Save window's min_hscroll.
1210         (compare_window_configurations): Compare min_hscroll values.
1212         * window.h (struct window): New member min_hscroll.
1214         * keyboard.c (echo_prompt): Prevent a compiler warning.
1216         * xdisp.c (try_cursor_movement): Fix last change.  The real
1217         condition is that PT is at the end of the row, and should
1218         be displayed at the start of the next row.
1219         
1220         * xdisp.c (try_cursor_movement): If we end on a partially
1221         visible line, end we already decided to scroll, return -1.
1223         * dispextern.h (ensure_frame_matrix): Add prototype.
1225         * window.c (delete_window, Fsplit_window)
1226         (Fset_window_configuration): Call ensure_frame_matrix.
1228         * dispnew.c (fake_current_matrices, ensure_frame_matrix): New
1229         functions.
1230         (adjust_frame_glyphs_for_frame_redisplay): If display has been
1231         completed, call fake_current_matrices instead of marking frame
1232         garbaged.
1234 2000-12-20  Jason Rumney  <jasonr@gnu.org>
1236         * w32fns.c (syms_of_w32fns): Initialize and staticpro tip_frame.
1238 2000-12-19  Eli Zaretskii  <eliz@is.elta.co.il>
1240         * fns.c (Frequire): Doc fix.
1242 2000-12-19  Gerd Moellmann  <gerd@gnu.org>
1244         * window.c (window_scroll_pixel_based): Don't use
1245         move_it_vertically.
1247         * dispnew.c (direct_output_for_insert): Fix check for mini-window
1248         currently displaying a message.
1250         * bytecode.c (toplevel) [CHECK_FRAME_FONT]: Include frame.h and
1251         xterm.h.
1252         (Fbyte_code) [CHECK_FRAME_FONT]: Check the selected frame's font.
1254 2000-12-18  Andrew Innes  <andrewi@gnu.org>
1256         * w32.c (w32_strerror): New function.
1258         * w32.h (w32_strerror): New extern.
1260         * w32fns.c (Fw32_shell_execute): Use it.
1262 2000-12-18  Gerd Moellmann  <gerd@gnu.org>
1264         * s/hpux10.h (_FILE_OFFSET_BITS): Undef again.
1266 2000-12-18  Eli Zaretskii  <eliz@is.elta.co.il>
1268         * msdos.c (IT_set_face): Obey inverse_video.
1270 2000-12-18  Kenichi Handa  <handa@etl.go.jp>
1272         * dired.c (directory_files_internal): Always return decoded filenames.
1274 2000-12-18  Gerd Moellmann  <gerd@gnu.org>
1276         * xterm.c (x_connection_closed): Prevent being called recursively
1277         because of an error condition in XtCloseDisplay.
1278         
1279         * xdisp.c (init_iterator): If noninteractive, and the frame's
1280         face cache is null, make one.
1282         * xfns.c (show_busy_cursor): Check for live frames more
1283         thoroughly.
1285         * process.c (wait_reading_process_input): Check for pending
1286         input when running timers.
1288 2000-12-18  Eli Zaretskii  <eliz@is.elta.co.il>
1290         * msdos.c (IT_write_glyphs): Compute the glyph face from
1291         str->face_id.
1293 2000-12-18  Kenichi Handa  <handa@etl.go.jp>
1295         * process.c (read_process_output): Don't run a filter if the code
1296         decoder produces nothing but carryover.
1298 2000-12-17  Andrew Innes  <andrewi@gnu.org>
1300         * w32.c (sys_rename): Only check errno against EEXIST, and not
1301         EACCES, when determining whether rename failed because the target
1302         exists.  This was resulting in indefinite looping on Windows 9x if
1303         the source file was locked by another process.
1305         * w32fns.c (Ffile_system_info): New function.
1306         (syms_of_w32fns): Defsubr it.
1308 2000-12-17  Gerd Moellmann  <gerd@gnu.org>
1310         * window.c (coordinates_in_window): Fix computation for
1311         position on vertical line between mode lines.
1313         * xfns.c (unwind_create_frame): Return t if frame was deleted.
1314         Don't alter tip_frame or tip_window.
1315         (unwind_create_tip_frame): Set tip_frame to nil only if frame
1316         was deleted.
1318         * w32fns.c (unwind_create_frame): Return t if frame was deleted.
1319         Don't alter tip_frame or tip_window.
1320         (unwind_create_tip_frame): Set tip_frame to nil only if frame
1321         was deleted.
1323 2000-12-16  Eli Zaretskii  <eliz@is.elta.co.il>
1325         * fileio.c (Fcopy_file): Rename the last argument to keep_time, to
1326         be consistent with the doc string.  Reported by NAKAJIMA Mikio
1327         <minakaji@osaka.email.ne.jp>.
1329 2000-12-16  Kenichi Handa  <handa@etl.go.jp>
1331         * xfaces.c (Vface_ignored_fonts): New variable.
1332         (x_face_list_fonts): Ignore fonts matching Vface_ignored_fonts.
1333         (syms_of_xfaces): Declare Vface_ignored_fonts as a Lisp variable.
1335 2000-12-15  Gerd Moellmann  <gerd@gnu.org>
1337         * dispnew.c (update_window): Detect pending input every nth line
1338         updated, i.e. do it depending on real work done, and not on the
1339         vpos of the line.
1341         * xterm.c (expose_window): Don't redraw the window that's
1342         currently being updated.
1344         * window.c (Fset_window_point): Remove test for
1345         cursor_in_non_selected_windows.
1347         * lread.c (read1): Recognize end of file after `\\'.
1349         * xfns.c (x_create_tip_frame): Use unwind_create_tip_frame,
1350         not unwind_create_frame.
1352 2000-12-15  Dave Love  <fx@gnu.org>
1354         * s/usg5-4.h (bcopy) [IRIX6]: Don't special-case definition of
1355         bcopy & al.
1357         * s/irix6-5.h: #undef bcopy & al here.  Include strings.h.
1359 2000-12-15  Kenichi Handa  <handa@etl.go.jp>
1361         * coding.c (setup_coding_system): Clear all members of the struct
1362         coding_system at first.
1363         (detect_coding): Call detect_coding_mask with a correct MULTIBYTEP
1364         argument.
1365         (code_convert_region): Don't override coding->src_multibyte and
1366         coding->dst_multibyte.
1368         * fns.c (Fmd5): Docstring improved.
1370 2000-12-15  Miles Bader  <miles@gnu.org>
1372         * xdisp.c (window_box_height): Only use mode-line glyph-rows that
1373         are actually marked as mode-lines; otherwise use
1374         estimate_mode_line_height.
1376 2000-12-14  Gerd Moellmann  <gerd@gnu.org>
1378         * editfns.c (Fformat): Prevent a buffer overrun when the format
1379         specifies a precision.
1381 2000-12-14  Eli Zaretskii  <eliz@is.elta.co.il>
1383         * msdos.c (Fmsdos_set_mouse_buttons): Signal an error if the
1384         argument is outside the range [2..3].
1386 2000-12-14  Andrew Innes  <andrewi@gnu.org>
1388         * w32fns.c (Fx_hide_tip): Avoid unnecessary work when there's
1389         nothing to do.  Bind inhibit-quit.
1390         (tip_frame): Make it a Lisp_Object.
1391         (x_create_tip_frame): Set tip_frame after it has been added to
1392         Vframe_list.
1393         (Fx_show_tip): Don't set tip_frame here.
1394         (image_cache_refcount, dpyinfo_refcount) [GLYPH_DEBUG]: New
1395         variables.
1396         (unwind_create_frame, unwind_create_tip_frame): New functions.
1397         (Fx_create_frame, x_create_tip_frame): Handle errors signaled
1398         while a frame is only partially constructed.
1400         * w32term.c (clear_mouse_face): Treat tip_frame as a Lisp_Object.
1401         (x_free_frame_resources): New function.
1402         (x_destroy_window): Use it.
1404 2000-12-14  Gerd Moellmann  <gerd@gnu.org>
1406         * xfns.c (Fx_backspace_delete_keys_p): New function.
1407         (syms_of_xfns): Defsubr it.
1409         * config.in (HAVE_XKBGETKEYBOARD): Add.
1411 2000-12-14  Kenichi Handa  <handa@etl.go.jp>
1413         * keyboard.c (echo_prompt): Argument type changed to Lisp_Object.
1414         Always store string in multibyte representation in echobuf.
1415         (echo_char): Always store string in multibyte representation in
1416         echobuf.
1417         (echo_now): Call message2_nolog with the arg MULTIBYTE 1.
1418         (read_key_sequence): Adjusted for the change of echo_prompt.
1420         * fns.c (Fmd5): Docstring improved.
1422         * lisp.h (detect_coding_system): Prototype adjusted.
1424         * coding.c (ONE_MORE_BYTE_CHECK_MULTIBYTE): New macro.
1425         (detect_coding_emacs_mule, detect_coding_iso2022,)
1426         (detect_coding_sjis, detect_coding_big5, detect_coding_utf_8)
1427         (detect_coding_utf_16, detect_coding_ccl): Make them static.  New
1428         argument MULTIBYTEP.  Callers changed.
1429         (detect_coding_mask, detect_coding_system): New argument
1430         MULTIBYTEP.  Callers changed.
1431         (decode_coding_string): Set coding->src_multibyte and
1432         coding->dst_multibyte before calling detect_coding and detect_eol.
1433         Update them after some coding system is detected.
1434         
1435 2000-12-13  Stefan Monnier  <monnier@cs.yale.edu>
1437         * keymap.c (get_keyelt): Only eval the filter if `autoload' is set.
1439         * keyboard.c (menu_bar_items, tool_bar_items):
1440         Set `autoload' when looking up `tool-bar' or `menu-bar' submap.
1442 2000-12-13  Gerd Moellmann  <gerd@gnu.org>
1444         * xfns.c (image_cache_refcount, dpyinfo_refcount) [GLYPH_DEBUG]: 
1445         New variables.
1446         (unwind_create_frame, unwind_create_tip_frame): New functions.
1447         (Fx_create_frame, x_create_tip_frame): Handle errors signaled
1448         while a frame is only partially constructed.
1450         * xterm.h (x_free_frame_resources): Declare.
1452         * xterm.c (x_free_frame_resources): New function.
1453         (x_destroy_window): Use it.
1455         * dispnew.c (update_window): If do_mouse_tracking is non-nil,
1456         don't interrupt the update for pending input initially, i.e.
1457         update at least some lines.
1459         * keyboard.c (do_mouse_tracking): Make externally visible.
1460         
1461         * xterm.c (x_term_init): Declare gray_bitmap_bits as `extern char *'.
1463         * xfns.c (gray_bitmap_bits): Declare `char *'.
1465 2000-12-12  Gerd Moellmann  <gerd@gnu.org>
1467         * xdisp.c (display_tool_bar_line): Make sure that tool bar
1468         lines start with a relief line.
1470 2000-12-12  Dave Love  <fx@gnu.org>
1472         * window.c (Fdisplay_buffer): Doc fix.
1473         (Fwindow_list): Remove unused var.
1475         * buffer.h (mmap_set_vars): Declare.
1477         * window.h (Fset_window_point): Declare.
1479 2000-12-12  Eli Zaretskii  <eliz@is.elta.co.il>
1481         * msdos.c (fast_find_position): Don't overstep the last window row.
1482         (IT_note_mouse_highlight): Initialize portion to -1.  Remove
1483         unused variable `area'.  When looking for a row under (X,Y), give
1484         up if some of the previous rows is not enabled.
1486 2000-12-12  Gerd Moellmann  <gerd@gnu.org>
1488         * window.c (Fset_window_point): If displaying cursors in windows
1489         other than the selected window, make sure redisplay updates
1490         other windows to show the new value of point in the window.
1492         * dispextern.h (cursor_in_non_selected_windows): Declare extern.
1494         * buffer.c (Fkill_buffer): Don't Fset_buffer when testing if
1495         the buffer is the sole visible buffer when in the mini-buffer.
1497         * xdisp.c (setup_echo_area_for_printing, with_echo_area_buffer): 
1498         Bind `inhibit-read-only' to t.
1499         (unwind_with_echo_area_buffer): Use AREF.
1501         * xfns.c (Fx_hide_tip): Simplified.
1503         * s/freebsd.h, s/netbsd.h (GC_MARK_STACK): Use
1504         GC_MAKE_GCPROS_NOOPS instead of `1'.
1506         * s/gnu-linux.h (GC_MARK_STACK): Define as GC_MAKE_GCPROS_NOOPS.
1508 2000-12-11  Gerd Moellmann  <gerd@gnu.org>
1510         * xfns.c (Fx_hide_tip): Fix last change.
1511         
1512         * xfns.c (Fx_hide_tip): Avoid unnecessary work when there's
1513         nothing to do.  Bind inhibit-quit.
1514         (tip_frame): Make it a Lisp_Object.
1515         (x_create_tip_frame): Set tip_frame after it has been added to
1516         Vframe_list.
1517         (Fx_show_tip): Don't set tip_frame here.
1519         * xterm.c (clear_mouse_face): Treat tip_frame as a Lisp_Object.
1521         * xdisp.c (prepare_menu_bars): Changes for tip_frame being a
1522         Lisp_Object.
1524         * dispextern.h: Change external declaration of tip_frame.
1526         * keymap.c (Fkey_description): If KEYS is an empty key sequence,
1527         return an empty string.
1529         * xdisp.c (try_cursor_movement): Check update_mode_lines instead
1530         of the window's update_mode_line flag, since the former is set by
1531         force-mode-line-update, not the latter.  This makes
1532         column-number-mode slightly faster.
1533         
1534         * xdisp.c (try_window_id) <all changes above window start>:
1535         Set the cursor.
1537 2000-12-11  Paul Eggert  <eggert@twinsun.com>
1539         * config.in (HAVE_FTELLO): Remove.
1540         (HAVE_FSEEKO): Add.
1541         (_XOPEN_SOURCE): Remove; the large-file code no longer needs it.
1542         * lread.c (file_offset, file_tell): Depend on HAVE_FSEEKO, not
1543         HAVE_FTELLO.
1544         * s/hpux10.h (_FILE_OFFSET_BITS): Do not undef.
1545         * s/isc3-0.h, s/osf5-0.h: Update comment about _XOPEN_SOURCE.
1546         
1547 2000-12-11  Miles Bader  <miles@gnu.org>
1549         * window.c (displayed_window_lines): Don't round up when
1550         converting empty space at bottom to lines.
1551         Handle non-newline-terminated final lines properly.
1552         (Fwindow_text_height): New function (used to be in lisp).
1553         (syms_of_window): Initialize it.
1555 2000-12-09  Stefan Monnier  <monnier@cs.yale.edu>
1557         * syntax.c (scan_lists): Check that the right quote char has the
1558         right Sstring syntax when jumping over strings.
1559         (init_syntax_once): Use Smax rather than 13.
1561 2000-12-09  Miles Bader  <miles@gnu.org>
1563         * window.c (Fpos_visible_in_window_p): Replace FULLY parameter
1564         with PARTIALLY, inverting the sense.
1565         (window_scroll_pixel_based): Scroll partially visible lines into
1566         place if we hit the beginning or end of the buffer.
1567         (displayed_window_lines): Don't include partially visible lines.
1568         (Fmove_to_window_line): Skip past any partially visible first line.
1570 2000-12-08  Gerd Moellmann  <gerd@gnu.org>
1572         * keymap.c (current_minor_maps): Use malloc.  Prevent a leak.
1574         * tparam.c (tparam1): Change the way buffers are reallocated to be
1575         portable and less obfuscated.
1577         * termcap.c (tgetent): Change the way buffers are reallocated to
1578         be portable and less obfuscated.
1580         * macros.c (store_kbd_macro_char): Change the way buffers are
1581         reallocated to be portable and less obfuscated.
1583         * lread.c (read1): Change the way buffers are reallocated to be
1584         portable and less obfuscated.
1586         * doc.c (Fsubstitute_command_keys): Change the way buffers
1587         are reallocated so that it is portable.
1589 2000-12-07  Eli Zaretskii  <eliz@is.elta.co.il>
1591         * dosfns.c (Ffile_system_info): New function.
1592         (syms_of_dosfns): Defsubr it.
1594 2000-12-07  Stefan Monnier  <monnier@cs.yale.edu>
1596         * alloc.c (gc_sweep): Add comment.
1598 2000-12-07  Gerd Moellmann  <gerd@gnu.org>
1600         * sound.c (vox_configure): Change order of ioctls.  Don't
1601         set SNDCTL_DSP_SPEED from bps, don't set SNDCTL_DSP_SAMPLESIZE.
1602         Ignore errors when changing volume.
1603         (vox_close): Don't reset the device.
1605         * process.c (read_process_output): Make sure the process marker's
1606         position is valid when the process buffer is changed in
1607         after-change functions.  W3 does that.
1608         
1609         * xfns.c (x_free_gcs): New function.
1611         * xterm.h (x_free_gcs): Add prototype.
1613         * widget.c (EmacsFrameDestroy): Call x_free_gcs instead of
1614         freeing GCs here.
1616         * xterm.c (x_destroy_window): Call x_free_gcs so that
1617         resources of non-toolkit X windows will be freed.
1619 2000-12-07  Andrew Innes  <andrewi@gnu.org>
1621         * w32fns.c (xlfd_charset_of_font): Fix last change.
1623 2000-12-06  Dave Love  <fx@gnu.org>
1625         * md5.h (__P): Don't define -- it comes from config.h.
1627         * strftime.c: Change some #if foo to #ifdef foo.
1629 2000-12-06  Andrew Innes  <andrewi@gnu.org>
1631         * w32term.h (CP_INVALID): Rename to CP_UNKNOWN.
1633         * w32fns.c (xlfd_charset_of_font): Don't overwrite fontname
1634         argument.
1635         (w32_codepage_for_font): Rename CP_INVALID to CP_UNKNOWN.
1636         (w32_list_fonts): Don't choke if pattern doesn't specify a
1637         codepage.
1639 2000-12-06  Gerd Moellmann  <gerd@gnu.org>
1641         * alloc.c (gc_sweep): Prevent symbols read during loadup
1642         from being freed.
1644         * xdisp.c (underlying_face_id): New function.
1645         (handle_face_prop, face_before_or_after_it_pos): Use it
1646         to determine the face ``under'' a string.  Let strings inherit
1647         the face of the buffer under them.
1649         * xfaces.c (face_at_string_position): Update function comment.
1650         
1651         * dispnew.c (adjust_glyph_matrix): Don't reuse a window's current
1652         matrix if the window's left position has changed; we need to
1653         redraw it in this case.
1655         * dispextern.h (struct glyph_matrix): Add member window_left_x.
1657         * window.c (coordinates_in_window): Check mouse on mode-line or
1658         header-line first.
1660         * alloc.c (Fgarbage_collect): Dox fix.  Return a list as
1661         advertized by the function documentation.
1663         * window.c (syms_of_window): Doc fix.
1665         * sound.c (vox_configure): Set volume for left and right channel.
1666         (sound_cleanup): Return nil.
1668         * xdisp.c (move_it_by_lines): Fix paren typo.
1670         * xterm.c (x_load_font): Don't use the font's max_bounds for
1671         computing the height of the font.  If max_bounds' ascent or
1672         descent are greater than the font's ascent or descent, this means
1673         glyphs overlap, which should be handled now by redisplay.
1675         * window.c (Veven_window_heights): New variable.
1676         (syms_of_window): DEFVAR_LISP it.
1677         (Fdisplay_buffer): Check Veven_window_heights before evening the
1678         window heights.
1679         
1680 2000-12-06  Miles Bader  <miles@gnu.org>
1682         * xfaces.c (Finternal_set_lisp_face_attribute): If FRAME is `t',
1683         update `default-frame-alist' instead of setting no frame parameters.
1685 2000-12-06  Kenichi Handa  <handa@etl.go.jp>
1687         * composite.c (update_compositions): Fix typo (use the correct
1688         variable).
1690 2000-12-05  Jason Rumney  <jasonr@gnu.org>
1692         * md5.h: Remove underscores from function declarations.
1693         (__attribute__, __alignof__) [!__GNUC__]: Define.
1695         * md5.c: Delay include of md5.h until after namespace cleaning.
1697         * makefile.w32-in (fns.o): Depend on md5.h
1698         (md5.o): New target.
1699         (sunfns.o): Remove.
1701         * makefile.nt: Likewise.
1703 2000-12-05  Jason Rumney  <jasonr@altavista.net>
1705         * w32term.c (expose_area): Complete last change.
1707 2000-12-05  Ken Raeburn  <raeburn@gnu.org>
1709         * minibuf.c: Include intervals.h.
1711 2000-12-05  Jason Rumney  <jasonr@gnu.org>
1713         * w32term.c (x_produce_glyphs): If a font for a component of
1714         a composition is not found, use 1 pixel dot ascent and 0 dot
1715         descent value to avoid displaying terribly tall empty boxes.
1716         (expose_area): Pass x-coordinate relative to the exposed
1717         area to x_draw_glyphs instead of a window-relative coordinate.
1719 2000-12-05  Gerd Moellmann  <gerd@gnu.org>
1721         * xdisp.c (next_element_from_ellipsis): Save face before selective
1722         display in saved_face_id, and set face_before_selective_p.
1723         (reseat_1): Reset face_before_selective_p.
1724         (append_space, extend_face_to_end_of_line): If iterator's
1725         face_before_selective_p is set, use the face from saved_face_id.
1726         (extend_face_to_end_of_line): For tty frames, make sure to
1727         use the right face id when producing spaces at the end of
1728         the line.
1730         * dispextern.h (struct it): Add face_before_selective_p.
1732         * keyboard.c (record_char): Don't record identical help-echo
1733         events in recent_keys.
1735         * xterm.c [USE_X_TOOLKIT]: Close the display.
1736         (xim_close_dpy): Handle case that the display has been closed.
1738         * xterm.c (x_destroy_window): Reset the frame's X window after
1739         destroying it.
1741         * dispnew.c (adjust_glyph_matrix): Make sure to initialize local
1742         variable window_width.
1743         (line_draw_cost): Fix code skipping over spaces at the end of the
1744         line when must_write_spaces is not set.
1745         (scrolling_window): Fix code inserting runs in list of all runs.
1747 2000-12-05  Kenichi Handa  <handa@etl.go.jp>
1749         * coding.c (setup_coding_system): Be sure to initialize
1750         coding->category_idx.
1752 2000-12-04  Gerd Moellmann  <gerd@gnu.org>
1754         * xterm.c (PER_CHAR_METRIC): Removed because not used.
1755         
1756         * xterm.c (expose_area): Pass x-coordinate relative to the exposed
1757         area to x_draw_glyphs instead of a window-relative coordinate.
1759         * fileio.c (auto_save_error): Add parameter ERROR.  Show the
1760         error in the message.
1762         * keyboard.c (Fread_key_sequence): Don't start the busy cursor
1763         timer after having read a key.  It's not good for code reading
1764         several keys in a loop, like an input method.
1766         * fileio.c (Finsert_file_contents): When VISIT is t, don't
1767         record undo information for format-decode.
1769         * undo.c (Fprimitive_undo): Bind inhibit-read-only to t if
1770         current buffer is read-only, not if it isn't.
1772         * keyboard.c (record_char): Record `help-echo' input events
1773         in recent_keys only if they display some help.  Don't record
1774         `help-echo' events as macro char.
1776 2000-12-04  Richard M. Stallman  <rms@caffeine.ai.mit.edu>
1778         * editfns.c (save_excursion_restore): Don't move point
1779         in another window if it is showing the wrong buffer.
1780         Avoid the call to Fwindow_live_p, for speed.
1782 2000-12-04  Kenichi Handa  <handa@etl.go.jp>
1784         * xfaces.c (struct font_name): New member registry_priority.
1785         (split_font_name): Initialize the above member to zero.
1786         (concat_font_list): New function.
1787         (font_list): Include fonts of all alternative registries.
1788         (FONT_POINT_SIZE_QUANTUM): New macro.
1789         (better_font_p): Ignore point size difference less than
1790         FONT_POINT_SIZE_QUANTUM.  Use registry_prioprity as a last resort.
1792         * xterm.c (x_produce_glyphs): If a font for a component of
1793         a composition is not found, use 1 pixel dot ascent and 0 dot
1794         descent value to avoid displaying terribly tall empty boxes.
1796         * ccl.c (stack_idx_of_map_multiple): Don't use C initializier.
1798 2000-12-03  Ken Raeburn  <raeburn@gnu.org>
1800         * coding.h (code_convert_string1): Declare.
1802         * fns.c (Fmd5): Pass lisp objects, not integers, to call3.
1804         * lisp.h (Fmake_variable_buffer_local, Fbuffer_file_name):
1805         Declare.
1807 2000-12-02  Jason Rumney  <jasonr@gnu.org>
1809         * w32term.c (w32_bdf_per_char_metric): Dereference pointer
1810         correctly for single byte character case.
1811         (w32_per_char_metric): Do not try to make any assumptions about
1812         the metrics of BDF fonts.
1813         (x_estimate_mode_line_height): If `mode-line' face
1814         hasn't a font, use that of the frame, as drawing glyphs
1815         does.
1816         (note_mouse_highlight): Change the cursor shape on the vertical
1817         border between windows [not enabled].
1819         * w32term.h (struct w32_output): Add member horizontal_drag_cursor.
1821         * w32fns.c (Fx_create_frame): Reintroduce the call to
1822         face-set-after-frame-defaults.
1823         (Vx_window_horizontal_drag_shape): New variable.
1824         (syms_of_xfns): DEFVAR_LISP it.
1825         (x_set_mouse_color): Create frame's horizontal_drag_cursor [not
1826         enabled].
1828 2000-12-02  Simon Josefsson  <simon@josefsson.org>
1830         * fns.c (Fmd5): Use a different logic to decide the coding system
1831         to use.
1833         * coding.h (Qwrite_region, Qcoding_system_error): Declare extern.
1835 2000-12-02  Eli Zaretskii  <eliz@is.elta.co.il>
1837         * fileio.c (Fread_file_name) [DOS_NT]: Don't crash if homedir is
1838         NULL.
1840 2000-12-01  Gerd Moellmann  <gerd@gnu.org>
1842         * xterm.c (x_calc_absolute_position): Don't subtract menubar's
1843         height for YNegative.
1844         (x_calc_absolute_position) [USE_MOTIF]: Use the column widget's
1845         height; also see comment there.
1847         * window.c (coordinates_in_window): Handle computations for
1848         positions on the vertical bar and fringes differently for
1849         window-system frames.  Consider some pixels near the vertical bar
1850         as on the bar if the frame doesn't have vertical scroll bars.
1851         Associate positions between mode or header lines with the
1852         right window, the left one.
1854 2000-12-01  Jason Rumney  <jasonr@gnu.org>
1856         * w32term.c (w32_clear_window): Avoid clearing an invalid frame.
1858         * w32xfns.c (get_frame_dc): Avoid changing the palette on an
1859         invalid frame.
1861 2000-12-01  Gerd Moellmann  <gerd@gnu.org>
1863         * window.c (struct saved_window): Add members orig_top and
1864         orig_height.
1865         (SAVED_WINDOW_VECTOR_SIZE): Increment to 16.
1866         (save_window_save, Fset_window_configuration): Save/restore
1867         window's orig_top and orig_height.
1869 2000-12-01  Jason Rumney  <jasonr@gnu.org>
1871         * w32term.c (x_draw_vertical_border): Fix call to w32_fill_rect.
1873         * w32fns.c (x_set_cursor_color): Fix last change.
1875 2000-11-30  Gerd Moellmann  <gerd@gnu.org>
1877         * xdisp.c (echo_area_display): If cursor is in the echo area, make
1878         sure that the next redisplay displays the minibuffer, so that
1879         the cursor will be replaced with what the minibuffer wants.
1881         * xterm.c: Test USE_TOOLKIT_SCROLL_BARS everywhere with #ifdef and
1882         #ifndef instead of using #if.
1883         (XTread_socket) [USE_MOTIF] <KeyPress>: Call XmIsScrollBar only if
1884         USE_TOOLKIT_SCROLL_BARS is defined.
1886 2000-11-30  Jason Rumney  <jasonr@gnu.org>
1888         * w32fns.c (x_set_cursor_color): Use x_update_cursor instead of
1889         x_display_cursor.
1891 2000-11-30  Gerd Moellmann  <gerd@gnu.org>
1893         * fns.c (Fmd5): Doc fix.
1895 2000-11-30  Simon Josefsson  <simon@josefsson.org>
1897         * fns.c (Fmd5): New function.
1898         (syms_of_fns): Defsubr md5.
1900         * Makefile.in (obj): Add md5.o
1902 2000-11-30  Gerd Moellmann  <gerd@gnu.org>
1904         * md5.h, md5.c: New files, taken from glibc.
1906         * xmenu.c (popup_get_selection): Use xmalloc instead of malloc.
1908         * xterm.c (x_estimate_mode_line_height): If `mode-line' face
1909         hasn't a font, use that of the frame, as drawing glyphs
1910         does.
1912 2000-11-29  Stefan Monnier  <monnier@cs.yale.edu>
1914         * eval.c (Frun_hooks): Allow 0 arguments.
1916 2000-11-29  Gerd Moellmann  <gerd@gnu.org>
1918         * xterm.c (XTmouse_position) [USE_X_TOOLKIT]: When the mouse
1919         is over the menu bar widget, say it's not on the frame.
1921         * xfns.c (Fx_create_frame): Reintroduce the call to
1922         face-set-after-frame-defaults.
1924         * eval.c (Fsignal): Reset handling_signal.
1926 2000-11-28  Jason Rumney  <jasonr@gnu.org>
1928         * w32menu.c (add_menu_item): Reset menu item text when changing
1929         type to radio button.
1931 2000-11-28  Gerd Moellmann  <gerd@gnu.org>
1933         * xselect.c: Update copyright.
1935         * window.c (coordinates_in_window): If on a mode or header line,
1936         but sufficiently close to its start, return ``on vertical
1937         border''.  This gives us a way to drag windows horizontally when
1938         using toolkit scroll bars.
1940         * xterm.c (note_mouse_highlight): Change the cursor shape
1941         on the vertical border between windows.
1943         * xterm.h (struct x_output): Add member horizontal_drag_cursor.
1945         * xfns.c (Vx_window_horizontal_drag_shape): New variable.
1946         (syms_of_xfns): DEFVAR_LISP it.
1947         (x_set_mouse_color): Create frame's horizontal_drag_cursor.
1949         * textprop.c (text_read_only): New function.
1950         (verify_interval_modification): Use it instead of signaling
1951         `text-read-only'.  This makes it easier to catch this error
1952         with a breakpoint.: 
1954         * xdisp.c (forward_to_next_line_start): Check for newlines, 
1955         not end of line, which includes CR.
1957 2000-11-28  Kenichi Handa  <handa@etl.go.jp>
1959         * coding.c (Ffind_coding_systems_region_internal): Be sure to
1960         include no-conversion.
1962 2000-11-27  Jason Rumney  <jasonr@gnu.org>
1964         * w32fns.c (w32_load_system_font): Always mark font as double byte
1965         if codepage is unicode.
1967 2000-11-27  Gerd Moellmann  <gerd@gnu.org>
1969         * xdisp.c (forward_to_next_line_start): If already on a newline,
1970         just consume it to avoid unintended skipping over invisible text
1971         below.
1973         * keyboard.c (lucid_event_type_list_p): Handle `help-echo',
1974         `vertical-line', `mode-line' and `header-line' events.
1976         * xdisp.c (try_window_id): Avoid starting to display in the middle
1977          of a character, a TAB for instance.  This is easier than to set
1978          up the iterator exactly, and it's not a frequent case, so the
1979          additional effort wouldn't really pay off.
1981 2000-11-26  Andrew Choi  <akochoi@i-cable.com>
1983         * emacs.c (main) [macintosh]: Call syms_of_frame before calling
1984         init_window_once.
1986 2000-11-25  Jason Rumney  <jasonr@gnu.org>
1988         * keyboard.c (make_lispy_event) [mouse_wheel, drag_n_drop]: Args
1989         to window_from_coordinates should be pixel coordinates.
1991         * w32fns.c (x_to_w32_font): Do not filter out italic fonts, as new
1992         redisplay handles them properly.
1994 2000-11-25  Miles Bader  <miles@gnu.org>
1996         * indent.c (compute_motion): Keep pos_byte in sync with pos.
1998 2000-11-24  Jason Rumney  <jasonr@gnu.org>
2000         * w32.c (init_environment): Set LANG environment variable based on
2001         locale settings, if not set.
2003         * w32fns.c (x_set_tool_bar_lines): Clear internal border when
2004         making tool bar smaller. When clearing the frame, also
2005         clear current matrices. Clear frame when tool bar disappears.
2006         Don't use more lines for the tool-bar than is available.
2007         (x_change_window_heights): New function.
2009 2000-11-24  Gerd Moellmann  <gerd@gnu.org>
2011         * xdisp.c (init_from_display_pos): If POS says we're already after
2012          an overlay string ending at POS, make sure to pop the iterator
2013          because it will be in front of that overlay string.  When POS is
2014          ZV, we've thereby also ``processed'' overlay strings at ZV.
2016         * xfaces.c (lface_from_face_name): Function comment fix.
2018 2000-11-24  Miles Bader  <miles@gnu.org>
2020         * xdisp.c (display_menu_bar, display_mode_line): Change the way we
2021         apply `mode-line-inverse-video' -- zero means force display using
2022         the default face, non-zero means display using the specialized face.
2023         (syms_of_xdisp): `mode-line-inverse-video' defaults to true again.
2025 2000-11-23  Kenichi Handa  <handa@etl.go.jp>
2027         * alloc.c (Fmake_string): Use MAX_MULTIBYTE_LENGTH, instead of
2028         hard coded `4'.
2030 2000-11-23  Eli Zaretskii  <eliz@is.elta.co.il>
2032         * coding.c (decode_coding_emacs_mule): Fix the case of
2033         CODING_EOL_LF, which used uninitialized value of c.
2035 2000-11-23  Stefan Monnier  <monnier@cs.yale.edu>
2037         * xdisp.c (syms_of_xdisp): Make fontification-functions buffer-local.
2039 2000-11-22  Gerd Moellmann  <gerd@gnu.org>
2041         * buffer.c (Fmake_indirect_buffer): Don't treat nil as a
2042         buffer object.
2044         * frame.h (struct frame): Replace desired_tool_bar_items,
2045         current_tool_bar_items, n_desired_tool_bar_items,
2046         n_current_tool_bar_items with tool_bar_items and n_tool_bar_items.
2048         * frame.c (make_frame): Change initialization of tool bar
2049         items accordingly.
2051         * xterm.c (x_handle_tool_bar_click, note_tool_bar_highlight):
2052         Change references to members deleted from struct frame to use the
2053         new ones.
2055         * xdisp.c (update_tool_bar, build_desired_tool_bar_string): Change
2056         references to members deleted from struct frame to use the new
2057         ones.
2059         * dispnew.c (update_frame): Do nothing with frame's tool bar
2060         items.
2062         * alloc.c (mark_object) <frame>: Mark tool bar items differently.
2064         * w32term.c (x_tool_bar_item, w32_handle_tool_bar_click)
2065         (note_tool_bar_highlight): Change references to members deleted
2066         from struct frame to use the new ones.
2068 2000-11-23  Miles Bader  <miles@gnu.org>
2070         * xdisp.c (display_menu_bar): Or `mode-line-inverse-video' with
2071         the face's inverse-video attribute, rather than overriding it.
2073 2000-11-22  Gerd Moellmann  <gerd@gnu.org>
2075         * xfns.c (x_set_tool_bar_lines): Clear internal border when
2076         making tool bar smaller.
2078 2000-11-22  Dave Love  <fx@gnu.org>
2080         * s/sol2-5.h (_LARGEFILE_SOURCE, _FILE_OFFSET_BITS): Don't define.
2082 2000-11-22  Miles Bader  <miles@gnu.org>
2084         * keyboard.c (Vminibuffer_message_timeout): New variable.
2085         (command_loop_1): Use it to determine message timeout.
2086         (syms_of_keyboard): Initialize it.
2088         * xdisp.c (syms_of_xdisp): `mode-line-inverse-video' defaults to nil.
2090 2000-11-22  Kenichi Handa  <handa@etl.go.jp>
2092         * sysdep.c: Move the code for declaring h_errno after #include
2093         <netdb.h>.
2095 2000-11-21  Gerd Moellmann  <gerd@gnu.org>
2097         * xfns.c (Fx_hide_tip) [USE_LUCID]: Add a hack to redisplay
2098         the menu bar when the tooltip is unmapped.
2100         * buffer.c (Fkill_buffer): Notice if the buffer to kill is the
2101         sole visible buffer when we're currently in the mini-buffer, and
2102         give up if so.
2103         
2104 2000-11-21  Jason Rumney  <jasonr@gnu.org>
2106         * w32select.c (Fw32_set_clipboard_data): Save a copy of what is
2107         put on the clipboard.
2108         (Fw32_get_clipboard_data): Compare data on clipboard with saved
2109         copy of what Emacs last put there. If they are the same, do not
2110         use the clipboard copy to avoid losing data due to coding
2111         conversions. 
2113 2000-11-22  Miles Bader  <miles@gnu.org>
2115         * minibuf.c (Vminibuffer_prompt_properties): New variable.
2116         (syms_of_minibuf): Initialize it.
2117         (read_minibuf): Add properties from Vminibuffer_prompt_properties
2118         to prompt, don't make read-only.
2120 2000-11-21  Gerd Moellmann  <gerd@gnu.org>
2122         * bytecode.c (Fbyte_code) <Bvarbind, Bunwind_protect>: Add
2123         BEFORE/AFTER_POTENTIAL_GC.
2125         * s/hpux10.h (_FILE_OFFSET_BITS): Undef.
2127         * buffer.c (mmap_free_1): Avoid a compiler warning.
2129         * term.c, cm.c: Don't try to include termcap.h; see comment there.
2131 2000-11-21  Kenichi Handa  <handa@etl.go.jp>
2133         * s/sol2-5.h: Move #undef USE_MMAP_FOR_BUFFERS out of #if 0
2134         ... #endif scope.
2136 2000-11-20  Gerd Moellmann  <gerd@gnu.org>
2138         * xfns.c (x_create_tip_frame): Use CWSaveUnder only if the 
2139         screen supports it.
2141         * s/gnu-linux.h: Don't use `#cpu'.
2143         * buffer.c (MAP_FAILED): Define it as `((void *) -1)' if it's
2144         not defined in mman.h.
2146         * xterm.c (scroll_bar_windows, scroll_bar_windows_size): New
2147         variables.
2148         (x_send_scroll_bar_event): Store the window in scroll_bar_windows
2149         and store an index in the XClientMessageEvent.  Storing a
2150         Lisp_Object or pointer can fail on a 64 bit system, since X only
2151         transfers 32 bits.
2152         (x_scroll_bar_to_input_event): Get the window from
2153         scroll_bar_windows.
2154         
2155 2000-11-20  Dave Love  <fx@gnu.org>
2157         * Makefile.in (LIBX): Reorder for -lX11 after -lXpm.
2159 2000-11-20  Gerd Moellmann  <gerd@gnu.org>
2161         * s/sol2-5.h (USE_MMAP_FOR_BUFFERS): Undefine.
2163 2000-11-20  Kenichi Handa  <handa@etl.go.jp>
2165         * charset.c (get_new_private_charset_id): Don't limit CHARSET_ID
2166         by WIDTH.
2168         * alloc.c (make_string): Fix previous change.  Be sure to make
2169         unibyte string correctly.
2171 2000-11-19  Gerd Moellmann  <gerd@gnu.org>
2173         * window.c (Fwindow_list): Change parameter list to be XEmacs
2174         compatible.
2175         (window_list_1): New function.
2176         (window_loop): Use it instead of Fwindow_list.
2178         * sysdep.c (emacs_ospeed): New variable.
2179         (toplevel): Don't declare ospeed extern.
2180         (init_baud_rate): Use emacs_ospeed instead of ospeed.
2182         * termcap.c (ospeed): Remove.
2183         (tputs) [!emacs]: Remove unused code.
2184         (tgetent): Avoid a compiler warning.
2186         * xterm.c (x_set_toolkit_scroll_bar_thumb, x_scroll_bar_create)
2187         (x_scroll_bar_remove, XTset_vertical_scroll_bar): Call
2188         SCROLL_BAR_X_WIDGET with additional argument DPY.
2190         * xterm.h (struct scroll_bar): Members x_widget_low, x_widget_high
2191         removed.
2192         (SCROLL_BAR_X_WIDGET): Get the widget via XtWindowToWidget.
2193         Take the X display as additional argument.
2194         (SET_SCROLL_BAR_X_WIDGET): Store the window of the widget, since
2195         `Widget' is a pointer type that's not easily stored in Lisp_Object
2196         form in a portable way.
2197         
2198         * dispnew.c (update_text_area): Fix last change.
2200 2000-11-18  Gerd Moellmann  <gerd@gnu.org>
2202         * xdisp.c: Use BINDING_STACK_SIZE throughout.
2204         * xfns.c (x_set_tool_bar_lines): When clearing the frame, also
2205         clear current matrices.
2207         * buffer.c (mmap_enlarge): Don't print a message on stderr
2208         if mapping new memory at the end of the existing region fails.
2210         * dispnew.c (update_text_area): Don't skip over equal glyphs
2211         when the last current glyph overlaps the glyph to its right.
2213 2000-11-18  Miles Bader  <miles@gnu.org>
2215         * xdisp.c (message_log_check_duplicate): Let "..."-detection match
2216         lines that *end* with "..." too (that's the most common case!).
2218 2000-11-18  Gerd Moellmann  <gerd@gnu.org>
2220         * xdisp.c (resize_mini_window): Temporarily change to the
2221         mini-window's buffer if necessary.
2223         * xfns.c (Fx_show_tip): Use default y-offset of -10 so that
2224         the tooltip obscures less text under it.
2226 2000-11-17  Gerd Moellmann  <gerd@gnu.org>
2228         * puresize.h (BASE_PURESIZE): Increase to 700000.
2230 2000-11-18  Jason Rumney  <jasonr@gnu.org>
2232         * w32term.c (w32_draw_bitmap): Use face to set colors.
2234 2000-11-17  Dave Love  <fx@gnu.org>
2236         * lread.c (Fload): Fix #ifdef for pcc.
2238 2000-11-17  Gerd Moellmann  <gerd@gnu.org>
2240         * xdisp.c (pos_visible_p): Compute the default character height
2241         differently.
2243 2000-11-16  Gerd Moellmann  <gerd@gnu.org>
2245         * xdisp.c (pos_visible_p): Handle case that we reach ZV without
2246         knowing the line's height; use the default font's height in that
2247         case.
2249         * xfaces.c (weight_table): Add `demi' with the same meaning as
2250         `demibold'.
2252 2000-11-16  Kenichi Handa  <handa@etl.go.jp>
2254         * dispnew.c (null_row): New global static variable.
2255         (clear_glyph_row): Delete local static variable null_row.
2257 2000-11-15  Jason Rumney  <jasonr@gnu.org>
2259         * w32term.c (HIGHLIGHT_COLOR_DARK_BOOST_LIMIT): New constant.
2260         (w32_alloc_lighter_color): Use new brightness calculations from
2261         xterm.c. Scale delta to be in the range expected by W32.
2262         (w32_draw_relief_rect): Use frame relief colors.
2264 2000-11-15  Gerd Moellmann  <gerd@gnu.org>
2266         * frame.c (syms_of_frame_1): Removed; code moved to syms_of_frame.
2267         (Qinhibit_default_face_x_resources): New variable.
2268         (syms_of_frame): Initialize it.
2269         (Fmodify_frame_parameters): Bind inhibit-default-face-x-resources.
2271         * xdisp.c (pos_visible_p): Improve function comment.
2273         * lisp.h (BINDING_STACK_SIZE): New macro.
2275         * dired.c (directory_files_internal) [EAGAIN || EINTR]: Retry
2276         reading the directory if readdir returns null and errno is EAGAIN
2277         or EINTR.
2279 2000-11-14  Stefan Monnier  <monnier@cs.yale.edu>
2281         * xdisp.c (try_scrolling): Set scroll_max to max of scroll_* args
2282         so setting scroll-step to 1 doesn't defeat scroll-conservatively.
2283         Set amount_to_scroll to max of dx and scroll_step so that
2284         scroll-conservatively doesn't defeat scroll-step>1.
2285         (syms_of_xdisp): Add a hint in scroll-step's docstring to use
2286         scroll-conservatively for line-at-a-time scrolling.
2288 2000-11-14  Gerd Moellmann  <gerd@gnu.org>
2290         * window.c (Fpos_visible_in_window_p): Call pos_visible with
2291         extra argument.
2293         * xdisp.c (current_mode_line_height, current_header_line_height):
2294         New variables.
2295         (init_xdisp): Initialize them.
2296         (pos_visible_p): Add parameter EXACT_MODE_LINE_HEIGHTS_P.  Compute
2297         and use exact mode line heights if it is set.
2299         * lisp.h (pos_visible_p): Change prototype.
2301         * dispextern.h (CURRENT_MODE_LINE_HEIGHT)
2302         (CURRENT_HEADER_LINE_HEIGHT):  Look at current_mode_line_height
2303         and current_header_line_height first.
2304         (current_mode_line_height, current_header_line_height): Declare
2305         extern.
2307 2000-11-14  Miles Bader  <miles@lsi.nec.co.jp>
2309         * xterm.c (x_alloc_lighter_color): Use real brightness calculation.
2310         Just use FACTOR/2 instead of HIGHLIGHT_COLOR_DARK_BOOST.
2311         (HIGHLIGHT_COLOR_DARK_BOOST): Macro removed.
2313 2000-11-14  Miles Bader  <miles@gnu.org>
2315         * xterm.c (x_alloc_lighter_color): Include an additive component
2316         too for dark colors, because FACTOR isn't enough.
2317         (HIGHLIGHT_COLOR_DARK_BOOST, HIGHLIGHT_COLOR_DARK_BOOST_LIMIT):
2318         New macros.
2320 2000-11-13  Gerd Moellmann  <gerd@gnu.org>
2322         * keyboard.c (show_help_echo): Call message3_nolog with number of
2323         bytes in the help string as 2nd parameter, instead of the number
2324         of characters.
2326 2000-11-13  Miles Bader  <miles@gnu.org>
2328         * lread.c (openp): Return -2 instead of 0 for the `remote file' case.
2329         (Fload): Use new openp return protocol.
2330         Don't try to use Vload_source_file_function to load .elc files.
2331         * xfns.c (x_create_bitmap_from_file, x_find_image_file): Use new
2332         openp return protocol.
2333         * w32fns.c (x_create_bitmap_from_file, x_find_image_file): Likewise.
2335 2000-11-11  Kenichi Handa  <handa@etl.go.jp>
2337         * syssignal.h: Pay attention to BROKEN_SIGAIO and BROKEN_SIGPTY.
2339         * m/ibmrs6000.h (BROKEN_SIGAIO, BROKEN_SIGPTY, BROKEN_SIGPOLL):
2340         Defined these macros.
2341         (NLIST_STRUCT): Avoid re-defining it.
2343         * s/hpux10.h (C_SWITCH_X_SYSTEM): Include -I/usr/include/X11R6 and
2344         -I/usr/contrib/X11R6/include.
2345         (LD_SWITCH_X_DEFAULT): Include -L/usr/lib/X11R6.
2347 2000-11-10  Jason Rumney  <jasonr@gnu.org>
2349         * w32term.h (CP_8BIT, CP_UNICODE, CP_INVALID): New pseudo-codepages.
2351         * w32term.c (w32_encode_char): Handle CP_UNICODE specially.
2352         (w32_use_unicode_for_codepage): Use new pseudo-codepages.
2354         * w32fns.c (Qw32_charset_hangeul): Rename to match w32 headers.
2355         (Qw32_charset_vietnamese): New symbol.
2356         (xlfd_charset_of_font): New function.
2357         (w32_load_system_font): Use it.
2358         (x_to_w32_charset): Use Fassoc to find charset info. Special case
2359         when Vw32_charset_info_alist is nil to ensure default face always
2360         has font. Use Fcar and Fcdr for safety.
2361         (w32_to_x_charset): Use Vw32_charset_info_alist for mappings.
2362         (w32_codepage_for_font): Use xlfd_charset_of_font.  Use new
2363         pseudo-codepages for special cases.
2364         (w32_to_x_font): New parameter to allow charset portion to be
2365         specified where there is many to one mapping.  Callers changed.
2366         (w32_list_fonts): Avoid listing fonts that won't display.
2368 2000-11-10  Gerd Moellmann  <gerd@gnu.org>
2370         * xfaces.c (Vface_alternative_font_registry_alist): New variable.
2371         (font_list_1): Renamed from font_list.
2372         (font_list): New function, trying alternative registries from
2373         Vface_alternative_font_registry_alist.
2374         (Finternal_set_alternative_font_registry_alist): New function.
2375         (syms_of_xfaces): Initialize and Staticpro
2376         Vface_alternative_font_registry_alist.  Defsubr
2377         Finternal_set_alternative_font_registry_alist.
2379 2000-11-09  Ken Raeburn  <raeburn@gnu.org>
2381         * lisp.h (Flooking_at): Declare.
2383 2000-11-09  Gerd Moellmann  <gerd@gnu.org>
2385         * dired.c (directory_files_internal): Fix a braino.
2386         
2387         * dired.c (directory_files_internal): Add missing GCPRO's.
2388         Some cleanup.
2390 2000-11-08  Gerd Moellmann  <gerd@gnu.org>
2392         * xdisp.c (syms_of_xdisp): Change doc of max-mini-window-height.
2393         (resize_mini_window): Return quickly if Vresize_mini_window is
2394         nil.  Don't return if Vmax_mini_window_height is nil.
2396         * xdisp.c (Vresize_mini_window, Qgrow_only): New variables.
2397         (syms_of_xdisp): Initialize them.
2398         (resize_mini_window): Act according to the setting of
2399         Vresize_mini_window.
2400         (syms_of_xdisp): Initialize Vmenu_bar_update_hook to nil.
2402         * xterm.c (x_scroll_bar_create) [USE_TOOLKIT_SCROLL_BARS]: Map the
2403         scroll bar widget after configuring it, so that it will appear at
2404         the right position from the start.
2405         (XTredeem_scroll_bar): Cleaned up.
2407 2000-11-08  Kenichi Handa  <handa@etl.go.jp>
2409         * xterm.c (VCENTER_BASELINE_OFFSET): Fix previous change.  If the
2410         font is taller than the frame line, we don't have to bias the
2411         division by two.
2413         * w32term.c (VCENTER_BASELINE_OFFSET): Likewise.
2415 2000-11-07  Dave Love  <fx@gnu.org>
2417         * config.in (HAVE_MKSTEMP): Add.
2419         * callproc.c (Fcall_process_region) [HAVE_MKSTEMP]: Use it.
2421 2000-11-07  Gerd Moellmann  <gerd@gnu.org>
2423         * window.c (Fset_window_configuration): Don't try to preserve
2424         point in the current buffer, if that buffer is displayed in more
2425         than one window.
2427         * xfaces.c (lookup_named_face): If default face isn't realized,
2428         try to realize it.  Return -1 if not successful.
2429         (Fx_list_fonts): Handle case that face cannot be determined.
2430         (Fface_font): Likewise.
2432 2000-11-06  Gerd Moellmann  <gerd@gnu.org>
2434         * window.c (displayed_window_lines): Detect partially
2435         visible lines at the bottom correctly.
2437 2000-11-06  Stefan Monnier  <monnier@cs.yale.edu>
2439         * fileio.c (Fwrite_region): Use `visiting' rather than `visit'
2440         when ensuring we don't do visit in indirect buffer.
2442 2000-11-06  Kenichi Handa  <handa@etl.go.jp>
2444         * composite.h (compose_chars_in_text): Add prototype.
2446         * composite.c (Vcomposition_function_table): New variable.
2447         (Qcomposition_function_table): New variable.
2448         (run_composition_function): Call
2449         Vcompose_chars_after_function with three arguments.
2450         (compose_chars_in_text): New function.
2451         (syms_of_composite): Modified the doc-string of
2452         Vcompose_chars_after_function.  Declare composition-function-table
2453         as a lisp variable, and initialize it.
2455         * xfns.c (x_encode_text): Suppress producing escape sequences for
2456         composition.
2458         * xselect.c: Include composite.h.
2459         (selection_data_to_lisp_data): Call compose_chars_in_text on STR.
2461 2000-11-05  Andrew Innes  <andrewi@gnu.org>
2463         * w32term.c (x_produce_glyphs): Fix typo in enum name.
2465         * sysdep.c (read_input_waiting): Remove extraneous argument to
2466         read_socket_hook.
2468         * w32fns.c (Fx_server_version): Include w32_build_number in the
2469         return list.
2471         * w32heap.c (w32_build_number): New variable.
2472         (cache_system_info): Set it.
2474         * w32heap.h (w32_build_number): Add extern.
2476         * emacs.c (syms_of_emacs): Update docstring for
2477         system-configuration, to reflect the actual usage on MS-Windows.
2479 2000-10-31  Gerd Moellmann  <gerd@gnu.org>
2481         * keyboard.c (read_char) <wrong_kboard>: Make sure that we
2482         process idle timers while waiting for another event.
2484         * dispnew.c (update_frame_line): Handle case where spaces in 
2485         the default face are colored.
2487         * xdisp.c (redisplay_tool_bar): Don't set fonts_changed_p if
2488         window height hasn't changed.
2490 2000-10-31  Jason Rumney  <jasonr@gnu.org>
2492         * w32term.c (x_produce_glyphs): Handle composite characters.
2493         (x_draw_glyph_string_foreground)
2494         (x_draw_composite_glyph_string_foreground): Restore old font.
2496 2000-10-31  Miles Bader  <miles@lsi.nec.co.jp>
2498         * minibuf.c (read_minibuf): Reset the undo history just before
2499         starting the recursive-edit.
2501 2000-10-30  Gerd Moellmann  <gerd@gnu.org>
2503         * xfaces.c (menu_face_change_count): New variable.
2504         (Finternal_set_lisp_face_attribute): Increment it for changes
2505         of the `menu' face.
2506         (realize_basic_faces): Reflect changes in the `menu' faces
2507         in menu bars.
2509         * xdisp.c (try_scrolling) <PT >= scroll_margin_pos>: Add 1 to the
2510         dy obtained from the iterator's y-position after moving from
2511         scroll_margin_pos to PT; see comment there.
2512         
2513         * xdisp.c (safe_eval_handler): Call add_to_log.
2515         * xfaces.c (resolve_face_name): Handle case that FACE_NAME
2516         is not a symbol or string.
2518         * xdisp.c (echo_area_display): Don't perform a display update from
2519         inside redisplay.  The update will happen anyway at the end of
2520         redisplay, and it can confuse redisplay (GC messages while
2521         redisplaying, for instance.)
2523 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
2525         * xrdb.c (x_load_resources): Use the class name in the defaults.
2527         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
2528         (regex_compile): Catch bogus \(\1\).
2530 2000-10-30  Gerd Moellmann  <gerd@gnu.org>
2532         * xterm.c (x_alloc_nearest_color): Fix last change to compare
2533         RGB values.
2534         
2535         * xterm.c (x_alloc_nearest_color): If allocation succeeds, and
2536         we have a color cache, check that the cached color equals the
2537         allocated color.  If not, clear the color cache.
2539         * window.c (displayed_window_lines): Change buffers if necessary.
2540         Fix computation of displayed lines.
2542         * keyboard.c (syms_of_keyboard): Change DEFVAR_LISP of
2543         update_menu_bindings to DEFVAR_BOOL.
2545 2000-10-30  Kenichi Handa  <handa@etl.go.jp>
2547         * search.c (Fset_match_data): Be sure to make search_regs always sane.
2549         * puresize.h (BASE_PURESIZE): Increase to 680000.
2551         * fns.c (Foptimize_char_table): Fix arg for CHARSET_DIMENSION.
2553 2000-10-29  Jason Rumney  <jasonr@gnu.org>
2555         * w32term.h (FONT_DESCENT): Negate descent of BDF fonts.
2557         * w32term.c (w32_bdf_per_char_metric): Negate descent.
2558         (w32_cache_char_metrics): Handle possibility that 'x' does not
2559         exist in a BDF font.
2560         (W32_TEXTOUT): w32_BDF_TextOut wants number of bytes not chars.
2562         * w32bdf.h (bdffont): Add nchars.
2564         * w32bdf.c (set_bdf_font_info): Set it.
2565         (w32_BDF_TextOut): Swap byte order of double byte characters.
2566         (w32_load_bdf_font): Set double_byte_p based on bdf_font->nchars.
2568 2000-10-28  Eli Zaretskii  <eliz@is.elta.co.il>
2570         * frame.c (Fframe_parameters): Fix the change from 2000-10-16:
2571         don't override the colors in frame's param_alist, unless they are
2572         unspecified.
2574         * term.c (reassert_line_highlight): If inverse_video is non-zero,
2575         reverse the effect of the highlight flag.
2577 2000-10-27  Ken Raeburn  <raeburn@gnu.org>
2579         * window.h (Fwindow_live_p): Declare.
2581         * undo.c (record_delete): Check that last_undo_buffer is really a
2582         buffer before applying XBUFFER to it.
2584         * keymap.c (where_is_internal): Pass lisp object, not integer, to
2585         Faref.
2587 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
2589         * lisp.h (KEYMAPP): New macro.
2590         (get_keymap): Remove.
2591         (get_keymap_1): Rename get_keymap.
2593         * keyboard.h (get_keymap_1, Fkeymapp): Remove prototype.
2595         * xterm.c (note_mode_line_highlight): Use KEYMAPP.
2597         * xmenu.c (single_submenu): Use KEYMAPP.
2598         (Fx_popup_menu): Fetch keymaps rather than checking Fkeymapp.
2599         Use KEYMAPP rather than Fkeymapp.
2601         * w32term.c (note_mode_line_highlight): Use KEYMAPP.
2603         * w32menu.c (True, False): Remove (use TRUE and FALSE instead).
2604         (Fx_popup_menu): Fetch keymaps rather than checking Fkeymapp.
2605         Use KEYMAPP rather than Fkeymapp.
2606         (single_submenu): Use KEYMAPP.
2607         (w32_menu_show, w32_dialog_show): Use TRUE.
2609         * minibuf.c (Fread_from_minibuffer): Update call to get_keymap.
2611         * keymap.c (KEYMAPP): Remove (moved to lisp.h).
2612         (Fkeymapp): Use KEYMAPP.
2613         (get_keymap): Rename from get_keymap_1.  Remove old def.
2614         Return t when autoload=0 and error=0 and the keymap needs autoloading.
2615         (Fcopy_keymap): Check (eq (car x) 'keymap) rather than using Fkeymapp.
2616         (Fminor_mode_key_binding): Don't raise an error if the binding
2617         is not a keymap.
2618         (Fuse_global_map, Fuse_local_map): Allow autoloading.
2619         (Faccessible_keymaps): Fetch keymaps rather than checking Fkeymapp.
2621         * keyboard.c (read_char): get_keymap_1 -> get_keymap.
2622         Allow Vspecial_event_map to be autoloaded.
2623         (menu_bar_items): Fetch the keymap rather than using keymapp.
2624         (menu_bar_one_keymap): No need to follow func-indirect any more.
2625         (parse_menu_item): get_keymap_1 -> get_keymap.
2626         (tool_bar_items): Fetch the keymap rather than using keymapp.
2627         (read_key_sequence): Use KEYMAPP.
2629         * intervals.c (get_local_map): Use get_keymap rather than following
2630         function-indirections explicitly.
2632         * doc.c (Fsubstitute_command_keys): get_keymap_1 -> get_keymap.
2634 2000-10-27  Jason Rumney  <jasonr@gnu.org>
2636         * w32fns.c (Fx_create_frame): Make default fontsize on w32 10
2637         point, as Windows has oversized fonts.
2639         * fontset.c (syms_of_fontset) [WINDOWSNT]: Likewise.
2641 2000-10-27  Gerd Moellmann  <gerd@gnu.org>
2643         * gmalloc.c [GC_MCHECK]: Add code from mcheck.c of glibc-1.09.1.
2644         (freehook, reallochook): Handle null pointer arguments.
2645         (__malloc_initialize) [GC_MCHECK]: Call mcheck.
2647 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
2649         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
2650         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
2651         Giving in to popular pressure to shut up the compiler with casts.
2653 2000-10-27  Gerd Moellmann  <gerd@gnu.org>
2655         * xterm.c (x_draw_glyph_string): Treat XA_UNDERLINE_POSITION as a
2656         signed value, and use a default value computed from the font's
2657         maximum descent.
2659 2000-10-27  Miles Bader  <miles@lsi.nec.co.jp>
2661         * xterm.c (x_draw_glyph_string): Add a workaround so that fonts
2662         that specify a negative underline position can still use underlines.
2664         * window.c (Fpos_visible_in_window_p): Make POS default to
2665         WINDOW's point, not the current buffer's point.
2667 2000-10-26  Dave Love  <fx@gnu.org>
2669         * s/sol2-5.h: Don't define SYSTEM_MALLOC so that we can find out
2670         when it's necessary.
2672 2000-10-26  Gerd Moellmann  <gerd@gnu.org>
2674         * window.c (size_window): Compute size difference from sum of old
2675         child window sizes instead of from parent's size.
2677         * xdisp.c (pos_visible_p): Change current buffer if necessary.
2678         Handle obscured lines at the top of the window.
2680         * frame.c (Fdelete_frame): Doc fix.  Move running the hook
2681         down after the last error condition check.
2683         * frame.c (Fdelete_frame): Run delete-frame-hook.
2685 2000-10-26  Kenichi Handa  <handa@etl.go.jp>
2687         * coding.c (decode_coding): Fix previous change (check also
2688         CODING_MODE_LAST_BLOCK).
2690 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
2692         * regex.c: More `unsigned char' -> `re_char' changes.
2693         Also change several `int' into `re_wchar_t'.
2694         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
2695         (PUSH_FAILURE_POINTER): Don't cast any more.
2696         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
2697         We want GCC to complain, since this piece of code makes
2698         re_match non-reentrant, which *should* be fixed.
2699         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
2700         (EXTEND_BUFFER): Use RETALLOC.
2701         (SET_LIST_BIT): Don't cast.
2702         (re_wchar_t): New type.
2703         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
2704         that those two functions will always properly return.
2705         (IMMEDIATE_QUIT_CHECK): Cast to void.
2706         (analyse_first): Use recursion rather than an explicit stack.
2707         (re_compile_fastmap): Can't fail anymore.
2708         (re_search_2): Don't check re_compile_fastmap for failure.
2709         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
2710         Now also sets the new value (passed in a new argument).
2711         (re_match_2_internal): Use it.
2712         Also, use a new var `reg' of type size_t when looping through regs
2713         rather than reuse the inappropriate `mcnt'.
2715         * keymap.c (where_is_cache, where_is_cache_keymaps): New vars.
2716         (Fset_keymap_parent, store_in_keymap): Flush the where-is cache.
2717         (where_is_internal): Renamed from Fwhere_is_internal.
2718         Don't DEFUN any more. Arg `xkeymap' replaced by `keymaps'.
2719         (Fwhere_is_internal): New function wrapping where_is_internal.
2720         (where_is_internal_1): Handle the case where we're filling the cache.
2721         (syms_of_keymap): Init and gcpro the where_is_cache(|_keymaps).
2723 2000-10-25  Miles Bader  <miles@gnu.org>
2725         * xdisp.c (pos_visible_p): Don't add `it.current_y' twice.
2727 2000-10-25  Gerd Moellmann  <gerd@gnu.org>
2729         * window.c (pos_fully_visible_p): Removed.
2730         (Fpos_visible_in_window_p): Use pos_visible_p to determine
2731         if position is visible and/or fully visible.
2733         * lisp.h (pos_visible_p): Add prototype.
2735         * xdisp.c (pos_visible_p): New function.
2737 2000-10-25  Kenichi Handa  <handa@etl.go.jp>
2739         * process.c (send_process): If OBJECT is t, it means that the data
2740         is from C string, but we should encode it.  Before calling
2741         setup_raw_text_coding_system, be sure to flush out data by the
2742         previous coding system.
2744 2000-10-25  Miles Bader  <miles@lsi.nec.co.jp>
2746         * buffer.c (overlays_at): Only let CHANGE_REQ inhibit an
2747         assignment of startpos to prev when startpos == pos.
2749         * editfns.c (find_field): Set the field stickiness correctly from
2750         overlay fields.  Use renamed `text_property_stickiness'.
2751         (text_property_stickiness): Renamed from `char_property_stickiness'.
2752         Only check text properties, not overlays.
2753         * textprop.c (get_char_property_and_overlay): New function.
2754         (Fget_char_property): Use it.
2755         * intervals.h (get_char_property_and_overlay): Add declaration.
2757 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
2759         * keymap.c: Use AREF, ASET and ASIZE macros.
2760         (Fmake_sparse_keymap): Docstring fix.
2761         (synkey): Remove.
2762         (shadow_lookup): Move up.
2763         Handle the case where lookup-key returns an integer.
2764         (where_is_internal_1): Drop arg `keymap'. Don't check shadowing.
2765         (where_is_internal_2): Adapt to fewer args for where_is_internal_1.
2766         (Fwhere_is_internal): Allow `xkeymap' to be a list of keymaps.
2767         Simplify/rewrite the keymap-finding code.
2768         Add check for command shadowing, using shadow_lookup.
2770 2000-10-24  Stefan Monnier  <monnier@cs.yale.edu>
2772         * keymap.c (fix_submap_inheritance): Use get_keymap_1 on parent_entry
2773         rather than KEYMAPP, to allow EQ to work correctly if parent_entry is
2774         a symbol.
2776 2000-10-24  Andrew Innes  <andrewi@gnu.org>
2778         * dired.c (directory_files_internal_unwind): New function.
2779         (directory_files_internal): Use it to ensure closedir is called
2780         even if expand-file-name or file-attributes throw, eg. because of
2781         a user interrupt.  Also enable immediate_quit while calling
2782         re_search, so that matching can be interrupted as well.
2784 2000-10-24  Andrew Innes  <andrewi@gnu.org>
2786         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
2787         NT-Emacs only.
2788         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
2789         so that re_search functions only quit when callers expect them to.
2791 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
2793         * regex.c (regex_compile): Change the way of handling a range from
2794         a char less than 256 to a char not less than 256.
2796 2000-10-24  Gerd Moellmann  <gerd@gnu.org>
2798         * window.c (size_window): Prevent setting window's width or
2799         height to a negative value (esp. with XSETFASTINT).
2801         * gmalloc.c (state_protected_p, last_state_size, last_heapinfo)
2802         [GC_MALLOC_CHECK && GC_PROTECT_MALLOC_STATE]: New variables.
2803         (protect_malloc_state) [GC_MALLOC_CHECK &&
2804         GC_PROTECT_MALLOC_STATE]: New function.
2805         (PROTECT_MALLOC_STATE): New macro.
2806         (__malloc_initialize, morecore, _malloc_internal)
2807         (_free_internal) _realloc_internal): Use it to make _heapinfo
2808         read-only outside of gmalloc.
2810         * keymap.c: Update copyright.
2812         * .gdbinit (xbacktrace): Handle case that $bt->function isn't
2813         a symbol.
2815 2000-10-24  Colin Walters  <walters@cis.ohio-state.edu>
2817         * filelock.c (unlock_all_files): Use unlock_file to expand each
2818         buffer's file_truename before trying remove its lock file.
2820 2000-10-24  Eli Zaretskii  <eliz@is.elta.co.il>
2822         * coding.c (decode_coding_emacs_mule): If coding->eol_type is CR
2823         or CRLF, decode EOLs.
2825 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
2827         * window.c (Fdisplay_buffer): Fix doc.
2829 2000-10-23  Jason Rumney  <jasonr@gnu.org>
2831         * fontset.c (syms_of_fontset) [WINDOWSNT]: Special case for
2832         ASCII font of default fontset on Windows.
2834         * w32term.c (VCENTER_BASELINE_OFFSET): Bias division (see
2835         xterm.c comment below).
2837         * w32fns.c (x_to_w32_font): Initialize dpi from dpyinfo->resy.
2839 2000-10-23  Gerd Moellmann  <gerd@gnu.org>
2841         * xterm.c (x_connection_closed): Reset handling_signal.
2843         * alloc.c (emacs_blocked_free) [GC_MALLOC_CHECK]: Handle freeing
2844         null.
2846 2000-10-23  Miles Bader  <miles@gnu.org>
2848         * window.c (window_scroll_pixel_based, window_scroll_line_based):
2849         Pass nil for FULLY argument to Fpos_visible_in_window_p to
2850         maintain old behavior.
2851         * minibuf.c (Fminibuffer_complete): Likewise.
2853 2000-10-23  Miles Bader  <miles@lsi.nec.co.jp>
2855         * xterm.c (VCENTER_BASELINE_OFFSET): Bias the division by two, so
2856         that when a font can't be exactly centered, it errs up rather than
2857         down.
2859 2000-10-23  ShengHuo ZHU  <zsh@cs.rochester.edu>
2861         * fns.c (Fbase64_decode_string): The decoded result should be
2862         unibyte.
2864 2000-10-23  Andrew Choi  <akochoi@i-cable.com>
2866         * dispextern.h [macintosh]: Include macgui.h instead of macterm.h.
2868         * dispnew.c [macintosh]: Include macterm.h.
2869         (init_display) [macintosh]: Initialization for window system.
2871         * emacs.c (main) [macintosh]: Call syms_of_textprop,
2872         syms_of_macfns, syms_of_ccl, syms_of_fontset, syms_of_xterm,
2873         syms_of_search, x_term_init, and init_keyboard before calling
2874         init_window_once.  Also, call syms_of_xmenu.
2876         * fontset.c (syms_of_fontset) [macintosh]: Set ASCII font of
2877         default fontset to Monaco.
2879         * frame.c [macintosh]: Include macterm.h.  Remove declarations of
2880         NewMacWindow and DisposeMacWindow.
2881         (make_terminal_frame) [macintosh]: Call make_mac_terminal_frame
2882         instead of calling NewMacWindow and setting fields of
2883         f->output_data.mac directly.  Call init_frame_faces.
2884         (Fdelete_frame) [macintosh]: Remove unused code.
2885         (Fmodify_frame_parameters) [macintosh]: Call
2886         x_set_frame_parameters instead of mac_set_frame_parameters.
2888         * frame.h [macintosh]: Define menu_bar_lines field in struct
2889         frame.  Define FRAME_EXTERNAL_MENU_BAR macro.
2891         * keyboard.c [macintosh]: Include macterm.h.
2892         (kbd_buffer_get_event) [macintosh]: Generate delete_window_event
2893         and menu_bar_activate_event type events as for X and NT.
2894         (make_lispy_event) [macintosh]: Construct lisp events of type
2895         MENU_BAR_EVENT as for X and NT.
2897         * sysdep.c [macintosh]: Remove declaration for sys_signal.
2898         Include stdlib.h.  Remove definition of Vx_bitmap_file_path.
2899         (sys_subshell) [macintosh]: Remove definition entirely.
2900         (init_sys_modes) [macintosh]: Do not initialize Vwindow_system and
2901         Vwindow_system_version here.  Remove initialization of
2902         Vx_bitmap_file_path.
2903         (read_input_waiting): Correct the number of parameters passed to
2904         read_socket_hook.
2905         Move all Macintosh functions to mac/mac.c.
2907         * term.c [macintosh]: Include macterm.h.
2909         * window.c [macintosh]: Include macterm.h.
2911         * xdisp.c [macintosh]: Include macterm.h.  Declare
2912         set_frame_menubar and pending_menu_activation.
2913         (echo_area_display) [macintosh]: Do not return if terminal frame
2914         is the selected frame.
2915         (update_menu_bar) [macintosh]: Check FRAME_EXTERNAL_MENU_BAR (f).
2916         Allow only the selected frame to set menu bar.
2917         (redisplay_window) [macintosh]: Obtain menu bar to redisplay by
2918         calling FRAME_EXTERNAL_MENU_BAR (f).
2919         (display_menu_bar) [macintosh]: Check FRAME_MAC_P (f).
2921         * xfaces.c [macintosh]: Include macterm.h.  Define x_display_info
2922         and check_x.  Declare XCreateGC.  Define x_create_gc and
2923         x_free_gc.  Initialize font_sort_order.
2924         (x_face_list_fonts) [macintosh]: Use the same code as WINDOWSNT,
2925         but call x_list_fonts instead of w32_list_fonts.
2926         (Finternal_face_x_get_resource) [macintosh]: Do not call
2927         display_x_get_resource.
2928         (prepare_face_for_display) [macintosh]: Set xgcv.font.
2929         (realize_x_face) [macintosh]: Load the font if it is specified in
2930         ATTRS.
2931         (syms_of_xfaces) [macintosh]: Initialize Vscalable_fonts_allowed
2932         to Qt.
2934 2000-10-22  Stefan Monnier  <monnier@cs.yale.edu>
2936         * keymap.c (fix_submap_inheritance): Don't do anything if parent_entry
2937         is nil: since we go to the end of submap anyway, we'd end up
2938         setting nil to nil.
2939         (access_keymap): Don't use KEYMAPP on meta_map since KEYMAPP
2940         doesn't obey autoload.
2942 2000-10-21  Eli Zaretskii  <eliz@is.elta.co.il>
2944         * msdos.c (dos_set_window_size): Update screen dimension variables.
2946 2000-10-21  Jason Rumney  <jasonr@gnu.org>
2948         * w32term.c (w32_cache_char_metrics): Double check that font is
2949         really fixed pitch before trusting tmPitchAndFamily.
2951 2000-10-21  Andrew Innes  <andrewi@gnu.org>
2953         * w32gui.h (w32_char_font_type): Move enum from w32term.c
2955         * w32term.h: Extern decl for w32_cache_char_metrics.
2957         * w32bdf.c (w32_load_bdf_font): Call w32_cache_char_metrics.
2959         * w32fns.c (w32_load_system_font): Call w32_cache_char_metrics.
2960         (w32_unload_font): Free per_char array if present.
2962         * w32term.c (w32_per_char_metric): Remove HDC argument.  Use
2963         cached information in emulated XFontStruct to handle common cases
2964         quickly.  Do not allocate XCharStruct for return.
2965         (w32_native_per_char_metric): New function.
2966         (w32_bdf_per_char_metric): Fill in supplied XCharStruct instead of
2967         allocating one.
2968         (x_produce_glyphs): Don't get an HDC.  Change calls to
2969         w32_per_char_metric to match arg change above.  Remove calls to
2970         free results.
2971         (w32_get_glyph_overhangs): Ditto.
2972         (w32_cache_char_metrics): New function.
2974         * makefile.w32-in: Change .obj to .$(O) in all dependencies.
2975         ($(BLD)/casefiddle.$(O)): Remove compile command.
2976         ($(BLD)/gmalloc.$(O)): Remove compile command.
2977         ($(BLD)/dispnew.obj): 
2978         ($(BLD)/keyboard.obj): 
2979         ($(BLD)/w32inevt.obj): 
2980         ($(BLD)/w32bdf.obj): 
2981         ($(BLD)/alloc.obj): 
2982         ($(BLD)/buffer.obj): 
2983         ($(BLD)/editfns.obj): 
2984         ($(BLD)/emacs.obj): 
2985         ($(BLD)/fileio.obj): 
2986         ($(BLD)/fns.obj): 
2987         ($(BLD)/indent.obj): 
2988         ($(BLD)/insdel.obj): 
2989         ($(BLD)/intervals.obj): 
2990         ($(BLD)/minibuf.obj): 
2991         ($(BLD)/print.obj): 
2992         ($(BLD)/scroll.obj): 
2993         ($(BLD)/sysdep.obj): 
2994         ($(BLD)/textprop.obj): 
2995         ($(BLD)/widget.obj): 
2996         ($(BLD)/xdisp.obj): Add dependency on w32gui.h.
2997         ($(BLD)/term.obj): Add dependency on dispextern.h.
2999         * makefile.nt ($(BLD)\dispnew.obj): 
3000         ($(BLD)\keyboard.obj): 
3001         ($(BLD)\w32inevt.obj): 
3002         ($(BLD)\w32bdf.obj): 
3003         ($(BLD)\alloc.obj): 
3004         ($(BLD)\buffer.obj): 
3005         ($(BLD)\editfns.obj): 
3006         ($(BLD)\emacs.obj): 
3007         ($(BLD)\fileio.obj): 
3008         ($(BLD)\fns.obj): 
3009         ($(BLD)\indent.obj): 
3010         ($(BLD)\insdel.obj): 
3011         ($(BLD)\intervals.obj): 
3012         ($(BLD)\minibuf.obj): 
3013         ($(BLD)\print.obj): 
3014         ($(BLD)\scroll.obj): 
3015         ($(BLD)\sysdep.obj): 
3016         ($(BLD)\textprop.obj): 
3017         ($(BLD)\widget.obj): 
3018         ($(BLD)\xdisp.obj): Add dependency on w32gui.h.
3019         ($(BLD)\term.obj): Add dependency on dispextern.h
3021 2000-10-21  Eli Zaretskii  <eliz@is.elta.co.il>
3023         * minibuf.c (Fminibuffer_complete): Call Fpos_visible_in_window_p
3024         with an additional argument of Qt.
3026 2000-10-21  Miles Bader  <miles@gnu.org>
3028         * window.c (pos_fully_visible_in_window_p): New function.
3029         (Fpos_visible_in_window_p): Add FULLY argument.
3030         Use pos_fully_visible_in_window_p.
3031         (window_scroll_pixel_based, window_scroll_line_based): Update
3032         calls to Fpos_visible_in_window_p.
3033         * lisp.h (Fpos_visible_in_window_p): Update prototype
3035 2000-10-20  Gerd Moellmann  <gerd@gnu.org>
3037         * alloc.c (toplevel): Conditionalize compilation of mem_*
3038         functions differently.
3039         
3040 2000-10-20  Jason Rumney  <jasonr@gnu.org>
3042         * alloc.c (toplevel): Move #ifdef GC_MARK_STACK back to above
3043         mem_init where it used to be. mem_z etc not defined otherwise.
3045 2000-10-20  Gerd Moellmann  <gerd@gnu.org>
3047         * alloc.c (toplevel) [SYSTEM_MALLOC || DOUG_LEA_MALLOC]: Undef
3048         GC_MALLOC_CHECK.
3049         (toplevel) [GC_MARK_STACK || GC_MALLOC_CHECK]: Move mem_node
3050         structure definition and related variabled to the top of the file.
3051         Include this code when GC_MALLOC_CHECK is defined.
3052         (lisp_malloc, lisp_free) [GC_MALLOC_CHECK]: Don't
3053         register/unregister allocated region.
3054         (emacs_blocked_free) [GC_MALLOC_CHECK]: Check if freeing something
3055         which isn't allocated.
3056         (emacs_blocked_malloc) [GC_MALLOC_CHECK]: Check if returning
3057         something which is already in use.
3058         (emacs_blocked_realloc) [GC_MALLOC_CHECK]: Likewise.
3059         (mem_insert) [GC_MALLOC_CHECK]: Use _malloc_internal.
3060         (mem_delete) [GC_MALLOC_CHECK]: Use _free_internal.
3061         (init_alloc_once) [GC_MALLOC_CHECK]: Call mem_init.
3063         * gmalloc.c (_malloc_internal) [GC_MALLOC_CHECK]: Use
3064         _malloc_internal instead of malloc.
3065         (_free_internal) [GC_MALLOC_CHECK]: Use _free_internal instead
3066         of free.
3068 2000-10-20  Andrew Innes  <andrewi@gnu.org>
3070         * strftime.c [!WINDOWSNT]: Don't apply Solaris 2.5 work-around on
3071         Windows.
3072         (my_strftime) <macro>: Don't use macro arg list when redefining as
3073         _strftime_copytm.
3074         (my_strftime) <function>: Supply 0 as ut argument.
3076 2000-10-19  Jason Rumney  <jasonr@altavista.net>
3078         * w32console.c: Do not undef HAVE_WINDOW_SYSTEM before
3079         including dispextern.h, as it stops faces from working.
3081         * w32fns.c (Fx_create_frame): Don't bother calling
3082         face-set-after-frame-default since the caller does it for us
3083         anyway. Clean up calls to x_get_arg to be consistent with X.
3085         * w32term.c (x_produce_glyphs): Handle
3086         unibyte_display_via_language_environment correctly.
3087         (w32_draw_box_rect): Fix the calculation of width and height.
3089         * w32menu.c (add_menu_item): Do not use MF_OWNERDRAW for titles,
3090         as it has stopped working.
3091         (Fx_popup_menu, Fx_popup_dialog): Check for tool-bar position like
3092         menu-bar.
3094 2000-10-19  Gerd Moellmann  <gerd@gnu.org>
3096         * eval.c (skip_debugger): Prevent a compiler warning.
3097         (Fcondition_case): Likewise.
3098         (Fbacktrace_frame): Use a null interactive spec.
3100 2000-10-19  Kenichi Handa  <handa@etl.go.jp>
3102         * xterm.c (x_find_ccl_program): Check also fontp->full_name.
3104 2000-10-18  Gerd Moellmann  <gerd@gnu.org>
3106         * strftime.c: Sync with glibc, file version 1.78.
3107         (my_strftime) [HAVE_TZNAME]: Use `UTC' instead of `GMT' which
3108         should no longer be used according to ISO 8601.
3110         * keymap.c (access_keymap): If IDX has a meta prefix, and there's
3111         no map for meta_prefix_char, don't try to use it as a keymap.
3112         Instead, if T_OK is non-zero, look up a default binding, if any,
3113         otherwise, if T_OK is zero, return nil.
3115         * xfns.c (x_to_xcolors, x_set_mouse_color, lookup_pixel_color)
3116         (x_to_xcolors, png_load): Use x_query_color.
3118         * xterm.c (x_color_cells, x_query_colors, x_query_color): New
3119         functions.
3120         (x_alloc_nearest_color): Use it to reduce calls to XQueryColors
3121         which can be slow.
3122         (x_copy_color, x_alloc_lighter_color): Likewise.
3124         * xterm.h (struct x_display_info): Add color_cells and ncolor_cells.
3125         (x_query_color, x_query_colors): Add prototype.
3127         * alloc.c (allocate_string) [GC_CHECK_STRING_BYTES]: Call
3128         check_string_bytes only if not noninteractive, increase count to 50.
3130 2000-10-18  Miles Bader  <miles@lsi.nec.co.jp>
3132         * insdel.c (adjust_markers_for_delete): Handle before-insertion
3133         markers correctly.
3135 2000-10-17  Gerd Moellmann  <gerd@gnu.org>
3137         * alloc.c (pure_bytes_used): Renamed from pureptr.
3138         (ALIGN): New macro.
3139         (pure_alloc): New function.
3140         (make_pure_string, pure_cons, make_pure_float, make_pure_vector):
3141         Use it.
3142         (Fpurecopy): Use PURE_POINTER_P.
3144         * xdisp.c (try_cursor_movement): Use cursor_row_p also when
3145         PT has moved backward.
3146         
3147         * xdisp.c (cursor_row_p): Take continued lines into account.
3149         * alloc.c (mark_object) [GC_CHECK_STRING_BYTES]: Check validity of
3150         string's size_byte.
3151         (check_string_bytes) [GC_CHECK_STRING_BYTES]: New function.
3152         (check_string_bytes_count) [GC_CHECK_STRING_BYTES]: New variable.
3153         (allocate_string) [GC_CHECK_STRING_BYTES]: Call it for every 10th
3154         string allocated.
3156         * xdisp.c (forward_to_next_line_start): Switch iterator's handling
3157         of selective display off while searching for the next line start.
3159 2000-10-17  Kenichi Handa  <handa@etl.go.jp>
3161         * Makefile.in (term.o): Depend on dispextern.h.
3163 2000-10-16  Stefan Monnier  <monnier@cs.yale.edu>
3165         * keymap.c (keymap_memberp): Ensure that nil is not a member.
3167 2000-10-16  Gerd Moellmann  <gerd@gnu.org>
3169         * xdisp.c (set_iterator_to_next): Reset box start and end flags of
3170         the iterator at the beginning, so that they can be set later on,
3171         for instance in reseat_at_next_visible_line_start, without being
3172         overwritten.
3174         * xfns.c (pbm_format): Add :foreground and :background keywords.
3175         (PBM_FOREGROUND, PBM_BACKGROUND): New enumerators.
3176         (xbm_load): Recognize foreground and background color
3177         specifications.
3179 2000-10-16  Eli Zaretskii  <eliz@is.elta.co.il>
3181         * dispextern.h (unspecified_fg, unspecified_bg): Declare.
3183         * dosfns.c (unspecified_fg, unspecified_bg): Remove extern
3184         declaration.
3186         * msdos.c (IT_set_face): Compare highlighted face with the default
3187         face, and invert colors if these faces' colors are identical.
3188         (Fmsdos_remember_default_colors): Don't swap foreground and
3189         background colors in initial_colors[].
3190         (IT_set_frame_parameters): Don't swap frame's foreground and
3191         background pixels.  If ALIST includes "(reverse . t)", swap
3192         foreground-color and background-color properties in frame's
3193         param_alist.  If the original frame's param_alist doesn't specify
3194         the colors, store unspecified-fg and unspecified-bg, reversed if
3195         required.
3197         * frame.c (Fframe_parameters): If a tty's frame's param_alist says
3198         the colors are unspecified and reversed, reverse fore- and back-
3199         ground in the returned value.
3200         (Fframe_parameter): Ditto.
3202 2000-10-16  Gerd Moellmann  <gerd@gnu.org>
3203         
3204         * xdisp.c (find_last_unchanged_at_beg_row): Renamed from
3205         get_last_unchanged_at_beg_row.
3206         (find_first_unchanged_at_end_row): Renamed from
3207         get_first_unchanged_at_end_row.
3208         (find_first_unchanged_at_end_row): Convert assertions to
3209         unconditional tests which abort.  When looking for a row in
3210         unchanged text, don't go further back than first_text_row.
3212         * xdisp.c (try_scrolling) <cursor in scroll margin at the bottom>:
3213         Don't add in the last line's height when deciding if the new
3214         position is below the scroll margin.
3216 2000-10-16  Miles Bader  <miles@gnu.org>
3218         * editfns.c (Fconstrain_to_field): Check carefully for field
3219         boundaries if either OLD_POS or NEW_POS has a non-nil field
3220         property, even if they're the same.
3222 2000-10-16  Kenichi Handa  <handa@etl.go.jp>
3224         * xterm.c (x_draw_box_rect): Fix the calculation of width and
3225         height for XFillRectangle.
3227 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
3229         * syntax.c (Fstring_to_syntax): New function extracted from
3230         Fmodify_syntax_entry.
3231         (Fmodify_syntax_entry): Use it and document the ! and | fences.
3232         (skip_chars, Fforward_comment): Remove unused variables.
3233         (syms_of_syntax): Add defsubr for string-to-syntax.
3234         (describe_syntax): Add code for comment and string fences.
3236 2000-10-14  Stefan Monnier  <monnier@cs.yale.edu>
3238         * keymap.c (access_keymap): Add AUTOLOAD parameter.
3239         Do the meta->esc mapping.  Call get_keyelt before returning.
3240         Start scanning from the second element (the first is always `keymap')
3241         to make it easier to detect when we reach a parent map.
3242         Handle the case of inheriting from a symbol whose function is a map.
3243         (Fkeymap_parent): Also handle the `inherit from symbol' case.
3244         (fix_submap_inheritance, Fdefine_key): Update call to access_keymap.
3245         (get_keyelt, Flookup_key): Update call to access_keymap.
3246         Remove the meta->esc mappings.
3247         (define_as_prefix): Delete old disabled code.
3248         (menu_item_p): New function.
3249         (where_is_internal_1): Skip over the few remaining menu items.
3250         * lisp.h (access_keymap): Update prototype.
3251         * keyboard.c (read_char, menu_bar_items, tool_bar_items):
3252         Update call to access_keymap.
3253         (follow_key, read_key_sequence): Update calls to access_keymap.
3254         Remove the meta->esc mappings.
3256 2000-10-13  Gerd Moellmann  <gerd@gnu.org>
3258         * dispnew.c (direct_output_for_insert): Call set_iterator_to_next
3259         with additional argument.
3261         * xdisp.c (cursor_row_p): New function.
3262         (try_cursor_movement, display_line): Use it.
3263         
3264         * xdisp.c (append_space): Also save/restore iterator's current
3265         character and its length.
3267         * xdisp.c (init_from_display_pos): Add an assertion.
3268         (handle_stop): Don't set iterator's add_overlay_start.
3269         (handle_invisible_prop): Likewise.
3270         (load_overlay_strings): If text under an overlay is invisible,
3271         take both before- and after-strings into account when the iterator
3272         is positioned either at the start or at the end of the overlay.
3273         (forward_to_next_line_start): Rewritten.
3274         (reseat_at_next_visible_line_start): Rewritten.
3275         (set_iterator_to_next): Add parameter RESEAT_P.
3277         * dispextern.h (struct it): Remove member add_overlay_start.
3278         (set_iterator_to_next): Change prototype.
3280 2000-10-13  Kenichi Handa  <handa@etl.go.jp>
3282         * coding.c (code_convert_region): Be sure to initialize
3283         coding->category_idx.
3284         (decode_coding_string): Set coding->src_multibyte and
3285         coding->dst_multibyte before using CODING_REQUIRE_DECODING.
3286         (encode_coding_string): Set coding->src_multibyte and
3287         coding->dst_multibyte before using CODING_REQUIRE_ENCODING.
3289 2000-10-12  Stefan Monnier  <monnier@cs.yale.edu>
3291         * xfns.c (Fx_create_frame): Don't bother calling
3292         face-set-after-frame-default since the caller does it for us anyway.
3294 2000-10-12  Eli Zaretskii  <eliz@is.elta.co.il>
3296         * window.c (coordinates_in_window): Fix detection of vertical line
3297         on character terminals.
3299 2000-10-12  Gerd Moellmann  <gerd@gnu.org>
3301         * editfns.c (save_excursion_save): Additionally record the
3302         selected window.
3303         (save_excursion_restore): If buffer was visible in a window, and a
3304         different window was selected, and the old selected window is
3305         still live, restore point in that window.
3307 2000-10-12  Kenichi Handa  <handa@etl.go.jp>
3309         * xterm.c (x_produce_glyphs): Handle
3310         unibyte_display_via_language_environment correctly.
3312         * regex.c (regex_compile): Change the way of handling a range from
3313         unibyte char to multibyte char.
3315         * syntax.c (skip_chars): Change the way of handling a range from
3316         unibyte char to multibyte char.
3318         * process.c (read_process_output): Cancel previous change.
3320 2000-10-11  Eli Zaretskii  <eliz@is.elta.co.il>
3322         * search.c (Fsearch_backward, Fsearch_forward): Doc fix.
3324         * charset.c (Ffind_charset_string): Doc fix.
3325         (Ffind_charset_region): Doc fix.
3327 2000-10-11  Kenichi Handa  <handa@mule.m17n.org>
3329         * process.c (read_process_output): Fix previous change.  Adjust
3330         multibyteness of text to insert in a buffer by
3331         string_make_unibyte/multibyte instead of
3332         Fstring_as_unibyte/multibyte.
3334 2000-10-10  Andreas Schwab  <schwab@suse.de>
3336         * alloc.c (mark_object): Remove all workarounds installed on
3337         1993-08-08.
3339 2000-10-10  Kenichi Handa  <handa@etl.go.jp>
3341         * fns.c (READ_QUADRUPLET_BYTE): Set *NCHARS_RETURN before
3342         returning.
3343         (base64_encode_1): Make it work for a text of multibyte form.
3344         (Fbase64_decode_region): Allocate sufficient memory for multibyte
3345         case.  Don't call str_to_multibyte because base64_decode_1
3346         produces correct multibyte form for eight-bit codes.
3347         (Fbase64_decode_string): Adjusted for the change of
3348         base64_decode_1.
3349         (base64_decode_1): New args MULTIBYTE and NCHARS_RETURN.  If
3350         MULTIBYTE is nonzero, produce correct multibyte form for eight-bit
3351         codes.
3353         * charset.h (CHAR_STRING): Optimized for single byte characters.
3355 2000-10-09  Andreas Schwab  <schwab@suse.de>
3357         * process.c (Fopen_network_stream) [HAVE_GETADDRINFO]: Reset S to
3358         -1 after socket is closed, to fall through to error processing.
3360 2000-10-09  Eli Zaretskii  <eliz@is.elta.co.il>
3362         * msdos.c (IT_set_frame_parameters): Don't initialize Lisp_Object
3363         variables.  If ALIST includes foreground-color or
3364         background-color, change also the colors of the default face for
3365         this frame.
3367 2000-10-08  Eli Zaretskii  <eliz@is.elta.co.il>
3369         * msdos.c (top-level) <Qbackground_color, Qforeground_color>: Make
3370         them extern (they are defined on xfaces.c).
3371         (syms_of_msdos): Don't intern and don't staticpro
3372         Qbackground_color and Qforeground_color.
3374 2000-10-07  Eli Zaretskii  <eliz@is.elta.co.il>
3376         * frame.c (Fframe_parameter): For non-windowed frames, if
3377         f->param_alist says foreground or background color is unspecified,
3378         call tty_color_name to return the color name computed from the
3379         frame's current colors.
3381 2000-10-06  Dave Love  <fx@gnu.org>
3383         * terminfo.c (ospeed): Don't declare.
3385         * sysdep.c: Don't include string.h.
3386         (h_errno): Declare conditional also on TRY_AGAIN.
3388         * charset.c (Ffind_charset_string): Doc fix.
3390         * fns.c (Fbase64_encode_region, Fbase64_encode_string) 
3391         (Fbase64_decode_region, Fbase64_decode_string): More explicit
3392         error messages.
3394 2000-10-05  Dave Love  <fx@gnu.org>
3396         * xmenu.c (Fx_popup_menu, Fx_popup_dialog): Check for tool-bar
3397         position like menu-bar.
3399 2000-10-05  Gerd Moellmann  <gerd@gnu.org>
3401         * keyboard.c (Frecursive_edit): Make sure redisplay can happen.
3403         * xdisp.c (handle_single_display_prop): Use safe_call1.
3404         (safe_call): Renamed from call_function.
3405         (safe_call1): New function.
3406         (handle_fontified_prop): Use safe_call1 instead of call1.
3407         (safe_eval): Renamed from eval_form.
3408         (safe_eval_handler): Renamed from eval_handler.
3409         (handle_single_display_prop, display_mode_element): Use safe_eval
3410         instead of eval_form.
3412         * xfaces.c (merge_face_heights): Use safe_call instead of
3413         call_function.
3415         * keyboard.c (show_help_echo): Use safe_call instead of
3416         call_function; use safe_eval instead of eval_form.
3418         * lisp.h (safe_call): Renamed from call_function.
3419         (safe_eval): Renamed from eval_form.
3420         (safe_call1): Add prototype.
3422 2000-10-05  Miles Bader  <miles@lsi.nec.co.jp>
3424         * xfns.c (image_ascent): Rearrange ascent calculation for the
3425         has-a-font case.
3427 2000-10-04  Stefan Monnier  <monnier@cs.yale.edu>
3429         * keymap.c (Fwhere_is_internal): Ignore `menu-bar' and `tool-bar'.
3430         (where_is_internal_1): Don't bother ignoring menu-items any more.
3432 2000-10-04  Gerd Moellmann  <gerd@gnu.org>
3434         * keyboard.c (update_menu_bindings): New variable.
3435         (parse_menu_item): Use AREF.  If update_menu_bindings
3436         is 0, don't update menu bindings.
3437         (syms_of_keyboard): New Lisp variable `update-menu-bindings'.
3439 2000-10-03  Eli Zaretskii  <eliz@is.elta.co.il>
3441         * alloc.c (Fgarbage_collect): Prevent compiler warning for a call
3442         to `mark_object'.
3444 2000-10-02  Stefan Monnier  <monnier@cs.yale.edu>
3446         * syntax.c (forw_comment): Match nestedness of ender/starter.
3447         (Fforward_comment): Treat an unmatched \n comment-ender as whitespace.
3448         (prev_char_comstart_first): Remove.
3449         (back_comment): Check two-char comment markers more carefully
3450         to better handle overlapping cases like *//* or /* */* */ ...
3451         Match nestedness of ender/starter.
3453 2000-10-02  Dave Love  <fx@gnu.org>
3455         * config.in (HAVE_GAI_STRERROR): Add undef.
3457         * process.c (Fopen_network_stream): Use it.
3459         * m/alpha.h (NO_REMAP): Don't define.
3461 2000-10-02  Gerd Moellmann  <gerd@gnu.org>
3463         * lisp.h (wrong_type_argument): Remove NO_RETURN, the function can
3464         return with a string converted to an integer or vice versa when
3465         Vmocklisp_arguments is t.
3466         (Fsignal): Likewise.  The function can return for `quit'.
3467         (struct gcpro): Declare member `var' to point to a volatile
3468         Lisp_Object.
3470         * eval.c (error): Prevent compiler warning.
3472 2000-09-30  Stefan Monnier  <monnier@cs.yale.edu>
3474         * keymap.c (keymap_memberp): New function.
3475         (Fset_keymap_parent): Use it.
3476         (fix_submap_inheritance): Use get_keyelt, get_keymap_1 and KEYMAPP.
3477         Use keymap_memberp to avoid creating cycles.
3478         (access_keymap): Use KEYMAPP.
3480 2000-09-30  Gerd Moellmann  <gerd@gnu.org>
3482         * process.c (Fopen_network_stream) [HAVE_GETADDRINFO]: Use
3483         gai_strerror.  Make sure xerrno is set if connect fails.  Improve
3484         error recovery.
3486 2000-09-29  Jason Rumney <jasonr@gnu.org>
3488         * w32term.c (w32_char_font_type, w32_encode_char)
3489         (x_produce_glyphs): Distinguish single and multibyte BDF fonts.
3490         (w32_bdf_per_char_metric): New function.
3491         (w32_per_char_metric): Use it.
3492         (x_draw_glyph_string_background): Always draw background for BDF
3493         glyphs.
3495         * w32bdf.h (glyph_struct, cache_bitmap): Cache bitmap data, not
3496         GDI object which is a scarce resource.
3498         * w32bdf.c (search_file_line): Fix skipping of whitespace.
3499         (get_quoted_string): Fix limit on memchr search.
3500         (set_bdf_font_info): Use unsigned chars. Negate yoffset.
3501         (w32_init_bdf_font): Initialize codepoint and bitmap heaps.
3502         (w32_free_bdf_font): Free bitmaps and codepoints on heaps.
3503         (get_cached_font_char, cache_char_offset): Use macro
3504         BDF_CODEPOINT_RANGE_COVER_P.
3505         (cache_char_offset): Use HeapAlloc to allocate codepoints on own heap.
3506         (clear_cached_bitmap_slots): New function.
3507         (GET_HEX_VALUE): G-Z, g-z are not hex.
3508         (w32_get_bdf_glyph): Convert to DIB format. Return bytes read.
3509         (get_bitmap_with_cache): Use new cache implementation.
3510         (create_offscreen_bitmap): New function.
3511         (w32_BDF_TextOut): Use it. Draw glyphs as DIBs.
3513         * w32term.c (x_produce_glyphs):  If the distance from the current
3514         position to the next tab stop is less than a canonical character
3515         width, use the tab stop after that.
3516         (x_draw_glyphs): Handle case START and END are out of bounds more
3517         carefully.
3518         (x_clear_mouse_face): Block/unblock input.
3519         (x_display_and_set_cursor): Don't show a hollow box cursor for
3520         buffers whose cursor_type is nil.
3522 2000-09-29  Gerd Moellmann  <gerd@gnu.org>
3524         * xfns.c (x_set_tool_bar_lines): Clear frame when tool bar
3525         disappears.
3527         * dispextern.h (updating_frame): Declare extern.
3529 2000-09-29  Andreas Schwab  <schwab@suse.de>
3531         * m/ia64.h: Remove hack of not prototyping bcopy, etc.
3533 2000-09-29  Gerd Moellmann  <gerd@gnu.org>
3535         * keyboard.c (menu_bar_one_keymap): If KEYMAP is a symbol,
3536         use its function definition.
3537         (tool_bar_items): Likewise.
3539         * lisp.h (fatal): Declare NO_RETURN.
3540         
3541 2000-09-29  Kenichi Handa  <handa@etl.go.jp>
3543         * keymap.c: Remove the line "#undef NULL".
3545 2000-09-28  Gerd Moellmann  <gerd@gnu.org>
3547         * xterm.c (x_make_frame_visible): Try harder to make the frame
3548         visible.
3550 2000-09-28  Dave Love  <fx@gnu.org>
3552         * s/osf5-0.h: Define USE_MMAP_FOR_BUFFERS, not REL_ALLOC_MMAP.
3554         * s/sunos413.h (USE_MMAP_FOR_BUFFERS): Define.
3556         * .gdbinit (xreload): Note its need on GNU/Linux.
3558         * m/alpha.h (XUINT) [REL_ALLOC && _MALLOC_INTERNAL]: Don't declare
3559         r_alloc, r_alloc_free.
3561 2000-09-28  Kenichi Handa  <handa@etl.go.jp>
3563         * syntax.c (skip_chars): Handle negation correctly.
3565 2000-09-27  Gerd Moellmann  <gerd@gnu.org>
3567         * xfaces.c (realize_default_face): Call set_lface_from_font_name
3568         with non-zero FORCE_P argument.
3570         * dispnew.c (adjust_glyph_matrix, enable_glyph_matrix_rows): 
3571         Add assertions.
3573         * xdisp.c (window_box_height): Add an assertion.
3575         * xfns.c (x_set_tool_bar_lines): Don't use more lines for the
3576         tool-bar than is available.
3577         (x_change_window_heights): Renamed from x_set_menu_bar_lines_1.
3579 2000-09-27  Dave Love  <fx@gnu.org>
3581         * s/irix6-5.h: Now works 64-bit.  Tidied.
3583 2000-09-26  Gerd Moellmann  <gerd@gnu.org>
3585         * lisp.h (XINT) [EXPLICIT_SIGN_EXTEND]: Use BITS_PER_EMACS_INT
3586         instead of BITS_PER_INT.
3587         (XINT, XUINT) [NO_UNION_TYPE]: Cast result to EMACS_INT and
3588         EMACS_UINT, respectively.
3589         (NO_UNION_TYPE) [USE_LISP_UNION_TYPE]: Undefine.
3591         * m/sparc.h (BITS_PER_EMACS_INT) [__arch64__]: Don't define.
3593         * unexelf.c (ELFSIZE) [__NetBSD__ && __sparc_v9__]: Define to 64.
3595         * window.c (freeze_window_starts): Construct last argument for
3596         foreach_window differently.
3598         * xfns.c (x_decode_color): Don't return a Lisp_Object.
3600         * lisp.h (union Lisp_Object) [!NO_UNION_TYPE]: Use EMACS_INT and
3601         EMACS_UINT instead of `int' and `unsigned int'.
3602         (XSET) [EXPLICIT_SIGN_EXTEND]: Use EMACS_INT instead of `int'.
3604         * frame.h (struct frame): Make the `nothing' member of union
3605         output_data an EMACS_INT.
3607         * alloc.c (GC_CHECK_STRING_BYTES): Temporarily define, for bug
3608         hunting.
3609         (struct sdata) [GC_CHECK_STRING_BYTES]: Always record the string's
3610         size in the sdata structure.
3611         (SDATA_NBYTES, SDATA_DATA): New macros.
3612         (SDATA_OF_STRING, SDATA_SIZE) [GC_CHECK_STRING_BYTES]: Define
3613         differently for the different layout of the sdata structure.
3614         (allocate_string_data) [GC_CHECK_STRING_BYTES]: Record string size
3615         in sdata.
3616         (sweep_strings, compact_small_strings) [GC_CHECK_STRING_BYTES]:
3617         Check that size recorded in the string size and size recorded in
3618         the sdata structure agree.
3620 2000-09-25  Dave Love  <fx@gnu.org>
3622         * buffer.c: Include stdio.h.
3624         Partly suggested by Eduardo Horvath <eeh@netbsd.org>.
3625         
3626         * ralloc.c (__malloc_extra_blocks): Declare as __malloc_size_t.
3628         * alloc.c (__malloc_size_t) [DOUG_LEA_MALLOC]: Don't redefine it.
3629         (__malloc_size_t) [!DOUG_LEA_MALLOC]: Define unconditionally as
3630         size_t.
3631         (__malloc_extra_blocks): Declare as __malloc_size_t.
3633 2000-09-25  Gerd Moellmann  <gerd@gnu.org>
3635         * alloc.c (mark_image): Use GC_NILP instead of NILP.
3637         * keyboard.c (show_help_echo): Set help_echo_showing_p.
3638         (read_char): If help-echo is showing, preserve the echo area
3639         when redisplaying.
3641         * xdisp.c (help_echo_showing_p): New variable.
3642         (set_message): Reset it to 0.
3643         (init_xdisp): Initialize help_echo_showing_p.
3645         * dispextern.h (help_echo_showing_p): Declare extern.
3647         * config.in: Fix typo in __GNUC_MINOR__.
3649         * keyboard.h (quit_throw_to_read_char): Declare NO_RETURN.
3651         * s/freebsd.h (POSIX_SIGNALS): Define.
3653         * xterm.c (x_clear_mouse_face): Block/unblock input.
3655 2000-09-24  Dave Love  <fx@gnu.org>
3657         * fns.c (base64_encode_1): Fix last change.
3659 2000-09-22  Gerd Moellmann  <gerd@gnu.org>
3661         * dispnew.c (enable_glyph_matrix_rows): Remove xasserts.
3663         * xdisp.c (try_window_reusing_current_matrix): More fixes
3664         for the case window has a header-line.
3666 2000-09-22  Dave Love  <fx@gnu.org>
3668         * xdisp.c (syms_of_xdisp): Defvar Vmenu_bar_update_hook to provide
3669         a doc string.
3671         * xterm.c [SOLARIS2]: Remove redundant include of string.h.
3673         * fns.c (Fstring_as_unibyte, Fstring_as_multibyte): Doc fix.
3675 2000-09-21  Gerd Moellmann  <gerd@gnu.org>
3677         * config.in (NO_RETURN): Define as `__attribute__((__noreturn__))'
3678         for GCC >= 2.5.
3680         * lisp.h (wrong_type_argument, Fthrow, Fsignal, error): Declare
3681         NO_RETURN.
3683         * window.c, term.c, xmenu.c, xrdb.c, emacs.c, macros.c,
3684         * keymap.c, insdel.c, marker.c, minibuf.c, fileio.c, dired.c,
3685         * indent.c, search.c, alloc.c, data.c: Avoid some more compiler
3686         warnings.
3687         
3688         * marker.c (byte_char_debug_check): Return void.
3690         * xfns.c (Fx_create_frame): Set default frame parameter value
3691         for tool-bar-lines to 1.
3693         * dispnew.c (scrolling_window): Compare y-positions of rows
3694         equal at the start.  Some simplification.
3696         * xdisp.c (try_window_reusing_current_matrix): Fix computation of
3697         reused rows' y-position in the case window has a header-line, and
3698         new window start is greater than old window start.
3700         * process.c (process_sent_to): New variable.
3701         (send_process): Workaround for a crash on sparc-sun-solaris-2.6
3702         with GCC 2.95.2 caused by a parameter being clobbered by longjmp.
3703         Declare more parameters volatile.
3705         * lread.c (Vrecursive_load_depth_limit): New variable.
3706         (Fload): Check recursive loads whose recursion depth exceeds
3707         Vrecursive_load_depth_limit.
3708         (syms_of_lread): DERFAR_LISP recursive-load-depth-limit.
3710 2000-09-20  Gerd Moellmann  <gerd@gnu.org>
3712         * fileio.c (Fread_file_name): Doc fix.
3714         * editfns.c (Fmessage_or_box): Doc fix.
3716         * fns.c (Fy_or_n_p, Fyes_or_no_p): Doc fix.
3718         * xfns.c (xbm_scan): Allow C-style comments.
3719         
3720         * xfns.c (xpm_init_color_cache) [ALLOC_XPM_COLORS]: If color
3721         symbols are specified, add color translations to the cache.
3722         (xpm_color_bucket, xpm_cache_color) [ALLOC_XPM_COLORS]: New
3723         functions.
3724         (xpm_lookup_color) [ALLOC_XPM_COLORS]: Use xpm_color_bucket and
3725         xpm_cache_color.
3726         (xpm_load) [ALLOC_XPM_COLORS]: Pass frame and XPM attributes
3727         structures to xpm_init_color_cache.
3729 2000-09-19  Gerd Moellmann  <gerd@gnu.org>
3731         * dispnew.c (update_window_line): Make sure to always draw
3732         mode-lines.
3734 2000-09-19  Andrew Innes  <andrewi@gnu.org>
3736         * makefile.nt (bootstrap-emacs): Don't change directory.
3738 2000-09-19  Kenichi Handa  <handa@etl.go.jp>
3740         * charset.h (UNIBYTE_STR_AS_MULTIBYTE_P): Fix previous change.
3742         * ccl.c (Fccl_execute_on_string): Make multibyte string correctly.
3743         If output buffer is too small, signal an appropriated error.
3745 2000-09-18  Dave Love  <fx@gnu.org>
3747         * keyboard.c (menu_bar_items, tool_bar_items) 
3748         (current_active_maps): Remove redundant get_local_map call.
3750 2000-09-18  Gerd Moellmann  <gerd@gnu.org>
3752         * xterm.c (x_display_and_set_cursor): Don't show a hollow box
3753         cursor for buffers whose cursor_type is nil.
3754         
3755         * xterm.c (x_draw_image_glyph_string): Remove a comment describing
3756         a feature to implement that is already implemented.
3757         (note_mouse_highlight, x_find_ccl_program): Avoid some compiler
3758         warnings.
3760         * xfns.c (x_clear_image_1): New function.
3761         (x_clear_image): Use it.
3762         (x_from_xcolors): Use x_clear_image_1; don't free the image's
3763         mask.
3765         * dispnew.c (update_window): Move test for invisible lines
3766         at the top to update_window_line.
3767         (update_window_line): Handle invisible lines here.
3769         * xfns.c (clear_image_cache): Clear current matrices of all
3770         frames sharing an image cache.  Block input while freeing
3771         images.  Fix timestamp comparison.
3772         (x_clear_image): Also free the mask.
3774         * xfns.c (lookup_image): Block input while loading the image so
3775         that we won't get interrupted in a state where the image isn't yet
3776         set up completely.
3777         (xbm_load_image, xbm_load, xpm_load, xpm_load, lookup_rgb_color)
3778         (lookup_pixel_color, x_to_xcolors, x_from_xcolors)
3779         (x_disable_image, x_build_heuristic_mask, pbm_load, png_load)
3780         (jpeg_load, tiff_load, gif_load, gs_load): Don't block/unblock
3781         input.
3783 2000-09-16  Gerd Moellmann  <gerd@gnu.org>
3785         * dispnew.c (update_window): Make sure to make desired rows
3786         current even if they are completely invisible at the top
3787         of a window.
3789 2000-09-15  Gerd Moellmann  <gerd@gnu.org>
3791         * xfns.c (lookup_image): Build mask before applying an algorithm.
3792         Recognize algorithm `disabled'.
3793         (cross_disabled_images): New variable.
3794         (COLOR_INTENSITY): New macro.
3795         (x_detect_edges): Use COLOR_INTENSITY.
3796         (x_disable_image): New function.
3797         (syms_of_xfns): DEFVAR_BOOL cross_disabled_images.
3799         * xdisp.c (build_desired_tool_bar_string): For a toolbar item in
3800         disabled state, don't apply an image transformation algorithm if
3801         the user specified an image for the disabled state.  Use
3802         `:algorithm disabled' for creating a disabled item's image if the
3803         user hasn't specified an image.
3805         * xfns.c (ALLOC_XPM_COLORS): Define if we can use Emacs' color
3806         allocation functions with the XPM lib.
3807         (struct xpm_cached_color) [ALLOC_XPM_COLORS]: New structure.
3808         (XPM_COLOR_CACHE_BUCKETS) [ALLOC_XPM_COLORS]: New macro.
3809         (xpm_color_cache) [ALLOC_XPM_COLORS]: New variable.
3810         (xpm_init_color_cache, xpm_free_color_cache, xpm_lookup_color)
3811         (xpm_alloc_color, xpm_free_colors) [ALLOC_XPM_COLORS]: New
3812         functions.
3813         (xpm_load) [ALLOC_XPM_COLORS]: Use Emacs' own color allocation
3814         functions, if possible, because these handle color allocation
3815         failure more gracefully.
3816         (Fimage_mask_p): New function.
3818         * xfns.c (QCmatrix, QCcolor_adjustment, QCmask, Qemboss)
3819         (Qedge_detection, Qheuristic): New symbols.
3820         (syms_of_xfns): Initialize new symbols.
3821         (lookup_image): Handle `:mask X', `:algorithm emboss', and
3822         `algorithm (edge-detection ...)'.
3823         (xbm_format, xpm_format, pbm_format, png_format, jpeg_format):
3824         (tiff_format, gif_format, gs_format): Add `:mask'.
3825         (XBM_MASK, XPM_MASK, PBM_MASK, PNG_MASK, JPEG_MASK, TIFF_MASK)
3826         (GIF_MASK, GS_MASK): New enumerators.
3827         (x_laplace_read_row, x_laplace_write_row): Functions removed.
3828         (emboss_matrix, laplace_matrix): New variables.
3829         (x_to_xcolors, x_from_xcolors, x_detect_edges, x_emboss)
3830         (x_edge_detection): New functions.
3831         (x_laplace): Rewritten in terms of x_detect_edges.
3832         (x_build_heuristic_mask): If image has a mask, free it.
3834 2000-09-14  Andrew Innes  <andrewi@gnu.org>
3836         * makefile.w32-in: Revert to Unix line endings.
3838 2000-09-14  Andrew Innes  <andrewi@gnu.org>
3840         * makefile.w32-in: Standardize indentation somewhat.
3841         (bootstrap-temacs): Use $(ARGQUOTE) instead of literal quotes, to
3842         cater for differences between shells.
3844         * w32term.c (w32_per_char_metric): Handle non-TrueType fonts.
3846 2000-09-14  Gerd Moellmann  <gerd@gnu.org>
3848         * xterm.c (x_produce_glyphs): If the distance from the current
3849         position to the next tab stop is less than a canonical character
3850         width, use the tab stop after that.
3852 2000-09-14  Dave Love  <fx@gnu.org>
3854         * buffer.c (alloc_buffer_text): Fix xmalloc call.
3856 2000-09-14  Gerd Moellmann  <gerd@gnu.org>
3858         * xdisp.c (handle_fontified_prop): While running fontification
3859         functions, bind `fontification-functions' and
3860         `after-change-functions' to nil.
3862         * s/freebsd.h, s/irix-5.0.h, s/sol2.h, s/template.h
3863         (USE_MMAP_FOR_BUFFERS): Define instead of REL_ALLOC_MMAP.
3865         * Makefile.in (mallocobj) [SYSTEM_MALLOC]: Don't add ralloc.o.
3867         * emacs.c: Change conditional compilation on REL_ALLOC_MMAP to
3868         USE_MMAP_FOR_BUFFERS.
3870         * insdel.c (make_gap): Use enlarge_buffer_text.
3872         * buffer.c: Move allocation with mmap here, from ralloc.c.  Change
3873         conditional compilation on REL_ALLOC_MMAP to USE_MMAP_FOR_BUFFERS.
3874         (mmap_alloc, mmap_free, mmap_realloc) [REL_ALLOC_MMAP]: Renamed
3875         from former r_alloc_* functions in ralloc.c.
3876         (mmap_page_size, mmap_initialized_p) [REL_ALLOC_MMAP]: New
3877         variables.
3878         (MEM_ALIGN) [REL_ALLOC_MMAP]: New macro.
3879         (mmap_init) [REL_ALLOC_MMAP]: New function.
3880         (alloc_buffer_text, enlarge_buffer_text, free_buffer_text): New
3881         functions replacing macros BUFFER_ALLOC, BUFFER_REALLOC, and
3882         BUFFER_FREE.
3884         * buffer.h (BUFFER_ALLOC, BUFFER_REALLOC, BUFFER_FREE): Removed.
3885         (enlarge_buffer_text): Add prototype.
3887         * ralloc.c: Remove everything having to do with the use of mmap.
3889 2000-09-13  Gerd Moellmann  <gerd@gnu.org>
3891         * sound.c (Fplay_sound): Doc fix.
3893         * keyboard.c: Avoid some more compiler warnings.
3894         (parse_tool_bar_item): Ignore cached key bindings.
3896         * alloc.c: Add some comments about DOUG_LEA_MALLOC's use of mmap
3897         and allocation of Lisp data.
3899 2000-09-12  Gerd Moellmann  <gerd@gnu.org>
3901         * xfaces.c: Remove conditional compilation on SCALABLE_FONTS.
3902         (Finternal_set_lisp_face_attribute): If frame is 0, set new frame
3903         defaults first.
3905         * lread.c (Fload): Put code checking for recursive loads in #if 0.
3907 2000-09-12  Miyashita Hisashi  <himi@meadowy.org>
3909         * ccl.c: Comment fixed.
3910         (MAX_MAP_SET_LEVEL): Increased to 30.
3911         (PUSH_MAPPING_STACK): Enclose with do-while block.
3912         (POP_MAPPING_STACK): Likewise.
3913         (stack_idx_of_map_multiple): New variable.
3914         (CCL_CALL_FOR_MAP_INSTRUCTION): New macro.
3915         (ccl_driver) <CCL_IterateMultipleMap>: If the content is a symbol,
3916         call the corresponding CCL program by
3917         CCL_CALL_FOR_MAP_INSTRUCTION.
3918         (ccl_driver) <CCL_MapSingle>: Likewise.
3919         (ccl_driver) <CCL_MapMultiple>: Rewritten to fix many bugs, deal
3920         with the case where looking up process reaches to the end of
3921         map-set, and call CCL programs as the above change.
3923 2000-09-11  Gerd Moellmann  <gerd@gnu.org>
3925         * xfns.c (png_load, jpeg_load): Declare some variables volatile
3926         that might be clobbered by longjmp.
3927         (check_x_display_info, x_decode_color, create_frame_xic)
3928         (Fx_display_backing_store, Fx_display_visual_class)
3929         (x_build_heuristic_mask, pbm_scan_number): Avoid compiler
3930         warnings.
3932         * lread.c (init_lread): Set Vloads_in_progress to nil.
3933         (Fload): Show list of recursively loaded files, when signaling an
3934         error.
3936         * lread.c (Vloads_in_progress): New variable.
3937         (record_load_unwind): New function.
3938         (Fload): Check for recursive loads.
3939         (syms_of_lread): Initialize Vloads_in_progress.
3940         (read_integer, read1): Avoid some compiler warnings.
3942         * fns.c (concat, Fsubstring, internal_equal, Fnconc): Avoid some
3943         compiler warnings.
3945 2000-09-11  Miles Bader  <miles@gnu.org>
3947         * editfns.c (Fbuffer_string): Doc fix.
3949 2000-09-10  Gerd Moellmann  <gerd@gnu.org>
3951         * ralloc.c (mmap_enlarge): Don't return 0 if successful.
3953 2000-09-09  Ken Raeburn  <raeburn@gnu.org>
3955         * s/netbsd.h: Use NOT_C_CODE, not NO_C_SOURCE, when deciding
3956         whether to include other header files.
3958 2000-09-09  Gerd Moellmann  <gerd@gnu.org>
3960         * xfaces.c (CYCLE_CHECK): Don't use the Lisp_Object returned 
3961         by Fmemq as a boolean.
3963 2000-09-08  Stefan Monnier  <monnier@cs.yale.edu>
3965         * xfaces.c (Finternal_set_lisp_face_attribute): Minor thinko.
3967 2000-09-08  Gerd Moellmann  <gerd@gnu.org>
3969         * ralloc.c (mmap_fd): Remove initializer which can make it
3970         read-only in a dumped Emacs.
3971         (mmap_fd_1): New variable.
3972         (mmap_set_vars): Remove local `fd'.  Save mmap_fd in mmap_fd_1,
3973         restore it from there.
3974         (r_alloc, r_re_alloc, r_alloc_free): Call r_alloc_init
3975         unconditionally so that mmap_fd can be initialized there.
3976         (r_alloc_init_fd): Open-coded in r_alloc_init; function removed.
3977         (r_alloc_init) [REL_ALLOC_MMAP && !MAP_ANON]: Open /dev/zero.
3978         (r_alloc_init) [REL_ALLOC_MMAP && MAP_ANON]: Set mmap_fd to -1.
3980         * xfaces.c (Finternal_merge_in_global_face): Return a Lisp object.
3982         * xdisp.c (dump_glyph_row): Fix printf format string.
3983         (display_line, move_it_in_display_line_to): Avoid compiler
3984         warnings.
3986         * s/freebsd.h (GC_MARK_STACK, REL_ALLOC_MMAP): Define.
3988         * keymap.c (Fset_keymap_parent): Check for cycles in keymap
3989         inheritance.
3991         * xdisp.c (try_window_id): When trying to locate cursor in
3992         unchanged rows at the top, handle the case that we can't find it.
3994         * xterm.c (x_draw_glyphs): Handle case START and END are out
3995         of bounds more carefully.
3997 2000-09-08  Dave Love  <fx@gnu.org>
3999         * s/sol2.h (REL_ALLOC_MMAP): Define.
4000         * s/irix5-0.h (REL_ALLOC_MMAP): Likewise.
4002         * ralloc.c: Don't include string.h (redundant).
4003         (MAP_ANON) [REL_ALLOC_MMAP]: Ensure it's defined.
4004         [!MAP_ANON]: Include fcntl.h.
4005         (mmap_fd) [REL_ALLOC_MMAP]: New variable.
4006         (r_alloc, r_re_alloc, r_alloc_free)
4007         (mmap_enlarge, mmap_set_vars): Use it.
4008         (r_alloc_init_fd): New function.
4009         (__morecore) [SYSTEM_MALLOC]: Don't declare.
4010         (r_alloc_init): Call r_alloc_init_fd.  Conditionalize stuff on
4011         malloc type.
4013         * Makefile.in (allocaobj) [!SYSTEM_MALLOC && REL_ALLOC_MMAP]:
4014         Remove vm-limit.o.
4016         * unexelf.c (SHT_MIPS_DEBUG, HDRR) [__mips__]: Really confine last
4017         change to __NetBSD__.
4019 2000-09-08  Kenichi Handa  <handa@etl.go.jp>
4021         * search.c (compile_pattern): Check the multibyteness of cached
4022         string and PATTERN.
4024 2000-09-08  Miles Bader  <miles@gnu.org>
4026         * xfaces.c (default_face_vector): Function removed.
4027         (Finternal_merge_in_global_face): Restore old global/local
4028         attribute override order.  Use inline loop instead of calling
4029         default_face_vector.
4031 2000-09-07  Gerd Moellmann  <gerd@gnu.org>
4033         * ralloc.c (obtain, relinquish, relinquish, r_alloc_size_in_use)
4034         (get_bloc, relocate_blocs, update_heap_bloc_correspondence)
4035         (resize_bloc, r_alloc_sbrk, r_alloc_init): Add casts to `char *'
4036         where necessary, in case POINTER_TYPE is `void'.
4038 2000-09-07  Eli Zaretskii  <eliz@is.elta.co.il>
4040         * frame.c (make_terminal_frame): Initialize frame foreground and
4041         background colors to unspecified, for the initial instance of an
4042         MSDOS frame.
4044 2000-09-07  Gerd Moellmann  <gerd@gnu.org>
4046         * ralloc.c (mmap_find): Fix overlap computation.
4047         (mmap_enlarge): Compute nbytes before trying to find an
4048         overlapping region.
4050         * xfaces.c (smaller_face): Compare font heights with `<' and `>'
4051         instead of `!='.
4053         * lread.c (syms_of_lread): Change value of regexp
4054         Vbytecomp_version_regexp to not match some XEmacs-compiled files.
4056         * xmenu.c (xdialog_show): When looking up the selection in
4057         menu_items, take `quote' boundaries into account; this corresponds
4058         to a nil ITEM in x-popup-dialog.
4060 2000-09-07  Kenichi Handa  <handa@etl.go.jp>
4062         * charset.h (MIN_CHARSET_OFFICIAL_DIMENSION1): Define it as 0x80,
4063         not 0x81.
4064         (MIN_CHAR_OFFICIAL_DIMENSION1): Define it as ((0x81 - 0x70) << 7).
4066         * coding.c (encode_coding_sjis_big5): Use translation table for
4067         encoding, not decoding.  Fix the handling of latin-jisx0201.
4068         Check for the charset katakana-jisx0201 too.
4069         (ONE_MORE_CHAR): Call translate_char with CHARSET arg -1.
4070         (detect_coding_sjis): Check the byte sequence more rigidly.
4072 2000-09-07  Gerd Moellmann  <gerd@gnu.org>
4074         * xfaces.c (Vparam_value_alist): New variable.
4075         (syms_of_xfaces): Initialize it.
4076         (Finternal_set_lisp_face_attribute): Avoid more consing.
4078         * frame.c (Fframe_parameter): Handle `name' and `background-mode'
4079         specially.
4080         (Fframe_parameter) [HAVE_X_WINDOWS]: Handle `display' specially.
4081         (Qbackground_mode): New variable.
4082         (syms_of_frame_1): Initialize Qbackground_mode.
4084         * lisp.h (Qdisplay): Declare extern.
4086         * xfaces.c (Finternal_set_lisp_face_attribute): If FRAME is 0,
4087         change face on all frames, and change the default for new frames.
4089 2000-09-07  Dave Love  <fx@gnu.org>
4091         * Makefile.in [!SYSTEM_MALLOC && REL_ALLOC_MMAP]: Set mallocobj.
4093 2000-09-07  Kenichi Handa  <handa@etl.go.jp>
4095         * charset.h (MAKE_CHAR): Be sure to set MSB of C1 to 0.
4097         * charset.c: Include composite.h
4098         (lisp_string_width): New function.
4099         (Fstring_width): Call lisp_string_width instead of strwidth.
4101         * Makefile.in (charset.o): Depends on composite.h.
4103         * process.c (read_process_output): Before inserting the decoded
4104         text in the buffer, adjust the multibyteness.
4106 2000-09-06  Gerd Moellmann  <gerd@gnu.org>
4108         * buffer.c (set_buffer_internal_1) [REL_ALLOC_MMAP]: If 
4109         buffer's text buffer is null, map new memory.
4111         * ralloc.c (POINTER, SIZE) [emacs]: Define in terms of
4112         POINTER_TYPE and size_t.
4113         (struct mmap_region) [REL_ALLOC_MMAP]: New structure.
4114         (mmap_regions, mmap_regions_1) [REL_ALLOC_MMAP]: New variables.
4115         (ROUND, MMAP_REGION_STRUCT_SIZE, MMAP_REGION, MMAP_USER_AREA)
4116         [REL_ALLOC_MMAP]: New macros.
4117         (mmap_find, mmap_free, mmap_enlarge, mmap_set_vars)
4118         (mmap_mapped_bytes, r_alloc, r_re_alloc, r_alloc_free)
4119         [REL_ALLOC_MMAP]: New functions.
4121         * emacs.c (Fdump_emacs) [REL_ALLOC_MMAP]: Call mmap_set_vars
4122         before and after unexec.
4124         * buffer.c (init_buffer) [REL_ALLOC_MMAP]: Map new buffer
4125         text buffers if necessary.
4127         * buffer.h (R_ALLOC_DECLARE): Removed because unused.
4128         (r_alloc, r_re_alloc, r_alloc_free): Use POINTER_TYPE and size_t
4129         in prototypes.
4131         * config.in (HAVE_MMAP): Add #undef.
4133 2000-09-05  Gerd Moellmann  <gerd@gnu.org>
4135         * frame.c (Qdisplay_type): New variable.
4136         (syms_of_frame_1): Initialize it.
4137         (Fframe_parameter): New function that avoids consing.
4138         (syms_of_frame): Defsubr it.
4140         * buffer.c (Fother_buffer): Consider buffers as invisible when
4141         they are displayed in a window on an invisible frame.
4143         * window.c (window_loop) <GET_LARGEST_WINDOW>: Fix bug making
4144         get-largest-window always return nil.
4146 2000-09-04  Gerd Moellmann  <gerd@gnu.org>
4148         * lread.c (syms_of_lread): Make Vbytecomp_version_regexp a Lisp
4149         variable; recognize Emacs 19 elc files.
4151 2000-09-04  Miles Bader  <miles@gnu.org>
4153         * xmenu.c (xmenu_show): Call x_set_menu_resources_from_menu_face
4154         before initially popping up the menu, so the menu doesn't flash
4155         when the face settings are significantly different from the
4156         defaults.
4158 2000-09-04  Stefan Monnier  <monnier@cs.yale.edu>
4160         * regex.c (WIDE_CHAR_SUPPORT): New macro.
4161         (btowc, iswctype, wctype) [_LIBC]: Redefine to __<fun>.
4162         (BIT_ALPHA, BIT_ALNUM, BIT_ASCII, BIT_NONASCII, BIT_GRAPH, BIT_PRINT)
4163         (BIT_UNIBYTE): Remove.
4164         (re_match_2_internal): Delete corresponding code and streamline the
4165         BIT_MULTIBYTE case to not bother checking ISUNIBYTE.
4166         (CHAR_CLASS_MAX_LENGTH) [!WIDE_CHAR_SUPPORT]: Set to 9 rather than 6.
4167         (re_wctype_t): New type.
4168         (re_wctype, re_iswctype, re_wctype_to_bit): New functions.
4169         (regex_compile): Use them and fix handling of overly long char classes.
4171 2000-09-03  Andrew Innes  <andrewi@gnu.org>
4173         * makefile.w32-in: Change to DOS line endings.
4175         * s/ms-w32.h (ORDINARY_LINK): New define.
4177         * w32.c (_ANONYMOUS_UNION) [__GNUC__]: New define
4178         (_ANONYMOUS_STRUCT) [__GNUC__]: New define.
4180         * makefile.w32-in (clean): Don't delete config.h and epaths.h.
4181         (distclean): Delete them here instead.
4183         * w32proc.c (compare_env): Convert to uppercase for comparison,
4184         not lowercase, to match how the native Windows shell works.
4186 2000-09-03  Jason Rumney  <jasonr@gnu.org>
4188         * ChangeLog: Remove -unix from coding. Let Emacs autodetect, as
4189         CVS changes the line-ends when checking in/out on DOS/Windows.
4191         * makefile.nt (emacs): Do not change directory to run temacs, as
4192         the load-path is set relative to current directory.
4194 2000-09-03  Miles Bader  <miles@gnu.org>
4196         * xterm.c (x_alloc_lighter_color_for_widget): New function.
4198 2000-09-02  Gerd Moellmann  <gerd@gnu.org>
4200         * xdisp.c (redisplay_mode_lines): New function.
4201         (display_mode_lines): Return number of mode lines displayed.
4202         (echo_area_display): Use redisplay_mode_lines to draw garbaged
4203         mode lines.  Don't temporarily bind redisplay-dont-pause to t.
4205         * emacs.c, callint.c, doc.c, editfns.c: Remove includes of
4206         string.h and strings.h.
4207         (index) [HAVE_INDEX]: Add prototype.
4209         * unexelf.c (SHT_PROGBITS) [__NetBSD__ && !PT_LOAD]: Don't define.
4210         (SHT_MIPS_DEBUG, HDRR) [__NetBSD__ && __mips__]: Define.
4212         * s/netbsd.h [!NO_C_SOURCE]: Include <signal.h>.
4213         (GC_SETJMP_WORKS, GC_MARK_STACK): Define.
4215 2000-09-01  Gerd Moellmann  <gerd@gnu.org>
4217         * lread.c (read1): Accept `?' as symbol constituent, for
4218         compatiblity with XEmacs.
4220 2000-08-31  Stefan Monnier  <monnier@cs.yale.edu>
4222         * regex.h (RE_NO_NEWLINE_ANCHOR): New syntax flag.
4223         (struct re_pattern_buffer): Remove newline_anchor.
4224         * regex.c: Keep namespace clean for GNU libc by renaming <fun>
4225         to __<fun> and using `weak_alias (__<fun>, <fun>)'.
4226         (re_max_failures, fail_stack): Use size_t rather than unsigned.
4227         (regex_compile): For ^ and $, choose between buffer and line (beg|end)
4228         depending on the new RE_NO_NEWLINE_ANCHOR syntax flag.
4229         (print_compiled_pattern, re_search_2, mutually_exclusive_p)
4230         (re_match_2_internal, re_compile_pattern, re_comp, regcomp):
4231         Get rid of references to newline_anchor.
4232         (regcomp): Allocate and precompute a fastmap.
4234 2000-08-31  Gerd Moellmann  <gerd@gnu.org>
4236         * lread.c (openp): GCPRO local variable `filename'.
4238 2000-08-30  Stefan Monnier  <monnier@cs.yale.edu>
4240         * regex.h (struct re_pattern_buffer): Use size_t for used/allocated.
4242         * regex.c: Merge some changes from GNU libc.  Add prototypes.
4243         (bcopy, bcmp, REGEX_REALLOCATE, re_match_2_internal):
4244         Use memcmp and memcpy instead of bcopy and bcmp.
4245         (init_syntax_once): Use ISALNUM.
4246         (PUSH_FAILURE_POINT, re_match_2_internal): Remove failure_id.
4247         (REG_UNSET_VALUE): Remove.  Use NULL instead.
4248         (REG_UNSET, re_match_2_internal): Use NULL.
4249         (SET_HIGH_BOUND, MOVE_BUFFER_POINTER, ELSE_EXTEND_BUFFER_HIGH_BOUND):
4250         New macros.
4251         (EXTEND_BUFFER): Use them (to work with BOUNDED_POINTERS).
4252         (GET_UNSIGNED_NUMBER): Don't use ISDIGIT.
4253         (regex_compile): In handle_interval, return an error rather than try to
4254         unfetch the interval if we can't find the closing brace.
4255         Obey the RE_NO_GNU_OPS syntax bit.
4256         (TOLOWER): New macro.
4257         (regcomp): Use it.
4258         (regexec): Allocate regs.start and regs.end as one block.
4260 2000-08-30  Gerd Moellmann  <gerd@gnu.org>
4262         * xdisp.c (echo_area_display): Check display_completed instead
4263         of calling detect_input_pending.
4265         * dispnew.c (update_frame): Only set display_completed here; move
4266         the update_begin and update_end calls here from update_frame_1.
4267         (update_frame_1): Don't set display_completed here, don't call
4268         update_begin/update_end.
4270         * xfaces.c (set_font_frame_param): Use Fmodify_frame_parameters
4271         instead of store_frame_param.
4273 2000-08-29  Gerd Moellmann  <gerd@gnu.org>
4275         * dispnew.c (build_frame_matrix_from_leaf_window): If a row of a
4276         desired window matrix hasn't been displayed, use the current row
4277         instead.  Make sure that only those frame rows are updated for
4278         which there exists a corresponding enabled desired row.
4279         
4280 2000-08-29  Miles Bader  <miles@gnu.org>
4282         * xfaces.c (default_face_vector): New function.
4283         (Finternal_merge_in_global_face): Use it instead of merge_face_vectors.
4285 2000-08-29  Gerd Moellmann  <gerd@gnu.org>
4287         * lread.c (openp): Prevent temporary string passed to
4288         Ffile_readable_p from being garbage collected.
4290 2000-08-28  Dave Love  <fx@gnu.org>
4292         * keymap.c (store_in_keymap): Add `static' to declaration.
4294 2000-08-28  Gerd Moellmann  <gerd@gnu.org>
4296         * emacs.c, callint.c, doc.c, editfns.c
4297         (toplevel) [HAVE_STRING_H]: Include string.h.
4298         (toplevel) [HAVE_STRINGS_H]: Include strings.h.
4299         (index): Remove prototypes which might conflict with non-standard
4300         definitions of index/strchr.
4302         * s/usg5-3.h (index): Define only if not HAVE_INDEX.
4303         (rindex): Define only if !HAVE_RINDEX.
4305         * s/sco5.h (bcopy, bzero, bcmp): Don't define.
4307         * config.in (HAVE_INDEX, HAVE_RINDEX, HAVE_STRINGS_H): Add undefs.
4309 2000-08-28  Miles Bader  <miles@gnu.org>
4311         * xfaces.c (merge_face_vectors): Clear TO's :font attribute if
4312         made inconsistent by a font-related attribute in FROM.
4313         (merge_face_inheritance): Add function comment.
4315 2000-08-28  Kenichi Handa  <handa@etl.go.jp>
4317         * keyboard.c (read_char_minibuf_menu_prompt): Call read_char with
4318         the 4th arg (PREV_EVENT) Qt to suppress input method.
4320 2000-08-27  Stefan Monnier  <monnier@cs.yale.edu>
4322         * regex.c: Indent cpp directives and remove parens after `defined'.
4323         (PTR_TO_OFFSET, POS_AS_IN_BUFFER): Move to a better place.
4324         (ISDIGIT, ISCNTRL, ISXDIGIT) [!emacs]: Remove duplicate definition.
4325         (regex_compile): Use RE_FRUGAL instead of RE_ALL_GREEDY.
4326         (re_compile_pattern): Use size_t for length.
4327         (init_syntax_once): Move to a better place.
4328         * regex.h: Merge changes from GNU libc.  Indent cpp directives.
4329         (RE_FRUGAL): Replaces RE_ALL_GREEDY (inverted meaning).
4331         * syntax.c (back_comment): Detect cases where a comment-starter is
4332         actually inside another comment as in:   /* a // b */ c // d \n.
4333         Make it clear that `comstart_pos' is unused for nested comments.
4335         * keymap.c (store_in_keymap, fix_submap_inheritance): New prototypes.
4336         (KEYMAPP): New macro.
4337         (Fkeymap_parent, Fset_keymap_parent): Use it.
4338         (fix_submap_inheritance): Mark it static.
4339         (define_as_prefix, describe_buffer_bindings, describe_command)
4340         (describe_translation, describe_map): Complete prototypes.
4342         * lisp.h (store_in_keymap, fix_submap_inheritance): Remove.
4344         * keyboard.c (menu_bar_item): Detect duplicate entries for all items
4345         to better match the key-lookup behavior.
4347 2000-08-27  Gerd Moellmann  <gerd@gnu.org>
4349         * xfaces.c (lface_fully_specified_p): Handle :inherit.
4350         (Finternal_set_lisp_face_attribute): Fix typo in error message.
4352 2000-08-27  Eli Zaretskii  <eliz@is.elta.co.il>
4354         * Makefile.in (dispnew.o, indent.o, fontset.o, minibuf.o)
4355         (process.o, scroll.o, sysdep.o): Depend on keyboard.h.
4356         (xterm.o): Depend on coding.h
4358 2000-08-26  Kenichi Handa  <handa@etl.go.jp>
4360         * cmds.c (internal_self_insert): Delete '#ifdef HAVE_FACES' and
4361         the corresponding '#endif'.
4363 2000-08-26  Miles Bader  <miles@gnu.org>
4365         * dispextern.h (enum lface_attribute_index): Add LFACE_INHERIT_INDEX.
4366         * xfaces.c (QCinherit): New variable.
4367         (syms_of_xfaces): Initialize it.
4368         (LFACE_INHERIT): New macro.
4369         (Finternal_get_lisp_face_attribute)
4370         (merge_face_vector_with_property) 
4371         (Finternal_set_lisp_face_attribute): Deal with :inherit attribute.
4372         (check_lface_attrs): Allow new types of face height.  Check
4373         inherit attribute.
4374         (CYCLE_CHECK): New macro.
4375         (merge_face_inheritance): New function.
4376         (merge_face_vectors): Merge inherited faces too.  Add F and
4377         CYCLE_CHECK arguments.
4378         (merge_face_vector_with_property, Finternal_merge_in_global_face)
4379         (lookup_named_face, lookup_derived_face, realize_named_face)
4380         (face_at_string_position, face_at_buffer_position):  Supply
4381         new F and CYCLE_CHECK arguments to merge_face_vectors.
4382         (merge_face_heights): New function.
4383         (merge_face_vectors, merge_face_vector_with_property) 
4384         (Finternal_set_lisp_face_attribute): Call merge_face_heights to
4385         handle relative face heights.
4386         (lface_same_font_attributes_p): Compare heights using EQ.
4388 2000-08-26  Kenichi Handa  <handa@etl.go.jp>
4390         * charset.c (char_to_string): Check the character validity.
4391         (char_valid_p): If C is not less than MAX_CHAR, be sure to return
4392         0.
4394 2000-08-25  Stefan Monnier  <monnier@cs.yale.edu>
4396         * regex.c (PUSH_FAILURE_COUNT): New macro.
4397         (POP_FAILURE_REG_OR_COUNT): Renamed from POP_FAILURE_REG.
4398         Handle popping of a register's or a counter's data.
4399         (POP_FAILURE_POINT): Use the new name.
4400         (re_match_2_internal): Push counter data on the stack for succeed_n,
4401         jump_n and set_number_at and remove misleading dead code in succeed_n.
4403 2000-08-25  Gerd Moellmann  <gerd@gnu.org>
4405         * xdisp.c (redisplay_internal): If considering all windows on all
4406         frames, update the display for each frame as soon as possible,
4407         instead of first building all desired matrices for all frames, and
4408         then updating them all.
4409         (try_cursor_movement): Handle case that last_cursor.vpos is -1.
4411 2000-08-24  Gerd Moellmann  <gerd@gnu.org>
4413         * bytecode.c (mark_byte_stack): Add a comment.
4415         * frame.h (FRAME_FLAGS_AREA_COLS, FRAME_FLAGS_AREA_WIDTH) 
4416         (FRAME_LEFT_FLAGS_AREA_WIDTH): Return 0 unless frame is 
4417         a graphical frame.
4419 2000-08-24  Kenichi Handa  <handa@etl.go.jp>
4421         * minibuf.c (do_completion): Always use compare-string, not
4422         string-equal because the latter doesn't pay attention to
4423         multibyteness of strings.
4425         * process.c (create_process): Don't setup raw-text coding here.
4426         (Fopen_network_stream): Don't set coding->src_multibyte and
4427         coding->dst_multibyte here.
4428         (read_process_output): For process filter, return unibyte string
4429         if default-enable-multibyte-characters is nil.
4430         (send_process): If OBJECT is multibyte text, be sure to encoded it
4431         by the specified coding system for the process.  Otherwise, setup
4432         raw-text coding.
4433         (init_process): Don't initialize default-process-coding-system
4434         here.
4436 2000-08-23  Eli Zaretskii  <eliz@is.elta.co.il>
4438         * buffer.c (syms_of_buffer) <scroll-up-aggressively>: Doc fix.
4439         <scroll-down-aggressively>: Likewise.
4441 2000-08-23  Kenichi Handa  <handa@etl.go.jp>
4443         * coding.c (encode_eol): Fix bug for the case of dst_bytes being
4444         zero.  Set coding->produced_char correctly.
4446 2000-08-22  Andrew Innes  <andrewi@gnu.org>
4448         * makefile.w32-in: New file.
4450         * unexw32.c (unexec): Ignore old_name, and use the actual location
4451         of the current executable instead.  Base new_name on this.
4453         * w32proc.c (create_child): Remove reference to security
4454         descriptor, which isn't needed and doesn't compile with mingw32.
4456         * w32term.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4457         up dllimport attributes.
4458         (x_update_window_end): Update prototype.
4460         * unexec.c (write_segment) [USE_CRT_DLL]: Remove unnecessary
4461         extern, which screws up dllimport attributes.
4463         * sysdep.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4464         up dllimport attributes.
4466         * strftime.c [USE_CRT_DLL]: Remove unnecessary extern, which
4467         screws up dllimport attributes.
4469         * process.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4470         up dllimport attributes.
4471         (create_process) [USE_CRT_DLL]: Remove unnecessary extern, which
4472         screws up dllimport attributes.
4474         * lread.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4475         up dllimport attributes.
4477         * keyboard.c [USE_CRT_DLL]: Remove unnecessary extern, which
4478         screws up dllimport attributes.
4480         * floatfns.c [USE_CRT_DLL]: Remove unnecessary extern, which
4481         screws up dllimport attributes.
4483         * fileio.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4484         up dllimport attributes.
4486         * emacs.c (malloc_initialize_hook) [USE_CRT_DLL]: Remove
4487         unnecessary extern, which screws up dllimport attributes.
4488         (main): Ditto.
4490         * editfns.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4491         up dllimport attributes.
4493         * dispnew.c (window_change_signal) [USE_CRT_DLL]: Remove
4494         unnecessary extern, which screws up dllimport attributes.
4496         * callproc.c [USE_CRT_DLL]: Remove unnecessary extern, which
4497         screws up dllimport attributes.
4499         * buffer.c [USE_CRT_DLL]: Remove unnecessary extern, which screws
4500         up dllimport attributes.
4502         * w32proc.c (IsValidLocale): Extern missing from mingw32 headers.
4504         * w32bdf.c (search_file_line): 
4505         (set_bdf_font_info): 
4506         (seek_char): 
4507         (w32_get_bdf_glyph): 
4508         (w32_BDF_to_x_font): Fix compile warnings.
4510         * w32menu.c: Include keyboard.h before frame.h.  Fix compile
4511         warnings.
4513         * w32select.c: Include keyboard.h before frame.h.
4515         * w32fns.c (max): Define macro.
4516         (JOHAB_CHARSET): Define if not known.
4517         (MOD_ALT, MOD_CONTROL, MOD_SHIFT, MOD_WIN): Define if not known.
4518         (Fx_show_tip): Synch with X version.
4520         * w32xfns.c: Include keyboard.h before frame.h.
4522         * w32fns.c: Include keyboard.h before frame.h.
4524         * w32term.c: Include keyboard.h before frame.h.
4526         * fontset.c: Include keyboard.h before frame.h.
4528         * w32inevt.c: Include keyboard.h before frame.h.
4529         (MOUSE_MOVED): Define if not known.
4531         * minibuf.c: Include keyboard.h before frame.h.
4533         * keyboard.c: Include keyboard.h before frame.h.
4535         * indent.c: Include keyboard.h before frame.h.
4537         * dispnew.c: Include keyboard.h before frame.h.
4539         * buffer.c: Include keyboard.h before frame.h.
4541         * alloc.c: Include keyboard.h before frame.h.
4543         * print.c: Include keyboard.h before frame.h.
4545         * process.c: Include keyboard.h before frame.h.
4547         * scroll.c: Include keyboard.h before frame.h.
4549         * sysdep.c: Include keyboard.h before frame.h.
4551         * term.c: Include keyboard.h before frame.h.
4553         * window.c: Include keyboard.h before frame.h.
4555         * xdisp.c: Include keyboard.h before frame.h.
4556         Separate GLYPH_DEBUG and DEBUG_TRACE_MOVE.
4558         * frame.c: Include keyboard.h before frame.h.
4560         * w32heap.h: Undefine min, max.
4562         * w32gui.h: Undefine min, max.
4564         * unexw32.c: Change PUCHAR to PCHAR.
4565         (PTR_TO_OFFSET): Cast ptr to unsigned char *.
4566         (relocate_offset): 
4567         (get_section_info): 
4568         (copy_executable_and_dump_data): Remove unnecessary static defs.
4569         (copy_executable_and_dump_data): Fix compile warnings.
4571         * sysdep.c (NULL) [WINDOWSNT]: Define NULL if not defined.
4573         * w32console.c (min): Define macro.
4574         (clear_frame, write_glyphs): Fix compile warning.
4576         * w32proc.c (compare_env): 
4577         (find_child_console): Fix compile warning.
4579         * w32.c (sys_strerror): Use sys_nerr instead of _sys_nerr.  Use
4580         sys_errlist instead of _sys_errlist.
4581         (get_emacs_configuration_options): New function.
4583         * s/ms-w32.h (sys_nerr): Provide default definition.
4584         (strdup, strupr, strnicmp, stricmp, tzset, tzname): Map to same
4585         name with _ prepended.
4586         (NSIG): Define if not known.
4587         (get_emacs_configuration): Provide extern declaration.
4588         (get_emacs_configuration_options): Provide extern declaration.
4589         (EMACS_CONFIG_OPTIONS): Call get_emacs_configuration_options.
4591         * w32.c (gettimeofday): Use struct timeb, not struct _timeb.
4592         (map_w32_filename): 
4593         (read_unc_volume): Fix compile warning.
4595         * s/ms-w32.h (_WINSOCK_H): Define to prevent normal winsock
4596         definitions from being used.
4598         * lisp.h [WINDOWSNT]: Don't declare externs for getenv, ctime and getwd.
4600         * w32.c (unc_volume_file_attributes): 
4601         (open_unc_volume): Make arg const.
4603         * sysdep.c [WINDOWSNT]: Remove extern decl of errno.
4604         (read_input_waiting): Remove excess parameter.
4606         * w32.c (init_environment): Call _access.
4607         (check_windows_init_file): Call _close.
4608         (init_user_info): Call _putenv.
4609         (init_environment): Call _putenv and _strdup.
4610         (init_ntproc): Reset volume info cache on startup.
4612         * s/ms-w32.h (malloc, free, realloc, calloc): Rename if
4613         USE_CRT_DLL is defined, so Emacs can use GNU malloc even though it
4614         cannot override the CRT malloc.
4616         * makefile.nt (LOCAL_FLAGS): Define USE_CRT_DLL if requested.
4617         (LINK_FLAGS): Append to original value of LINK_FLAGS.
4619         * w32heap.c [!USE_CRT_DLL]: Don't define _heap_init and _heap_term
4620         unless we are linking with a static CRT.
4621         (RVA_TO_PTR): Cast result to unsigned char*.
4623         * w32.c (GetCachedVolumeInformation): Use xmalloc, xfree and xstrdup.
4624         (add_volume_info): Use xstrdup.
4626 2000-08-22  Stefan Monnier  <monnier@cs.yale.edu>
4628         * minibuf.c (Vcompletion_auto_help): Renamed from `auto_help'.
4629         (do_completion, Fminibuffer_complete_word): Use it.
4630         (syms_of_minibuf): Turn completion-auto-help into a proper Lisp
4631         var so it can take non-boolean values.
4633 2000-08-21  Gerd Moellmann  <gerd@gnu.org>
4635         * editfns.c (find_field): Formatting changes.
4636         (toplevel): Some old-style function forward declarations 
4637         changed to prototypes, some new protypes added, some functions
4638         made static.
4640         * lisp.h (set_time_zone_rule): Add prototype.
4641         (use_dialog_box): External declaration.
4643         * keyboard.c (gen_help_event): Add parameter SIZE.
4644         (kbd_buffer_events_waiting): Slightly rewritten.
4645         (clear_event): New function.
4646         (kbd_buffer_get_event): Use it, and clear the input_events of
4647         HELP_EVENTs.
4648         (init_keyboard): Remove duplicate creation of kbd_buffer_gcpro and
4649         don't fill the newly created array with nils.
4650         (toplevel): Convert some old-style function forward declarations
4651         to prototypes.
4653         * keyboard.h (gen_help_event): Change prototype.
4655         * xterm.c (XTread_socket): Change calls to gen_help_event.
4657         * w32term.c (w32_read_socket): Change calls to gen_help_event.
4659         * eval.c (Fmacroexpand): Doc fix.
4661 2000-08-20  Jason Rumney  <jasonr@gnu.org>
4663         * w32term.h (x_display_info_for_display): Remove as this function
4664         does not exist on W32.
4666         * w32term.c (help_echo_window): New variable.
4667         (syms_of_w32term): staticpro it.
4668         (note_mode_line_highlight): Set it.
4669         (XTextExtents16): Removed as there is no equivalent on W32.
4670         (x_compute_glyph_string_overhangs): Incomplete body removed, as
4671         the X way of doing this will not work for W32.
4672         (w32_intersect_rectangles): Removed. Use IntersectRect API call.
4673         (x_draw_image_foreground):  Avoid drawing outside of the clip area
4674         when image doesn't have a mask.
4675         (note_mouse_highlight): Process overlays in the right order of
4676         priority. Set help_echo_window.
4677         (x_draw_bar_cursor): If cursor is on an image, draw a box cursor
4678         because that's more visible for large images.
4680         * w32menu.c (keymap_panes): Pass the keymap's prompt as the pane
4681         name to single_keymap_panes.
4682         (w32_menu_show): Set wv->title when dealing with titles.
4683         (w32_menu_display_help): Call show_help_echo with OBJECT and POS.
4685 2000-08-21  Miles Bader  <miles@gnu.org>
4687         * minibuf.c (do_completion): Try again if we rewrite the input
4688         string, but no completion was done, so that any completion message
4689         will be correct.
4691 2000-08-20  Gerd Moellmann  <gerd@gnu.org>
4693         * xfaces.c (lface_equal_p): Compare strings differently.
4694         (Qtty_color_alist, Vtty_defined_color_alist): New variables.
4695         (realize_tty_face): Use them.
4696         (syms_of_xfaces): Initialize new variables.
4697         (map_tty_color): New function, extracted from realize_tty_face.
4698         (map_tty_color) [MSDOS || WINDOWSNT]: If using the frame's default
4699         foreground or background color, store the new color name in the
4700         realized face; previous code trying to do this had no effect.
4701         (realize_tty_face): Use map_tty_color.
4702         (Fclear_face_cache): Set face_change_count and ensure thorough
4703         redisplay.
4705 2000-08-19  Gerd Moellmann  <gerd@gnu.org>
4707         * undo.c (record_first_change, record_marker_adjustment): Don't
4708         use XBUFFER on last_undo_buffer which might not be a buffer.
4710 2000-08-18  Kenichi Handa  <handa@etl.go.jp>
4712         * coding.c (decode_coding_string): Set members consumed,
4713         consumed_char, produced, produced_char of *coding correctly.  If
4714         decode_coding doesn't consume any byte, don't try anymore.
4715         (encode_coding_string): Likewise.
4717 2000-08-18  Gerd Moellmann  <gerd@gnu.org>
4719         * lisp.h (CHECK) [ENABLE_CHECKING]: Make both sides of the
4720         conditional have void type, for Standard C compilers.
4722         * xdisp.c (redisplay_internal): Compare windows for equality with
4723         EQ, instead of applying XWINDOW to something that might not
4724         be a window.
4725         
4726 2000-08-18  Kenichi Handa  <handa@etl.go.jp>
4728         * fontset.c (Finternal_char_font): Search only the selected frame
4729         for a window of the current buffer.
4731 2000-08-18  Gerd Moellmann  <gerd@gnu.org>
4733         * minibuf.c (do_completion): Use EQ instead of `!=' to compare
4734         Lisp_Objects.
4736         * keyboard.c (kbd_buffer_get_event): Handle the case that the
4737         second half of a HELP_EVENT is found at the start of kbd_buffer.
4739 2000-08-18  Miles Bader  <miles@gnu.org>
4741         * lisp.h (Lisp_String): Replace DECLARE_INTERVALS with real decl.
4743         * editfns.c (save_restriction_save): Rewrite to use markers.
4744         (save_restriction_restore): Rewrite to understand new form of data
4745         saved by save_restriction_save.
4746         (Fsave_restriction): Remove cautionary note in doc-string.
4748 2000-08-17  Gerd Moellmann  <gerd@gnu.org>
4750         * fileio.c (build_annotations): Add a comment explaining the
4751         return value of format-annotate-function.  Replace a spurious call
4752         to Flength with a CONSP test.  Call format-annotate-function with
4753         a fifth arg specifying how many times the function is been called
4754         in a row, to let it choose temporary buffers appropriately.
4756 2000-08-17  Dave Love  <fx@gnu.org>
4758         * lisp.h: Remove DECLARE_INTERVALS, INITIALIZE_INTERVAL.  Don't
4759         declare make_temp_name twice.
4761         * lread.c: Prototype readevalloop, load_unwind,
4762         load_descriptor_unwind.
4763         (unreadpure): Give it an arg.
4765         * unexalpha.c: Prototype fatal_unexec, mark_x,
4766         update_dynamic_symbols.  Declare unexec as void.
4768         * cm.c [HAVE_TERMCAP_H]: Include <termcap.h>.
4769         [!HAVE_TERMCAP_H]: Prototype tputs, tgoto.
4771         * alloc.c (lisp_malloc): Declare with POINTER_TYPE.
4772         [SYSTEM_MALLOC]: Make decls in malloc.h conditional on
4773         DOUG_LEA_MALLOC.
4775         * alloca.c: Use #error.
4776         [POINTER_TYPE]: Use it.
4778         * eval.c (Fdefvar): Doc fix.
4780         * buffer.c (Fget_buffer_create, Fmake_indirect_buffer): Avoid
4781         INITIALIZE_INTERVAL.
4783         * buffer.h: Avoid DECLARE_INTERVALS.
4785         * config.in: Add size_t.
4787 2000-08-17  Eli Zaretskii  <eliz@is.elta.co.il>
4789         * w16select.c (set_clipboard_data): If there's not enough memory
4790         to put text into clipboard, return 1, as Fw16_set_clipboard_data
4791         expects.  In case of other failures, return 3.
4792         (system_error_msg): New error message.
4793         (Fw16_set_clipboard_data): If set_clipboard_data returns 3, print
4794         system_error_msg.
4796 2000-08-16  Gerd Moellmann  <gerd@gnu.org>
4798         * term.c (write_glyphs): Also turn off inverse video after turning
4799         off other appearances in case TS_exit_attribute_mode is not equal
4800         to TS_end_standout_mode.
4801         (insert_glyphs): Turn inverse video on/off for each run of glyphs
4802         with the same face.
4803         (turn_off_face): Reset standout_mode only if
4804         TS_exit_attribute_mode has been output and TS_exit_attribute_mode
4805         is equal to TS_end_standout_mode.
4807 2000-08-16  Kenichi Handa  <handa@etl.go.jp>
4809         * coding.c (encode_coding): Fix the bug of not flushing ISO escape
4810         sequence at the end of the source block.
4812         * ccl.c (Fccl_program_p): Docstring modified.
4813         (Fccl_execute): Likewise.
4814         (Fccl_execute_on_string): Likewise.
4816 2000-08-16  Eli Zaretskii  <eliz@is.elta.co.il>
4818         * msdos.c (IT_write_glyphs): Convert cbp to unsigned char *.
4820 2000-08-16  Kenichi Handa  <handa@etl.go.jp>
4822         The following changes are mainly to fix bugs of
4823         encode/decode-coding-string failing if encoding/decoding return
4824         CODING_FINISH_INSUFFICIENT_DST.  In addition, delete the global
4825         variable conversion_buffer.
4827         * ccl.c (CCL_WRITE_CHAR): If CH is eight-bit-control char,
4828         decrement dst_end to avoid buffer overflow in the later call of
4829         string_as_multibyte
4831         * coding.h (conversion_buffer_size, conversion_buffer)
4832         (get_conversion_buffer): Extern deleted.
4834         * coding.c (MINIMUM_CONVERSION_BUFFER_SIZE): Macro deleted.
4835         (conversion_buffer, conversion_buffer_size): Variables deleted.
4836         (get_conversion_buffer): Function deleted.
4837         (struct conversion_buffer): New structure.
4838         (MAX_ALLOCA): New macro.
4839         (allocate_conversion_buffer): New macro.
4840         (extend_conversion_buffer, free_conversion_buffer): New functions.
4841         (ccl_coding_driver): Set coding->result.
4842         (decode_coding): Set coding->result to CODING_FINISH_NORMAL if
4843         this is the last block of source.
4844         (encode_coding): Likewise.  Handle the source block as the last
4845         one only when the whole source text is consumed.
4846         (decode_coding_string): Handle the case that the output buffer is
4847         too small to decode the whole source text.  Use
4848         allocate_conversion_buffer, extend_conversion_buffer and
4849         free_conversion_buffer, not get_conversion_buffer.
4850         (encode_coding_string): Likewise.
4851         (init_coding): Function deleted.
4852         (init_coding_once): Delete code to initialize
4853         conversion_buffer_size.
4855         * emacs.c (main): Don't call init_coding.
4857         * msdos.c (IT_write_glyphs): Use a locally declared
4858         conversion_buffer.
4860         * term.c (write_glyphs): Use a locally declared conversion_buffer.
4861         (insert_glyphs): Likewise.
4863         * w32console.c (write_glyphs): Use a locally declared
4864         conversion_buffer.
4866 2000-08-15  Eli Zaretskii  <eliz@is.elta.co.il>
4868         * msdos.c (IT_update_begin): Don't crash if mouse_face_mouse_frame
4869         member of display_info is NULL.
4871 2000-08-15  Gerd Moellmann  <gerd@gnu.org>
4873         * alloc.c (compact_small_strings): Use safe_bcopy, add an
4874         assertion.
4876         * term.c (turn_off_face): Reset standout_mode when resetting
4877         appearances with capability `me'.
4878         (write_glyphs): Switch on inverse video before each face change.
4880 2000-08-14  Dave Love  <fx@gnu.org>
4882         * alloc.c [HAVE_UNISTD_H]: Include unistd.h; don't declare sbrk.
4883         [!HAVE_UNISTD_H]: Use POINTER_TYPE to declare sbrk.
4884         (lisp_free): Declare and make static.
4886         * window.c: Fix embedded comment.
4887         (syms_of_window): Fix doc string.
4889 2000-08-14  Gerd Moellmann  <gerd@gnu.org>
4891         * keymap.c (push_key_description): If C without modifiers is < 32, 
4892         make sure to print `C-' before `M-', like in the manual.
4894 2000-08-11  Gerd Moellmann  <gerd@gnu.org>
4896         * fns.c (hashfn_eq, hashfn_eql): Don't handle strings specially
4897         since they aren't relocated anymore.
4898         (sxhash_string): Make sure returned hash code fits in a Lisp
4899         integer.
4901         * xdisp.c (try_cursor_movement): Fix handling of cursor in
4902         partially visible line which is smaller than the window's
4903         height.
4905 2000-08-11  Kenichi Handa  <handa@etl.go.jp>
4907         * ccl.c (CCL_READ_CHAR): If source is multibyte, pay attention to
4908         the multibyte form of eight-bit-control characters. 
4909         (Fccl_execute_on_string): Initialize ccl->multibyte.
4911         * ccl.h (struct ccl_program): New member multibyte.
4913         * coding.c (ccl_coding_driver): Initialize ccl->multibyte.
4915 2000-08-11  Kenichi Handa  <handa@etl.go.jp>
4917         * regex.c (regex_compile) <normal_char>: Pay attention to
4918         multibyteness.
4919         (analyse_first) <exactn>: Setup fastmap correctly for
4920         eight-bit-control characters.
4922 2000-08-11  Kenichi Handa  <handa@etl.go.jp>
4924         * termhooks.h (enum event_kind): New member
4925         multibyte_char_keystroke.
4927         * keyboard.c (make_lispy_event): Handle the new event type
4928         multibyte_char_keystroke.
4930         * xterm.c: Include coding.h.
4931         (XTread_socket): Work around a bug of XmbLookupString.  If the
4932         input is from XIM, decode it according to the current locale.  In
4933         that case, generate multibyte_char_keystroke events.
4935 2000-08-11  Kenichi Handa  <handa@etl.go.jp>
4937         * xdisp.c (TRACE_MOVE) [GLYPH_DEBUG]: Delete the last semicolon.
4938         (TRACE_MOVE) [not GLYPH_DEBUG]: Define dummy.
4940 2000-08-10  Gerd Moellmann  <gerd@gnu.org>
4942         * xdisp.c (trace_move) [GLYPH_DEBUG]: New variable.
4943         (TRACE_MOVE) [GLYPH_DEBUG]: New macro.
4944         (move_it_in_display_line_to): Record iterator's ascent and descent
4945         before producing glyphs, and restore them when we know the glyph
4946         doesn't fit on the line.
4947         (move_it_to): Restructured so that it's easier to debug.  If
4948         moving to a vpos, and not moving to an x or character position,
4949         stop as soon as the specified vpos is reached; don't move further
4950         into that line because that might change the computed line height.
4951         (try_cursor_movement): New function, extracted from the cursor
4952         movement branch of redisplay_window.  If ending on a partially
4953         visible line, don't try to scroll if the cursor line is taller
4954         than the window.
4955         (redisplay_window): Use try_cursor_movement.
4957         * window.c (Fwindow_end): Rewritten to not use Fvertical_motion,
4958         because that function doesn't cope with variable-height lines.
4960         * xterm.c (x_draw_bar_cursor): If cursor is on an image, draw a
4961         box cursor because that's better visible for large images.
4962         
4963 2000-08-10  Miles Bader  <miles@gnu.org>
4965         * w32term.c (note_mouse_highlight): Update calls to overlays_at.
4967 2000-08-10  Gerd Moellmann  <gerd@gnu.org>
4969         * xdisp.c (Vmessages_buffer_name): New variable.
4970         (message_dolog): Use it.
4971         (syms_of_xdisp): Initialize it.
4973 2000-08-10  Eli Zaretskii  <eliz@is.elta.co.il>
4975         * msdos.c (IT_note_mouse_highlight): Update the calls to
4976         overlays_at.
4977         (toplevel) <kbd_buffer_store_event>: Remove prototype, it's
4978         redundant now that keyboard.h is included.
4980 2000-08-09  Eli Zaretskii  <eliz@is.elta.co.il>
4982         * keyboard.c (kbd_buffer_events_waiting): New function.
4984         * keyboard.h (kbd_buffer_events_waiting): Add prototype.
4986         * msdos.c: Include keyboard.h.
4987         (XMenuActivate): Empty no_event events from the event buffer.  If
4988         no events are left after that, call clear_input_pending.
4989         (mouse_clear_clicks): New function, code moved from mouse_init.
4990         (mouse_init, XMenuActivate): Call mouse_clear_clicks to force the
4991         mouse driver to ``forget'' any past clicks.
4993         * Makefile.in (msdos.o): Depend on keyboard.h.
4995 2000-08-09  Gerd Moellmann  <gerd@gnu.org>
4997         * lisp.h (input_pending): External declaration.
4999         * dispextern.h (Qredisplay_dont_pause): Declare extern.
5000         
5001         * xdisp.c (echo_area_display): Display thoroughly if input is
5002         pending.  Bind redisplay-dont-pause to t during the redisplay.
5003         in case input is pending.
5005         * dispnew.c (Qredisplay_dont_pause): New variable.
5006         (syms_of_display): Initialize and staticpro it.
5007         (update_frame_1): Don't interrupt the display for pending input if
5008         redisplay_dont_pause is set.
5009         
5010         * dispnew.c (mode_line_string): Declare parameter MODE_LINE_P.
5012         * xfaces.c (Ftty_suppress_bold_inverse_default_colors): Doc fix.
5014 2000-08-09  Miles Bader  <miles@lsi.nec.co.jp>
5016         * callproc.c (Fcall_process): Terminate the unwind-protect around
5017         the post-read-conversion of coding system.
5019         * buffer.c (overlays_at): Add CHANGE_REQ parameter.
5020         (Foverlays_at, Fnext_overlay_change, Fprevious_overlay_change): Use it.
5021         * buffer.h (overlays_at): Update prototype.
5022         * xdisp.c (next_overlay_change): Update call to overlays_at.
5023         * xfaces.c (face_at_buffer_position): Likewise.
5024         * textprop.c (Fget_char_property): Likewise.
5025         * xterm.c (note_mouse_highlight): Likewise.
5027         * minibuf.c (do_completion): Don't consider a simple change of
5028         case as `completion'.
5030 2000-08-08  Ken Raeburn  <raeburn@gnu.org>
5032         * keyboard.c (syms_of_keyboard): Initialize
5033         last_point_position_buffer.
5034         * undo.c (record_delete): Make sure last_point_position_buffer is
5035         a buffer before comparing pointers.
5037         * coding.h (decode_coding_string): Declare.
5039         * intervals.h (Fprevious_single_char_property_change): Declare.
5041         * textprop.c (Fprevious_single_char_property_change): Don't do
5042         arithmetic directly on lisp objects.
5044         * editfns.c (find_field): Use EQ, not ==, to compare Lisp
5045         objects.
5047         * keyboard.h (menu_item_eval_property): Declare.
5049         * xdisp.c (message_dolog): Save and protect string "*Messages*" to
5050         reuse as buffer name, instead of recreating (and discarding) every
5051         time a message is logged.
5052         (with_echo_area_buffer): Make callback arg A2 a lisp object.
5053         (current_message_1, truncate_message_1, set_message_1)
5054         (display_echo_area_1, resize_mini_window_1): Signatures changed.
5055         (current_message, truncate_echo_area, display_echo_area)
5056         (resize_echo_area_axactly): Changed calls.
5058         * coding.c (find_safe_codings): CHAR_TABLE_SET index must be a
5059         Lisp object.
5060         (Ffind_coding_systems_region_internal): First argument to Fappend
5061         must be an integer, not a Lisp object.
5063 2000-08-08  Kenichi Handa  <handa@etl.go.jp>
5065         * charset.c (Fchar_width): Doc fix.
5067 2000-08-08  Gerd Moellmann  <gerd@gnu.org>
5069         * charset.c (Fstring_width): Doc fix.
5071 2000-08-07  Gerd Moellmann  <gerd@gnu.org>
5073         * xdisp.c (start_display): When starting display on a continuation
5074         line, clear ascent and descent members of the iterator structure;
5075         the height of the continued line does not affect the height of the
5076         continuation line.
5077         (make_cursor_line_fully_visible): Do nothing if cursor is on a
5078         line taller than the window.
5079         (redisplay_window) <forced window start>: Handle case that the
5080         middle of the window is not found in any row.
5081         (dump_glyph_row): Show more information.
5082         (compute_line_metrics): Use MATRIX_FIRST_TEXT_ROW to determine the
5083         first text line in a glyph matrix.
5085         * xterm.c (x_draw_image_foreground): Avoid drawing outside
5086         of the clip area when image doesn't have a mask.
5088         * fns.c (sweep_weak_table): Fix survival conditions for
5089         key-or-value and key-and-value weakness.
5091         * .gdbinit (xhashtable): New command.
5093         * fns.c (sweep_weak_hash_tables): Fix the code taking unmarked
5094         tables out of the list of all weak hash tables.
5096         * xdisp.c (ensure_echo_area_buffers): If a buffer was killed, and
5097         a new buffer is created, make sure echo_area_buffer[] references
5098         the new buffer.
5100 2000-08-07  Eli Zaretskii  <eliz@is.elta.co.il>
5102         * msdos.c (Fmsdos_set_mouse_buttons): Add missing backslashes in
5103         the doc string.
5105 2000-08-07  Kenichi Handa  <handa@etl.go.jp>
5107         * syntax.c (skip_chars): Fix previous change.  Make the handling
5108         of unibyte string consistent with that of regex search.
5110 2000-08-05  Gerd Moellmann  <gerd@gnu.org>
5112         * xmenu.c (popup_get_selection): Use xfree instead of free.
5114         * fileio.c (Finsert_file_contents): Use xfree instead of free.
5116         * editfns.c (Ftranspose_regions): Use xfree instead of free.
5118         * callproc.c (child_setup): Use xfree instead of free.
5120         * sysdep.c (opendir, GetTempDirName, run_mac_command): Use xmalloc
5121         instead of malloc.
5122         (run_mac_command, closedir): Use `xfree' instead of `free'.
5124         * keymap.c (current_minor_maps): Use xmalloc instead of malloc.
5126         * eval.c (error): Use xfree instead of free.
5128         * xfaces.c, xfns.c, w32fns.c: Replace `illegal' with `invalid'.
5130         * fns.c: Replace `illegal' with `invalid'.
5131         (Fmake_hash_table, make_hash_table): Allow table size of 0.
5133 2000-08-05  Kenichi Handa  <handa@etl.go.jp>
5135         * syntax.c (skip_chars): Fix handling of multibyte<->unibyte
5136         conversion.
5138 2000-08-04  Noah Friedman  <friedman@splode.com>
5140         * fns.c (Fmake_hash_table): Add missing `\n\' to end of line in
5141         docstring.
5143 2000-08-04  Gerd Moellmann  <gerd@gnu.org>
5145         * syntax.c (skip_chars): Fix typo in error message.
5147 2000-08-04  Andreas Schwab  <schwab@suse.de>
5149         * m/ia64.h: Moved from s/ia64.h.
5151 2000-08-04  Kenichi Handa  <handa@etl.go.jp>
5153         * process.c (read_process_output): Big simplification.  Handle
5154         composition and post-read-conversion of coding system correctly.
5155         (send_process): Handle composition correctly.
5157         * callproc.c (Fcall_process): Handle post-read-conversion of
5158         coding system if any.
5160         * coding.c (decode_coding_iso2022): More strict check for handling
5161         single shifting.
5162         (coding_restore_composition): Pay attention to the case that
5163         cmp_data is not set properly (because of invalid code in the
5164         source text).
5165         (run_pre_post_conversion_on_str): Include text properties in the
5166         resulting string.
5167         (decode_coding_string): Set members of coding correctly.
5169 2000-08-03  Gerd Moellmann  <gerd@gnu.org>
5171         * s/ia64.h: New file.
5173         * widget.c (set_frame_size, update_wm_hints, EmacsFrameSetValues):
5174         Use NULL instead of 0 at the end of variable argument list of
5175         XtVaGetValues and XtVaSetValues, because 0 fails on systems where
5176         sizeof (int) < sizeof (void *).
5178         * xmenu.c (update_frame_menubar): Use NULL instead of 0 at the end
5179         of variable argument lists of XtVaGetValues and XtVaSetValues.
5181         * xfns.c (Fx_file_dialog): Use NULL instead of 0 at the end of
5182         variable argument lists of XtVaGetValues and XtVaSetValues.
5184 2000-08-02  Gerd Moellmann  <gerd@gnu.org>
5186         * alloc.c (lisp_malloc, lisp_free): Use size_t and POINTER_TYPE.
5187         (xrealloc, xmalloc): Use size_t.  Some callers adjusted.
5189         * lisp.h (Fsingle_key_description, xmalloc, xrealloc): Change
5190         prototype.
5192         * keyboard.c (read_char_minibuf_menu_prompt): Add new parameter
5193         in call to Fsingle_key_description.
5195         * keymap.c (Fsingle_key_description): Add parameter NO_ANGLES.
5196         Callers changed.
5198 2000-08-02  Colin Walters <walters@cis.ohio-state.edu>
5200         * window.c (display_buffer_reuse_frames): New variable.
5201         (Fdisplay_buffer): If display_buffer_reuse_frames is set, reuse
5202         frames displaying BUFFER.
5203         (syms_of_window): Define Lisp variable
5204         display-buffer-reuse-frames.
5206 2000-08-01  Miles Bader  <miles@gnu.org>
5208         * editfns.c (Fconstrain_to_field): Fix the conditions for deciding
5209         when to constrain NEW_POS (they were pretty screwed up before).
5211 2000-07-31  Eli Zaretskii  <eliz@is.elta.co.il>
5213         * msdos.c (run_msdos_command): Save and restore the master
5214         environment, for the case that child_setup signals an error.
5215         When mirroring slashes in DOS shell commands, don't fail when
5216         argv[2] has embedded blanks.
5217         (Fmsdos_set_mouse_buttons, mouse_setup_buttons): New functions.
5218         (syms_of_msdos): Defsubr Fmsdos_set_mouse_buttons.
5219         (dos_ttraw): Call mouse_setup_buttons.
5221         * callproc.c (child_setup) [MSDOS]: malloc pwd_var instead of
5222         using alloca; free it after run_msdos_command returns.
5224 2000-07-27  Dave Love  <fx@gnu.org>
5226         * s/irix6-5.h (IRIX_FORCE_32_BITS, LD_SWITCH_SYSTEM): Don't
5227         define.
5228         [_MIPS_SZLONG == 64]: Set up for 64-bit mode -- not currently
5229         working.
5231         * m/iris4d.h (XUINT, XSET, XUNMARK) [_LP64]: Don't define.
5233 2000-07-27  Eli Zaretskii  <eliz@is.elta.co.il>
5235         * editfns.c (lisp_time_argument): Fix last change.
5237 2000-07-27  Gerd Moellmann  <gerd@gnu.org>
5239         * fns.c (Fdelete): Make it work on vectors and strings in addition
5240         to lists.
5242         * fns.c (Qkey_or_value, Qkey_and_value): New variables.
5243         (syms_of_fns): Initialize new variables.
5244         (sweep_weak_table): Handle weakness `key-or-value' and
5245         `key-and-value'.
5246         (Fmake_hash_table): Recognize `key-and-value' and `key-or-value'
5247         weakness, with t meaning the same as `key-and-value'.
5249 2000-07-27  Kenichi Handa  <handa@etl.go.jp>
5251         * coding.h (struct coding_system): Member safe_charset deleted.
5253         * coding.c (Qsafe_charsets): This variable deleted.
5254         (Qsafe_chars, Vchar_coding_system_table, Qchar_coding_system): New
5255         variables.
5256         (coding_safe_chars): New function.
5257         (CODING_SAFE_CHAR_P): New macro.
5258         (CHARSET_OK): New arg C.  Call CODING_SAFE_CHAR_P instead of
5259         checking safe_charsets member of the coding system.  Caller
5260         changed.
5261         (detect_coding_iso2022): New local variable safe_chars.
5262         (DECODE_DESIGNATION): Call CODING_SAFE_CHAR_P instead of checking
5263         safe_charsets member of the coding system.
5264         (decode_coding_iso2022): New local variable safe_chars.
5265         (ENCODE_ISO_CHARACTER_DIMENSION1): Don't check unsafe chars here.
5266         (ENCODE_ISO_CHARACTER_DIMENSION2): Likewise.
5267         (ENCODE_ISO_CHARACTER): Arguments changed.  Caller changed.
5268         (ENCODE_UNSAFE_CHARACTER): New macro.
5269         (encode_coding_iso2022): New local variable safe_chars.  Check
5270         unsafe chars.
5271         (setup_coding_system): Delete the code to initialize
5272         coding->safe_charses
5273         (intersection, find_safe_codings): New functions.
5274         (Ffind_coding_systems_region_internal): New function.
5275         (syms_of_coding): Defsubr it.  Initialize Qsafe_chars,
5276         Qsafe_cding_system.  Make Vchar_coding_system_table a Lisp
5277         variable and initialize it.
5279         * fns.c (char_table_ref_and_index): New function.
5281         * lisp.h (char_table_ref_and_index): Add prototype.
5283 2000-07-26  Sam Steingold  <sds@gnu.org>
5285         * editfns.c (lisp_time_argument): Added third argument `usec'.
5286         (Ffloat_time): New built-in Lisp function.
5288 2000-07-26  Gerd Moellmann  <gerd@gnu.org>
5290         * dispextern.h (GLYPH_FROM_CHAR_GLYPH): Use CHARACTERBITS bits
5291         for the character code.
5293         * config.in (HAVE_SOUND): Define only for FreeBSD, NetBSD and
5294         GNU/Linux.
5296         * xmenu.c (menu_highlight_callback): Call show_help_echo directly
5297         if called for a popup menu.
5298         (xmenu_show): Store help string in widget values.
5300 2000-07-26  Dave Love  <fx@gnu.org>
5302         * syswait.h: Move some definitions.
5303         (HAVE_SYS_WAIT_H): Undef for HPUX7, Convex.
5304         [!HAVE_SYS_WAIT_H]: Define things unconditionally.   More
5305         perspicuous definitions.
5306         (WTERMSIG): Fix bit pattern used.
5308 2000-07-26  Kenichi Handa  <handa@etl.go.jp>
5310         * print.c (print_object): If vector printing is truncated, print
5311         "..." to indicate it as well as the case of list printing.
5313 2000-07-25  Gerd Moellmann  <gerd@gnu.org>
5315         * xdisp.c (next_element_from_display_vector): Improve comments.
5317         * lisp.h (GLYPH_MASK_CHAR, GLYPH_MASK_FACE): Use 19 bits
5318         for the character code, and the rest for the face id as in 20.x.
5319         (FAST_GLYPH_FACE, FAST_MAKE_GLYPH): Changed accordingly.
5321         * window.c (window_display_table): Cleaned up.
5323         * syntax.c (Fforward_word): Add last arg nil in call of
5324         Fconstrain_to_field.
5326 2000-07-25  Eli Zaretskii  <eliz@is.elta.co.il>
5328         * fileio.c (Frename_file) [DOS_NT]: If the file names are
5329         identical but for the letter-case, don't call
5330         barf_or_query_if_file_exists.
5332 2000-07-25  Miles Bader  <miles@gnu.org>
5334         * editfns.c (find_field): Honor special `boundary' fields.
5335         (Qboundary): New variables.
5336         (syms_of_editfns): Initialize Qboundary.
5337         (Fconstrain_to_field): Add the INHIBIT-CAPTURE-PROPERTY argument.
5338         Use scan_buffer instead of find_before_next_newline, because it
5339         allows us to detect the boundary case where there's a newline at
5340         the search limit.
5341         * lisp.h (Fconstrain_to_field): Update external declaration.
5343 2000-07-24  Gerd Moellmann  <gerd@gnu.org>
5345         * print.c (temp_output_buffer_setup): Don't call1 Vrun_hooks
5346         if that is nil.
5348 2000-07-24  Dave Love  <fx@gnu.org>
5350         * s/sunos4-0.h, s/sol2.h:
5351         (LIBS_TERMCAP): Move from m/sparc.h.
5353         * m/sparc.h (TERMINFO): Moved to system files (probably only
5354         relevant for sunos4 judging by its vintage).
5355         (BITS_PER_LONG, BITS_PER_EMACS_INT, _LP64): Define conditional on
5356         __arch64__.
5358 2000-07-24  Eli Zaretskii  <eliz@is.elta.co.il>
5360         * xmenu.c (keymap_panes): Pass the keymap's prompt as the pane
5361         name to single_keymap_panes.
5363 2000-07-24  Andreas Schwab  <schwab@suse.de>
5365         * fns.c (Fmakehash): Pass Qeql to Fmake_hash_table if TEST is nil.
5367 2000-07-24  Gerd Moellmann  <gerd@gnu.org>
5369         * xdisp.c (with_echo_area_buffer): Take additional EMACS_INT
5370         parameters instead of using int parameters.  Expect FN to accept
5371         EMACS_INT parameters.
5372         (display_echo_area, resize_echo_area_axactly, current_message)
5373         (truncate_echo_area, set_message_1): Call with_echo_area_buffer
5374         with new argument list.
5375         (resize_mini_window_1): New callback function.
5376         (current_message_1, truncate_message_1, set_message_1): Change
5377         parameter lists to the new format expected by
5378         with_echo_area_buffer.
5380 2000-07-24  Kenichi Handa  <handa@etl.go.jp>
5382         * fontset.c (fontset_ref): Remove INLINE declaration.
5383         (fontset_ref_via_base): Likewise.
5384         (Fset_fontset_font): Convert FAMILY and REGISTRY specifications
5385         to downcase.
5387 2000-07-23  Eli Zaretskii  <eliz@is.elta.co.il>
5389         * msdos.c (IT_note_mouse_highlight): Process overlays in the
5390         correct order of priority.  If help echo was found in an overlay,
5391         use that overlay as the object in which the help echo was found.
5393 2000-07-22  Miles Bader  <miles@gnu.org>
5395         * textprop.c (Fprevious_single_char_property_change): The initial
5396         property value should be from the position preceding POSITION, not
5397         following it.
5399 2000-07-22  Eli Zaretskii  <eliz@is.elta.co.il>
5401         * coding.c (syms_of_coding): Doc fix for
5402         inhibit-iso-escape-detection.
5404 2000-07-21  Gerd Moellmann  <gerd@gnu.org>
5406         * xterm.c (note_mouse_highlight): Process overlays in the right
5407         order of priority.
5409         * keyboard.c (show_help_echo, gen_help_event): Extend comments.
5411         * xterm.c (note_mouse_highlight): If help-echo was found in an
5412         overlay, use that overlay as the object in which the help was
5413         found.
5415         * window.c (foreach_window_1): Fix typo reversing an if-condition.
5417         * window.c (foreach_window): Instead of a fake variable argument
5418         list, take one USER_DATA argument.
5419         (foreach_window_1): Likewise, and call callback functions with two
5420         args, the window and USER_DATA.
5421         (struct check_window_data): New struct.
5422         (check_window_containing): Use it.
5423         (window_from_coordinates): Set up a struct check_window_data for
5424         foreach_window.
5425         (add_window_to_list, freeze_window_start): Change parameters
5426         according to new calling convention.
5428         * window.h (foreach_window): Change prototype.
5430         * buffer.c (Fprevious_overlay_change): Avoid memory leak.
5432 2000-07-21  Eli Zaretskii  <eliz@is.elta.co.il>
5434         * xmenu.c (menu_help_callback): Call show_help_echo with
5435         additional arguments OBJECT and POS.
5437 2000-07-21  Kenichi Handa  <handa@etl.go.jp>
5439         * data.c (Faset): Allow storing any multibyte character in a
5440         string.  Convert unibyte string to multibyte if necessary.
5442         * xfns.c (x_encode_text): New function.
5443         (x_set_name): Use x_encode_text.
5444         (x_set_title): Likewise.
5446         * xselect.c (lisp_data_to_selection_data): Use x_encode_text.
5448         * xterm.h (x_encode_text): Add prototype.
5450 2000-07-20  Dave Love  <fx@gnu.org>
5452         * ccl.c (Fccl_execute_on_string): Don't check xmalloc return.  Use
5453         xfree, not free.
5455 2000-07-20  Eli Zaretskii  <eliz@is.elta.co.il>
5457         * msdos.c (help_echo_window): New variable.
5458         (syms_of_msdos): Initialize and staticpro it.
5459         (IT_note_mode_line_highlight): Set help_echo_window.
5460         (IT_note_mouse_highlight): Ditto.
5461         (dos_rawgetc): Store help_echo_window in the second event produced
5462         for HELP_EVENTs.
5464         * msdos.c (IT_note_mode_line_highlight, IT_note_mouse_highlight):
5465         Record the object that generated the help echo and the position of
5466         that object in help_echo_object and help_echo_pos.  Record that
5467         some glyphs in a row are displayed in mouse-face.
5468         (IT_update_begin): Don't clear mouse highlight unless one of the
5469         enabled glyph rows is marked as being displayed in mouse-face.
5470         (dos_rawgetc): Generate 2 events for HELP_EVENT.  Pass the object
5471         and position recorded in help_echo_object and help_echo_pos to the
5472         event queue.
5473         (IT_menu_display): Accept a new argument PN: the pane number of
5474         the current menu pane.  Record the pane number and the item
5475         number of the item which has associated help string.
5476         (XMenuActivate): Update the prototype for help_callback in
5477         function declaration.  Call IT_menu_display with the current menu
5478         pane number as an additional argument.  Call help_callback with
5479         two additional arguments: the pane number and the item number of
5480         the menu item associated with the help text.
5481         (help_echo_object, help_echo_pos): New variables.
5482         (syms_of_msdos): Initialize them and staticpro help_echo_object.
5484         * msdos.h (XMenuActivate): Update prototype.
5486 2000-07-19  Gerd Moellmann  <gerd@gnu.org>
5488         * xdisp.c (with_echo_area_buffer): Call FN with more arguments.
5489         Add some more prototypes.
5491         * xterm.c, xterm.h: Add some more prototypes.
5493         * lisp.h (Fnext_single_char_property_change): Add prototype.
5495         * dispnew.c (direct_output_for_insert): Remove confusing
5496         outer local variable mouse_face_overwritten_p.
5497         (glyph_row_slice_p): Put in #ifdef GLYPH_DEBUG.
5499         * alloc.c (allocate_string_data): Don't copy old string contents.
5501 2000-07-19  Kenichi Handa  <handa@etl.go.jp>
5503         * coding.c (code_convert_region): Delete text properties before
5504         shrinking the conversion region.
5506 2000-07-18  Gerd Moellmann  <gerd@gnu.org>
5508         * dispnew.c (update_text_area): Write the whole row if it
5509         has mouse-face in it.
5511         * xfaces.c (face-alternative-font-family-alist): Remove
5512         DEFVAR_LISP; staticpro instead.
5514         * xmenu.c (menu_help_callback): Call show_help_echo with
5515         new arguments.
5517         * keyboard.c (show_help_echo): Add parameter WINDOW.
5518         (read_char): Call show_help_echo with window extracted from Lisp
5519         help event.
5520         (gen_help_event): Add parameter WINDOW.
5522         * keyboard.h (show_help_echo, gen_help_event): Change prototypes.
5524         * xterm.c (help_echo_window): New variable.
5525         (note_mouse_highlight, note_tool_bar_highlight): Set
5526         help_echo_window.
5527         (XTread_socket): Pass help_echo_window to gen_help_event.
5528         (syms_of_xterm): Initialize and staticpro help_echo_window.
5530 2000-07-18  Dave Love  <fx@gnu.org>
5532         * Makefile.in: Fix dependencies of blockinput.h on atimer.h,
5533         systime.h.
5535 2000-07-18  Gerd Moellmann  <gerd@gnu.org>
5537         * alloc.c (allocate_string_data): If string had already data
5538         assigned, copy old contents to new string data.
5540         * coding.c (syms_of_coding): Fix typo in spelling of variable
5541         `inhibit-iso-escape-detection'.
5543         * alloca.c (free) [emacs && EMACS_FREE]: Define as EMACS_FREE.
5545         * Makefile.in: Add dependencies on dispextern.h.
5546         (alloca.o): Don't define malloc and define EMACS_FREE instead of
5547         `free'; both can conflict with system header files.
5549 2000-07-18  Kenichi Handa  <handa@etl.go.jp>
5551         * charset.h (MAKE_CHAR): Return reasonable code even if CHARSET is
5552         undefined.
5554 2000-07-18  Dave Love  <fx@gnu.org>
5556         * window.c (Fwindow_list): Declare arg `window'.
5558 2000-07-18  Kenichi Handa  <handa@etl.go.jp>
5560         * coding.c (setup_coding_system): Don't override the explicitly
5561         specified designations.
5563 2000-07-15  Miles Bader  <miles@gnu.org>
5565         * editfns.c (char_property_eq, char_property_stickiness): Renamed
5566         from `text_property_eq' and `text_property_stickiness', respectively.
5567         (find_field, Fconstrain_to_field, char_property_eq)
5568         (char_property_stickiness): Changed to call char-property functions
5569         instead of text-property-only ones.
5571         * textprop.c (Fnext_single_char_property_change): Made a subr (was
5572         `next_single_char_property_change').  Do more error checking, and
5573         cleanup limit behavior.
5574         (Fprevious_single_char_property_change): New function.
5575         (syms_of_textprop): Initialize new subrs.
5577         * xdisp.c (display_prop_end, invisible_text_between_p):
5578         Call Fnext_single_char_property_change instead of
5579         next_single_char_property_change.
5581 2000-07-15  Jason Rumney  <jasonr@gnu.org>
5583         * w32menu.c (w32_menu_show): Call free_menubar_widget_value_tree
5584         after menu is finished with.
5585         (add_menu_item): Only consider wv->title as a menu title.
5586         (w32_menu_display_help): Add OBJECT and POS to show_help_echo.
5588         * w32fns.c (w32_wnd_proc) [WM_DRAW_ITEM]: Do not try to draw a
5589         null title.
5590         (FONT_REGEXP): Remove unused macro, and its sub-components.
5591         (syms_of_w32fns): Replace underscore in w32-enable-synthesized-fonts.
5593         * w32term.c (help_echo_object, help_echo_pos): New variables.
5594         (note_mode_line_highlight): Store additional information about the
5595         help-echo in help_echo_object and help_echo_pos.  Check both
5596         `local-map' and `keymap' properties for changing the cursor
5597         (note_mouse_highlight): Store additional information about the
5598         help-echo in help_echo_object and help_echo_pos.
5599         (note_tool_bar_highlight): Set help_echo_object to nil and
5600         help_echo_pos to -1.
5601         (w32_read_socket): Use gen_help_event instead of filling
5602         input_events manually.
5603         (syms_of_w32term): Staticpro help_echo_object.
5604         (x_update_window_end): Add parameter MOUSE_FACE_OVERWRITTEN_P. If
5605         set, arrange for a mouse-highlight redisplay in
5606         XTframe_up_to_date.
5607         (x_clear_mouse_face): New function.
5608         (w32_redisplay_interface): Add pointer to x_clear_mouse_face.
5609         (x_update_window_begin): No need to turn off the mouse
5610         highlight here.
5611         (show_mouse_face): Set the mouse_face_p flag of glyph rows
5612         depending on whether they contain glyphs highlighted in
5613         mouse-face.
5614         (x_fill_stretch_glyph_string): Consume runs of stretch
5615         glyphs instead of a single one.
5616         (BUILD_STRETCH_GLYPH_STRING): Call x_fill_stretch_glyph_string
5617         with new argument list.
5618         (x_set_glyph_string_gc): Make sure the face's GC is valid.
5619         (x_append_glyph, x_append_composite_glyph)
5620         (x_produce_image_glyph, x_append_stretch_glyph): Accomodate to
5621         changes in struct glyph starting 1999-12-27. See comments for
5622         xterm.c on 2000-07-05.
5624 2000-07-14  Sam Steingold  <sds@gnu.org>
5626         * xfaces.c (realize_x_face): Fix the last patch:
5627         check `default_face' before dereferencing.
5629 2000-07-14  Dave Love  <fx@gnu.org>
5631         * syntax.c (back_comment): Add null default in switch (for pcc).
5633 2000-07-14  Kenichi Handa  <handa@etl.go.jp>
5635         * xfaces.c (realize_x_face): Make fontset using the base of the
5636         default_face's fontset, not using the default fontset.
5638         * coding.c (inhibit_iso_escape_detection): New variable.
5639         (syms_of_coding): Make it a Lisp variable.
5640         (detect_coding_iso2022): If inhibit_iso_escape_detection is
5641         nonzero, ignore ISO2022's escape sequence.
5643 2000-07-14  Gerd Moellmann  <gerd@gnu.org>
5645         * alloca.c (malloc) [emacs]: Define as xmalloc.
5647         * xfns.c (Fx_show_tip): If frame parameters contain a position,
5648         use that instead of the mouse position.  Add parameters DX and DY.
5650         * dispextern.h (Fx_show_tip): Adjust number of parameters
5651         in prototype.
5653         * keyboard.c (show_help_echo): Add parameters OBJECT and POS.
5654         if HELP is a function, call it with OBJECT and POS as parameters
5655         to get the help to display.
5656         (gen_help_event, kbd_buffer_store_help_event): New functions.
5657         (kbd_buffer_get_event): Construct the Lisp help-event differently.
5658         (read_char): Call show_help_echo with new parameters.
5660         * keyboard.h (gen_help_event, kbd_buffer_store_help_event):
5661         Add prototypes.
5663         * xterm.c (help_echo_object, help_echo_pos): New variables.
5664         (note_mode_line_highlight): Store additional information about the
5665         help-echo in help_echo_object and help_echo_pos.  Check both
5666         `local-map' and `keymap' properties for changing the cursor
5667         (note_mouse_highlight): Store additional information about the
5668         help-echo in help_echo_object and help_echo_pos.
5669         (note_tool_bar_highlight): Set help_echo_object to nil and
5670         help_echo_pos to -1.
5671         (XTread_socket): Use gen_help_event instead of filling
5672         input_events manually.
5673         (syms_of_xterm): Staticpro help_echo_object.
5675         * xmenu.c (menu_highlight_callback): Use
5676         kbd_buffer_store_help_event instead of setting up and input_event
5677         structure manually.
5679         * xdisp.c (eval_form): GCPRO argument sexpr.
5680         (call_function): New function.
5681         (handle_single_display_prop): Use call_function and FUNCTIONP
5682         instead of checking whether if font_height is a symbol and
5683         using eval_form.
5685         * eval.c (internal_condition_case_2): New function.
5687         * lisp.h (FUNCTIONP): New macro.
5688         (internal_condition_case_2, call_function): Add prototypes.
5690         * xterm.c (construct_mouse_click, x_scroll_bar_to_input_event)
5691         (x_scroll_bar_handle_click, SET_SAVED_MENU_EVENT, XTread_socket):
5692         Always set `arg' member of input_events.
5693         (construct_menu_click): Unused function removed.
5695         * msdos.c (dos_rawgetc): Always set `arg' member of input_events.
5697         * w32term.c (construct_mouse_click, construct_mouse_wheel)
5698         (construct_drag_n_drop, x_scroll_bar_handle_click)
5699         (w32_read_socket): Always set `arg' member of input_events.
5701         * keyboard.c (show_help_echo): Use eval_form.  Add comment.
5703         * lisp.h (eval_form): Add prototype.
5705         * xdisp.c (eval_form): Make it externally visible.
5707 2000-07-13  Gerd Moellmann  <gerd@gnu.org>
5709         * xterm.c (x_handle_tool_bar_click): Store the frame in the
5710         frame_or_window slot of TOOL_BAR_EVENT input events instead of
5711         consing.  For prefix events, store the frame in the `arg' slot of
5712         the event, otherwise store the key there.
5713         (XTread_socket): Instead of consing, use the frame_or_window slot
5714         of HELP_EVENTs for the frame, and the `arg' slot for the help
5715         string.
5717         * xmenu.c (menu_highlight_callback): Store help string in the
5718         `arg' member of the input event; don't cons.
5719         (menubar_selection_callback): Use the `arg' slot of input events
5720         to queue additional information, instead of consing.
5722         * msdos.c (dos_rawgetc): Adapt to change of HELP_EVENTs.
5724         * w32term.c (w32_handle_tool_bar_click): Adapt to changes in
5725         TOOL_BAR_EVENTs.
5726         (w32_read_socket): Adapt to changes in HELP_EVENTs.
5728         * w32menu.c (menubar_selection_callback): Use the `arg' slot of
5729         input events to queue additional information, instead of consing.
5731         * keyboard.c (kbd_buffer_gcpro): Renamed from
5732         kbd_buffer_frame_or_window.  Now used for all Lisp objects
5733         referenced from the input queue.
5734         (kbd_buffer_store_event): Always use structure assignment for
5735         copying input events.  Record all Lisp objects referenced from
5736         events in kbd_buffer_gcpro.
5737         (kbd_buffer_get_event): Construct Lisp `help-echo' events
5738         differently from input events.  Test for prefix menu_bar_events
5739         and TOOL_BAR_EVENTs differently.  Reset all slots used by an input
5740         event in kbd_buffer_gcpro to nil.
5741         (make_lispy_event) <TOOL_BAR_EVENT>: Treat an input event whose
5742         frame_or_window is equal to its arg member as prefix events.
5743         (stuff_buffered_input): Reset all slots in kbd_buffer_gcpro
5744         used by an input event to nil.
5745         (init_keyboard): Use two times the size of the input queue
5746         for kbd_buffer_gcpro.
5747         (syms_of_keyboard): Likewise.
5749         * emacs.c (handle_USR2_signal, handle_USR1_signal): Use
5750         USER_SIGNAL_EVENT.
5752         * termhooks.h (struct input_event): Add member `arg'.
5753         (MENU_BAR_EVENT): Renamed from menu_bar_event.
5754         (USER_SIGNAL_EVENT): Renamed from user_signal.
5756         * xfaces.c (ASET): Remove definition.
5758         * lisp.h (AREF, ASET, ASIZE): New macros.
5760         * fontset.c (AREF, ASIZE): Remove definitions.
5762         * fns.c (AREF): Remove definition.
5764         * composite.c (AREF): Remove definition.
5766 2000-07-12  Gerd Moellmann  <gerd@gnu.org>
5768         * dispnew.c (redraw_overlapped_rows): Add missing local.
5769         (scrolling_window): Remove debug code.
5771         * xdisp.c (try_window_reusing_current_matrix, try_window_id):
5772         Before scrolling, turn off a mouse-highlight in the window
5773         being scrolled.
5775         * xterm.c (x_update_window_end): Add parameter
5776         MOUSE_FACE_OVERWRITTEN_P.  If set, arrange for a mouse-highlight
5777         redisplay in XTframe_up_to_date.
5778         (x_clear_mouse_face): New function.
5779         (x_redisplay_interface): Add pointer to x_clear_mouse_face.
5781         * dispnew.c (make_current): Preserve the mouse_face_p flag of the
5782         current glyph row.
5783         (update_window_line): Add parameter MOUSE_FACE_OVERWRITTEN_P.  Set
5784         it when any row is written to that contains glyphs highlighted in
5785         mouse-face.
5786         (update_window): Call the window update end hook with new
5787         parameter MOUSE_FACE_OVERWRITTEN_P.
5788         (direct_output_for_insert): Give up if row contains mouse-face.
5790         * dispextern.h (struct redisplay_interface): Add parameter
5791         MOUSE_FACE_OVERWRITTEN_P to update_window_end_hook function.
5792         (clear_mouse_face): New function pointer member.
5794 2000-07-11  Stefan Monnier  <monnier@cs.yale.edu>
5796         * syntax.c (back_comment): Use one switch rather than a few `if's.
5797         Obey open_paren_in_column_0_is_defun_start.
5798         When reverting to the `slow' method, try to nicely handle the case
5799         of nested comments by checking that the comment-starter we found
5800         does indeed match the comment-ender.
5801         (scan_sexps_forward, scan_sexps_forward):
5802         Ignore excessive opening parenthesis rather than throwing an error.
5804 2000-07-11  Gerd Moellmann  <gerd@gnu.org>
5806         * doc.c (Fsubstitute_command_keys): Handle case that a GC
5807         in Fwhere_is_internal or get_keymap_1 relocates string contents.
5809         * dispnew.c (direct_output_forward_char): Give up if currently
5810         displaying a message instead of the minibuffer contents.
5812         * xterm.c (x_update_window_begin): No need to turn off the mouse
5813         highlight here.
5814         (show_mouse_face): Set the mouse_face_p flag of glyph rows
5815         depending on whether they contain glyphs highlighted in
5816         mouse-face.
5818         * dispnew.c (row_equal_p): Add parameter MOUSE_FACE_P.  If set,
5819         compare the mouse_face_p flags of both rows.
5821         * dispextern.h (struct glyph_row): Add flag mouse_face_p.
5823 2000-07-11  Eli Zaretskii  <eliz@is.elta.co.il>
5825         * keyboard.c (show_help_echo): Accept additional parameter
5826         ok_to_overwrite_keystroke_echo.
5827         (read_char): Call show_help_echo with a zero
5828         ok_to_overwrite_keystroke_echo argument.
5829         * keyboard.h (show_help_echo): Update prototype of
5830         show_help_echo.
5831         * xmenu.c (menu_help_callback): Call show_help_echo with non-zero
5832         ok_to_overwrite_keystroke_echo argument.
5833         * w32menu.c (w32_menu_display_help): Call show_help_echo with
5834         non-zero ok_to_overwrite_keystroke_echo argument.
5836 2000-07-10  Gerd Moellmann  <gerd@gnu.org>
5838         * xdisp.c (try_window_id): If changes are all below what is
5839         displayed in the window, and point is in the window, we still
5840         might have to find point on the display.
5842         * xterm.c (x_fill_stretch_glyph_string): Consume runs of stretch
5843         glyphs instead of a single one.
5844         (BUILD_STRETCH_GLYPH_STRING): Call x_fill_stretch_glyph_string
5845         with new argument list.
5846         (x_set_glyph_string_gc): Make sure the face's GC is valid.
5848         * keymap.c (get_keymap_1): Add comment that this function can GC.
5849         (where_is_internal_2, where_is_internal_1): Add GCPROs, add
5850         comment that functions can GC.
5851         (Fset_keymap_parent): GCPRO arg KEYMAP.
5853 2000-07-10  Eli Zaretskii  <eliz@is.elta.co.il>
5855         * msdos.c (XMenuActivate): After exiting the menu, restore the
5856         echo area message and erase it.
5858 2000-07-10  Kenichi Handa  <handa@etl.go.jp>
5860         * fontset.c (Ffontset_info): Make the return value more compatible
5861         with that of Emacs 20.
5863 2000-07-07  Gerd Moellmann  <gerd@gnu.org>
5865         * eval.c (Fsignal): Handle case that backtrace_list is null.
5867 2000-07-07  Kenichi Handa  <handa@etl.go.jp>
5869         * ccl.c (Fccl_execute): Typo fixed.
5871 2000-07-06  Gerd Moellmann  <gerd@gnu.org>
5873         * window.c (window_loop): Add missing gcpro1 local variable.
5875         * window.c (Fwindow_list): Reverse list at the end.
5876         (candidate_window_p): Add parameter OWINDOW.  ALL_FRAMES nil
5877         means allow windows on OWINDOW's frame, only.
5878         (window_loop): Simplified; use Fwindow_list.
5880         * Makefile.in (TAGS-LISP): Don't pass `$(lispsource)' to make.
5882 2000-07-05  Gerd Moellmann  <gerd@gnu.org>
5884         * xterm.c (XTread_socket): Increment handling_signal at the start,
5885         decrement it at the end.
5887         * eval.c (handling_signal): New variable.
5888         (Fsignal): Abort if handling_signal is non-zero.
5890         * lisp.h (handling_signal): External declaration.
5892         * s/freebsd.h (WAITTYPE, WRETCODE): Put in #if 0.
5894 2000-07-05  Ken Raeburn  <raeburn@gnu.org>
5896         Sound support for NetBSD through "Linux emulation" support:
5897         * config.in (HAVE_SOUNDCARD_H): Undef.
5898         (HAVE_SOUND): Define if HAVE_SOUNDCARD_H.
5899         * Makefile.in (LIBSOUND): New variable.
5900         (LIBES): Include it.
5901         * sound.c [HAVE_SOUNDCARD_H]: Include <sys/ioctl.h> and
5902         <soundcard.h>.
5903         (DEFAULT_SOUND_DEVICE): Define to "/dev/dsp" if not defined
5904         elsewhere.
5905         (vox_open): Use DEFAULT_SOUND_DEVICE.
5906         * s/netbsd.h (DEFAULT_SOUND_DEVICE): Define to /dev/audio.
5908 2000-07-05  Gerd Moellmann  <gerd@gnu.org>
5910         * print.c (print_error_message): If Vsignaling_function is set,
5911         show it in *Messages*.
5913         * lisp.h (Vsignaling_function): External declaration.
5915         * eval.c (Vsignaling_function): New variable.
5916         (Fsignal): Compute it.
5917         (syms_of_eval): Staticpro it.
5919 2000-07-05  Dave Love  <fx@gnu.org>
5921         * syswait.h: Use the autoconf recommended approach.  Old code
5922         #if'd out in case we need to revert.
5924         * config.in (HAVE_SYS_WAIT_H): Added.
5926 2000-07-05  Andrew Innes  <andrewi@gnu.org>
5928         * vm-limit.c (check_memory_limits) [REL_ALLOC]: Use real_morecore
5929         when non-NULL instead of __morecore, to take account of buffer
5930         memory.  This also solves a problem with spurious memory warnings
5931         on Windows.
5933         * ralloc.c: Make real_morecore non-static.
5935         * eval.c (internal_condition_case): Comment out abort if
5936         interrupt_input_blocked is not zero.
5938         * makefile.nt: Add support for `bootstrap' and related targets.
5939         Include minimal debug info in emacs.exe in release build.
5940         Remove all dependencies on lisp.h, and fixup some others.
5942         * w32.c (init_environment): Install code from 20.7 for providing
5943         default values for environment variables, based on the
5944         executable's own location.
5945         (map_w32_filename): Handle filenames that are longer than
5946         MAX_PATH.
5947         (sys_socket): Install socket inheritance bug fix from 20.7.
5949         * alloca.c [emacs]: Include lisp.h (needed by atimer.h included
5950         here via blockinput.h).
5952 2000-07-05  Stefan Monnier  <monnier@cs.yale.edu>
5954         * w32menu.c (w32_menu_display_help):
5955         * xmenu.c (menu_help_callback): Use show_help_echo.
5957         * keyboard.h (show_help_echo): Declare.
5959         * keyboard.c (show_help_echo): New function, extracted from read_char.
5960         Feval its `msg' argument if it's a cons cell.
5961         (read_char): Use it.
5962         (follow_key): Pass `autoload' to get_keyelt.
5964         * xterm.c (note_mode_line_highlight, note_mouse_highlight)
5965         (note_tool_bar_highlight, XTread_socket):
5966         * msdos.c (IT_note_mode_line_highlight, IT_note_mouse_highlight)
5967         (dos_rawgetc):
5968         * w32term.c (note_mode_line_highlight, note_mouse_highlight)
5969         (note_tool_bar_highlight, w32_read_socket):
5970         Do not gratuitously ignore non-string `help-echo' properties.
5972 2000-07-05  Gerd Moellmann  <gerd@gnu.org>
5974         * eval.c (Feval): Put check for interrupt_input_block in #if 0.
5976         * window.c (delete_all_subwindows): Reset Vwindow_list.
5978         * xterm.c (x_append_glyph, x_append_composite_glyph)
5979         (x_produce_image_glyph, x_append_stretch_glyph): Accomodate to
5980         changes in struct glyph starting 1999-12-27.  Some bit-fields of
5981         struct glyph were not set, which made glyphs unequal when compared
5982         with GLYPH_EQUAL_P.  Redisplay outputs such glyphs, and flickering
5983         effects were the result.  This also depended on the contents of
5984         memory returned by xmalloc.  If flickering happens again, activate
5985         the code in clear_glyph_row that's in #if 0.  If the flickering is
5986         gone with that, chances are that it is caused by something
5987         similar.
5989         * dispnew.c (clear_glyph_row): Add debug code in #if 0.
5991         * dispextern.h: Add some comments.
5993         * window.c (add_window_to_list): Add parameter LIST.
5994         (window_list): Order list so that, for each frame, windows are
5995         in canonical order, and so that frames appear in the list in
5996         the order given by Vframe_list.
5997         (next_window): Reverse the handling of NEXT_P.
5999 2000-07-04  Gerd Moellmann  <gerd@gnu.org>
6001         * window.c (Vwindow_list): New variable.
6002         (make_window, delete_window): Set Vwindow_list to nil.
6003         (check_window_containing): New function.
6004         (window_from_coordinates): Rewritten.
6005         (add_window_to_list, window_list, candidate_window_p)
6006         (decode_next_window_args, next_window): New functions.
6007         (Fnext_window, Fprevious_window): Rewritten in terms of
6008         next_window.
6009         (Fwindow_list): New function.
6010         (Fother_window): Cleaned up.
6011         (foreach_window): Add a longer "variable argument list".  Let
6012         callback function return 0 to indicate that cycling over windows
6013         should stop.
6014         (foreach_window_1): Likewise.
6015         (freeze_window_start): Return int.
6016         (init_window): New function.
6017         (syms_of_window): Staticpro Vwindow_list and defsubr Swindow_list.
6019         * emacs.c (handle_USR1_signal, handle_USR2_signal) Clear
6020         input_event with bzero.
6021         (main): Call init_window.
6023         * keymap.c (get_keyelt): Temporarily inhibit GC while evaluating
6024         a menu filter.
6026 2000-07-04  Kenichi Handa  <handa@etl.go.jp>
6028         * composite.h (make_composition_value_copy): Extern it.
6030         * composite.c (make_composition_value_copy): New function.
6032         * editfns.c (Fformat): While copying text properties, make each
6033         composition property value a copy.
6035         * fns.c (concat): While copying text properties, make each
6036         composition property value a copy.
6038 2000-07-03  Gerd Moellmann  <gerd@gnu.org>
6040         * m/macppc.h (LINKER, LD_SWITCH_MACHINE) [LINUX]: Define.
6042         * fns.c (sweep_weak_table): Mark only objects that are not
6043         marked already.
6045         * frame.c (next_frame, prev_frame): If MINIBUF is a window,
6046         include those frames as candidates which have their focus
6047         redirected to the minibuffer frame.
6049 2000-07-03  Stefan Monnier  <monnier@cs.yale.edu>
6051         * fns.c (Fputhash): Return `value' rather than nil.
6053 2000-06-30  Gerd Moellmann  <gerd@gnu.org>
6055         * frame.c (next_frame): Don't check focus redirection in case
6056         MINIBUF is a window.  Doing so excludes frames using MINIBUF
6057         unless their focus is redirected, which contradicts the
6058         specification of next-frame, and leads to infinite loops in
6059         certain situations when cycling through windows with next-window.
6061 2000-06-30  Kenichi Handa  <handa@etl.go.jp>
6063         * coding.c (code_convert_region): Even if the length of text is
6064         zero, try to convert it if coding->type is coding_type_ccl.
6065         (decode_coding_string, encode_coding_string): Likewise.
6067 2000-06-28  Gerd Moellmann  <gerd@gnu.org>
6069         * xdisp.c (try_window_reusing_current_matrix): Don't try to reuse
6070         the display if windows_or_buffers_changed.
6072         * dispnew.c (struct row_entry): New structure.
6073         (row_entry_pool, row_entry_pool_size, row_entry_idx, row_table)
6074         (row_table_size, old_lines, new_lines, old_lines_size)
6075         (new_lines_size, run_pool, runs_size, runs): New variables.
6076         (add_row_entry): New function.
6077         (scrolling_window): Use data structures allocated with xmalloc and
6078         held in global variables, instead of allocating them with alloca and
6079         holding them in local variables.  Use a larger hash table whose
6080         size depends on glyph matrix sizes.  Don't use bzero to clear the
6081         hash table; instead, clear used slots only.
6083         * fns.c (next_almost_prime): Make it externally visible.
6085         * lisp.h (next_almost_prime): Add prototype.
6087         * s/isc4-0.h (sigunblock): Define.
6089         * s/sco5.h (sigunblock): Define.
6091 2000-06-27  Dave Love  <fx@gnu.org>
6093         * s/osf1.h (C_SWITCH_SYSTEM, LIBS_SYSTEM): Revert last change
6094         (moved to osf5-0.h).
6095         [!NOT_C_CODE]: Protect string.h stuff.
6097         * s/osf5-0.h (C_SWITCH_SYSTEM, WAIT_USE_INT, SYS_SIGLIST_DECLARED)
6098         (sys_siglist, NSIG): Definitions moved here from osf1.h.
6100 2000-06-27  Gerd Moellmann  <gerd@gnu.org>
6102         * xdisp.c (resize_mini_window): Subtract the extra line spacing
6103         below the last line from the needed window height.
6105 2000-06-26  Stefan Monnier  <monnier@cs.yale.edu>
6107         * fns.c (Fplist_member): Renamed from Fwidget_plist_member.
6108         (Fwidget_get): Use it.
6109         (syms_of_fns): Defsubr it.
6111 2000-06-26  Gerd Moellmann  <gerd@gnu.org>
6113         * xterm.c (xim_initialize) [!USE_XIM]: Don't set up the
6114         display info for XIM.
6115         (xim_open_dpy): Likewise.
6116         (xim_close_dpy): Don't free the display info's XIM.
6118         * xfns.c (x_window) [!USE_XIM]: Don't call create_frame_ic.
6120         * config.in (USE_XIM): New define.
6122         * keymap.c (get_keyelt): For menu-items containing a `:filter
6123         FILTER', apply FILTER to the menu-item's definition to get the
6124         real definition to use.
6126         * lisp.h (QCfilter): External declaration.
6128         * xfns.c (Fimage_size): New function.
6129         (syms_of_xfns): Defsubr it.
6131 2000-06-26  Andreas Schwab  <schwab@suse.de>
6133         * coding.c (decode_coding_string): Re-fetch STRING_BYTES after
6134         Fstring_as_unibyte.
6136 2000-06-25  Dave Love  <fx@gnu.org>
6138         * term.c [!HAVE_TERMCAP_H]: Declare tputs, tgetent, tgetflag,
6139         tgetnum.
6141         * Makefile.in (blockinput.h): Depend on atimer.h.
6142         (atimer.h): Depend on systime.h.
6144         * blockinput.h: Protect against multiple inclusion.  Include
6145         atimer.h.
6147         * atimer.h: Protect against multiple inclusion.  Include
6148         systime.h.
6150         * lisp.h (swap_in_global_binding): Declare.
6152 2000-06-24  Ken Raeburn  <raeburn@gnu.org>
6154         * process.c (Fopen_network_stream): Turn off atimers for duration
6155         of call to connect.  (Patch from Gerd.)
6157 2000-06-23  Dave Love  <fx@gnu.org>
6159         * ralloc.c: Maybe include unistd.h
6161         * emacs.c (setgrp): Undefine before defining.
6162         (malloc_warning, set_time_zone_rule, index): Prototype.
6164         * systime.h (EMACS_GET_TIME) [!GETTIMEOFDAY_ONE_ARGUMENT]: Use
6165         HAVE_STRUCT_TIMEZONE.
6167         * s/osf1.h: Move string.h hack here from alpha.h and make it
6168         conditional.
6169         (C_SWITCH_SYSTEM): Use _OSF_SOURCE, not -BSD, which clashes with
6170         _XOPEN_SOURCE.
6171         (WAIT_USE_INT, SYS_SIGLIST_DECLARED, sys_siglist, NSIG): Define.
6172         (SOCKLEN_TYPE): Don't define.
6174         * m/alpha.h: Remove string.h hack.
6176         * s/osf5-0.h: New file.
6178         * filelock.c: Use feature tests for fcntl.h, string.h.  Don't
6179         include time.h, done by systime.h.
6180         [__FreeBSD__]: Remove redundant includes.
6182         * callproc.c (setpgrp): Undefine before defining.
6183         (delete_temp_file): Return Qnil to avoid warning.
6185         * config.in (HAVE_TERM_H, HAVE_STRUCT_TIMEZONE): Add.
6187         * xfaces.c: Include fontset.h dependent on HAVE_WINDOW_SYSTEM, not
6188         HAVE_X_WINDOWS.
6190         * fontset.h (free_face_fontset): Renamed from fs_free_face_fontset.
6192         * composite.h (compose_text): Declare.
6194         * xterm.c: Don't include sys/types.h unconditionally.  Don't
6195         protect its inclusion with !USG (following xmenu.c).
6197 2000-06-23  Gerd Moellmann  <gerd@gnu.org>
6199         * xfns.c (x_create_tip_frame): Initialize frame's colors like
6200         in x_create_frame.
6202 2000-06-23  Eli Zaretskii  <eliz@is.elta.co.il>
6204         * coding.c (decode_eol_post_ccl): Special handling for undecided
6205         and inconsistent EOL types.
6207 2000-06-22  Gerd Moellmann  <gerd@gnu.org>
6209         * xrdb.c (x_load_resources): Add default resource for scroll bar's
6210         trough color and main window's background color.
6212         * xfns.c (Fx_file_dialog) [HAVE_MOTIF_2_1]: Handle events
6213         differently.
6215         * xterm.h (Xt_app_con): External declaration.
6217         * widget.c (EmacsFrameRealize): Fix typo.
6219         * widget.c (EmacsFrameRealize): Remove SubstructureRedirectMask.
6221         * xdisp.c (handle_stop): Initialize it->add_overlay_start to zero.
6222         (handle_invisible_prop): Record the start of invisible text in
6223         it->add_overlay_start.
6224         (struct overlay_entry): Add member `overlay'.
6225         (handle_overlay_change): Simplify.
6226         (next_overlay_string): After having processed overlay strings at the
6227         end of the buffer, record that fact in
6228         it->overlay_strings_at_end_processed_p.
6229         (compare_overlay_entries): If before- and after-strings come
6230         from the same overlay, let before-strings come first.
6231         (RECORD_OVERLAY_STRING): Record the overlay that strings come from.
6232         (load_overlay_strings): Take it->add_overlay_start into account
6233         when adding overlay strings.
6235         * dispextern.h (struct it): Add member add_overlay_start.
6237 2000-06-22  Dave Love  <fx@gnu.org>
6239         * s/isc3-0.h (C_SWITCH_SYSTEM): Define _XOPEN_SOURCE=500.
6241         * s/gnu-linux.h (C_SWITCH_SYSTEM): Don't define _XOPEN_SOURCE here.
6243 2000-06-22  Kenichi Handa  <handa@etl.go.jp>
6245         * ccl.c (ccl_driver) <CCL_End>: Decrement stack_idx only when it
6246         is greater than 0.
6248 2000-06-21  Dave Love  <fx@gnu.org>
6250         * Makefile.in (GETLOADAVG_OBJ): Removed -- LIBOBJS does it.
6252 2000-06-21  Stefan Monnier  <monnier@cs.yale.edu>
6254         * syntax.c (back_comment): Simplify string-parity counting (with
6255         the added benefit of handling multiple string-styles as long as
6256         they are not intertwined).
6257         Jump to the slow code as soon as a comment starter is found in
6258         a "string_lossage" position.  Fixes the case:  " /* " /* " */.
6260 2000-06-21  Dave Love  <fx@gnu.org>
6262         * Makefile.in: Use GETLOADAVG_LIBS.
6264         * config.in: Add HAVE_FCNTL_H, _FILE_OFFSET_BITS,
6265         _LARGEFILE_SOURCE, _LARGE_FILES, _XOPEN_SOURCE.
6267 2000-06-20  Stefan Monnier  <monnier@cs.yale.edu>
6269         * syntax.c (describe_syntax): Recognize the `n'estable bit.
6270         (Fforward_comment, scan_lists):
6271         Check the comstyle of single-char comment-starters.
6272         (scan_sexps_forward): Don't try to recognize `half comment-enders' if
6273         we're just at the beginning of the comment (f.ex with (*) ... (*)).
6274         Check the comstyle of single-char comment-starters.
6275         Clarify control-flow around the Scomment case.
6277 2000-06-20  Dave Love  <fx@gnu.org>
6279         * fns.c (make_hash_table, maybe_resize_hash_table):
6280         Cast arg of next_almost_prime.
6282         * tparam.c [emacs]: Include lisp.h.
6284         * termcap.c [emacs]: Test HAVE_FCNTL_H, not USG5.  Include lisp.h
6285         and unistd.h.
6287 2000-06-20  Gerd Moellmann  <gerd@gnu.org>
6289         * keyboard.c (adjust_point_for_property): Check if display
6290         property should be treated as intangible by looking at its
6291         value.
6293         * xdisp.c (single_display_prop_intangible_p)
6294         (display_prop_intangible_p): New functions.
6296         * dispextern.h (display_prop_intangible_p): Add prototype.
6298         * xdisp.c (dump_glyph_row): Show type of glyph->object.
6300         * s/isc4-0.h (sigblock): Redefined to pass a pointer as second
6301         argument to sigprocmask.
6303         * s/sco5.h (sigblock): Redefined to pass a pointer as second
6304         argument to sigprocmask.
6306         * syssignal.h (sigblock, sigunblock) [USG5_4]: Set
6307         sigprocmask_set, and pass a pointer to it to sigprocmask.
6309         * sysdep.c (sigprocmask_set): New variable.
6311         * fileio.c (make_temp_name): Don't use `%s' in string passed to
6312         report_file_error.
6314 2000-06-20  Sam Steingold  <sds@gnu.org>
6316         * xrdb.c: Don't declare xmalloc, xrealloc.
6318 2000-06-20  Stefan Monnier  <monnier@cs.yale.edu>
6320         * regex.c (re_match, re_match_2): Protect calls to alloca (0).
6321         (re_comp): Cast gettext return value to avoid complaints when
6322         !HAVE_LIBINTL.
6324 2000-06-20  Dave Love  <fx@gnu.org>
6326         * m/stride.h, m/mips.h: Don't define HAVE_GETWD,
6327         HAVE_GETTIMEOFDAY.
6329         * m/ibmrt-aix.h: Don't declare HAVE_GETTIMEOFDAY, HAVE_VFORK.
6331         * m/ibmrs6000.h, m/ibmps2-aix.h, m/dpx2.h: Don't declare HAVE_GETWD.
6333         * m/alpha.h: Don't declare xmalloc, xrealloc.
6335         * s/ux4800.h: Don't declare GETTIMEOFDAY_ONE_ARGUMENT.
6337         * s/usg5-4-2.h: Don't declare HAVE_GETWD, VFORK_RETURN_TYPE.
6339         * s/umips.h: Don't declare HAVE_GETWD, HAVE_GETTIMEOFDAY.
6341         * s/cxux.h, s/gnu-linux.h, s/iris3-6.h, s/irix3-3.h: Don't declare
6342         HAVE_GETWD.
6344         * keyboard.h (poll_for_input_1): Declare.
6346         * getloadavg.c: Don't define NLIST_STRUCT (handled by configure).
6348         * alloc.c (xmalloc, xrealloc, xfree): Define using POINTER_TYPE.
6350         * doprnt.c: Don't declare xmalloc, xrealloc.
6352         * lisp.h (x_set_tool_bar_lines, free_frame_xic, compose_text)
6353         (getenv, ctime, getwd): Removed.
6354         (xmalloc, xrealloc, xfree): Declare using POINTER_TYPE.
6356         * xterm.h: Remove duplicate prototypes.  Declare free_frame_xic,
6357         x_set_tool_bar_lines.
6359         * config.in: Add HAVE_GETWD.  Move some definitions above
6360         machine/system includes.
6362 2000-06-20  Kenichi Handa  <handa@etl.go.jp>
6364         * s/bsd386.h (HAVE_GETLOADAVG): Define it as 1.
6366         * xfaces.c (font_list): Handle the case that REGISTRY doesn't
6367         contain information about ENCODING.
6369         * fontset.c (FONTSET_ASCII): Use the first element of char table
6370         for an ASCII font, not defalt slot.
6371         (fontset_ref_via_base): If FONTSET doesn't contain information for
6372         C, try the default fontset.
6373         (make_fontset): Don't copy the default fontset.
6374         (fontset_font_pattern): Likewise.
6375         (accumulate_font_info): If ELT is nil, use the corresponding
6376         element in the default fontset.
6378 2000-06-19  Dave Love  <fx@gnu.org>
6380         * syntax.c (Fparse_partial_sexp): Doc fix.
6382         * regex.h: Test PROTOTYPES as well as __STDC__.
6384         * unexalpha.c: Include errno.h, string.h, unistd.h.  Don't declare
6385         errno, strerror.  Put text after #endif in comment.
6387         * xdisp.c (dump_glyph_matrix): Add `static' to declaration (for
6388         pcc).
6390         * xterm.c (x_frame_of_widget): Likewise.
6392 2000-06-19  Gerd Moellmann  <gerd@gnu.org>
6394         * abbrev.c (syms_of_abbrev): Set buffer_default's abbrev table
6395         to Vfundamental_mode_abbrev_table.
6397         * alloc.c (mark_object) [GC_CHECK_MARKED_OBJECTS]: Check that no
6398         bogus objects are marked.  This slows down GC by ~80 percent, but
6399         it might be worth trying when debugging GC-related problems.
6400         This feature requires conservative stack marking to be enabled.
6402         * xterm.c (XTread_socket) <KeyPress>: In case XmbLookupString
6403         returns XLookupChars, reset `modifiers' to zero.
6405 2000-06-19  Dave Love  <fx@gnu.org>
6407         * mktime.c: Unprotoized.
6409 2000-06-19  Richard Stallman  <rms@gnu.org>
6411         * data.c (set_internal): If variable is frame-local,
6412         store the new value immediately into the frame parameter alist.
6414 2000-06-19  Ken Raeburn  <raeburn@gnu.org>
6416         * xfns.c (jpeg_load): Fetch error-handling data first, then fill
6417         in the custom handler pointer.
6419         * keyboard.c (follow_key, read_key_sequence): Use XUINT on key
6420         value, or checks for CHAR_META can fail when Lisp_Object is a
6421         union type.
6422         * keymap.c (get_keyelt): Likewise.
6424 2000-06-19  Kenichi Handa  <handa@etl.go.jp>
6426         * ccl.h (struct ccl_program): New member eol_type.
6427         (struct ccl_spec): New member cr_carryover.
6429         * ccl.c (CCL_WRITE_CHAR): Convert NL according to ccl->eol_type.
6430         (setup_ccl_program): Initialize ccl->eol_type to CODING_EOL_LF.
6432         * coding.c (setup_coding_system) <4>: Reset member `cr_carryover'.
6433         (ccl_coding_driver): On encoding, initialize ccl->eol_type.
6434         (decode_eol_post_ccl): New function.
6435         (decode_coding): Don't detect EOL format here for CCL based coding
6436         systems.
6437         (decode_coding) <coding_type_ccl>: Handle carryovered CR.  Call
6438         decode_eol_post_ccl after running the CCL program.
6439         (code_convert_region): Don't detect EOL format here for CCL based
6440         coding systems.
6441         (decode_coding_string): Likewise.
6443 2000-06-18  Ken Raeburn  <raeburn@gnu.org>
6445         * charset.c (update_charset_table): Use XINT on "iso_final_char"
6446         when treating it as an integer.
6448         * coding.h (encode_coding_string): Declare.
6450         * keyboard.c (read_key_sequence): Use XINT on "pos" when treating
6451         it as an integer.
6453         * keymap.c (Fwhere_is_internal): Rename argument "keymap" to
6454         "xkeymap" to avoid shadowing the "enum map_type" value that needs
6455         to be passed to get_local_map.
6457         * sound.c (Fplay_sound): Don't call make_number on
6458         Frun_hook_with_args count argument.
6460         * xterm.c (x_send_scroll_bar_event): Fudge lisp object/integer
6461         for lisp objects in X event structure data field, when lisp
6462         objects are represented with unions.
6463         (x_scroll_bar_to_input_event): Ditto.
6465 2000-06-16  Ken Raeburn  <raeburn@gnu.org>
6467         * xdisp.c (decode_mode_spec): In "no_value" case, do NUL
6468         termination of string.  Fix sense of test whether
6469         Vline_number_display_limit is an integer.
6471 2000-06-16  Gerd Moellmann  <gerd@gnu.org>
6473         * xfaces.c (syms_of_xfaces) [DEBUG_X_COLORS]: Defsubr dump_colors
6474         only if HAVE_X_WINDOWS.
6476         * keymap.c (describe_buffer_bindings): Add `\f\n' in front
6477         of titles.
6479         * dispnew.c (update_frame_1): Handle case that cursor vpos is
6480         out of bounds.
6482 2000-06-15  Eli Zaretskii  <eliz@is.elta.co.il>
6484         * unexec.c (toplevel): Fix last change, so as not to deprive MSDOS
6485         of its headers.
6487 2000-06-15  Kenichi Handa  <handa@etl.go.jp>
6489         * coding.c (decode_coding_emacs_mule): Always set src_base at the
6490         start of the while loop.
6492 2000-06-15  Gerd Moellmann  <gerd@gnu.org>
6494         * atimer.c (alarm_signal_handler): Add forward declaration.
6496         * data.c (set_internal): Remove debug code.
6498 2000-06-14  Gerd Moellmann  <gerd@gnu.org>
6500         * Makefile.in (bootstrap-temacs): Add `-I../src'.
6502         * unexec.c (toplevel) [COFF]: Include coff.h.
6504         * s/lynxos.h: New file.
6506         * keymap.c (Fsingle_key_description): Enclose function key and
6507         event symbol names in angle brackets.
6509         * xdisp.c (setup_echo_area_for_printing): Call
6510         message_log_maybe_newline if message_buf_print is not set.
6512         * print.c (printchar, strout): Don't check message_buf_print
6513         before calling setup_echo_area_for_printing because that
6514         function does something useful even when message_buf_print is
6515         already set.
6517         * xdisp.c (message_truncate_lines, Qmessage_truncate_lines): New
6518         variables.
6519         (ensure_echo_area_buffers): Initialize echo buffer's
6520         truncate lines setting to nil.
6521         (with_echo_area_buffer): Don't set the echo buffer's truncate
6522         lines setting here.
6523         (set_message_1): Set it here instead, based on the value
6524         of message_truncate_lines.
6525         (resize_mini_window): Handle case that lines are truncated.
6526         (syms_of_xdisp): Initialize Qmessage_truncate_lines.  DEFVAR_BOOL
6527         message-truncate-lines.
6529         * keyboard.c (read_char): Bind message-truncate-lines to t
6530         while displaying a help-echo.
6532         * lisp.h (Qmessage_truncate_lines): External declaration.
6534 2000-06-13  Gerd Moellmann  <gerd@gnu.org>
6536         * xdisp.c (Vline_number_display_limit): Renamed from
6537         line_number_display_limit.
6538         (syms_of_xdisp): Use DEFVAR_LISP for line-number-display-limit.
6539         Extend documentation string.  Initialize
6540         Vline_number_display_limit to nil meaning no limit.
6541         (decode_mode_spec): Use Vline_number_display_limit with its new
6542         meaning.
6544         * xterm.c (x_check_font) [GLYPH_DEBUG]: Add prototype.
6546 2000-06-13  Richard Stallman  <rms@gnu.org>
6548         * frame.c (Fmodify_frame_parameters): Doc fix.
6550         * xfns.c (x_set_frame_parameters): Comment fix.
6552         * frame.c (store_frame_param): Call swap_in_global_binding if the
6553         variable's current binding was chosen based on this frame.
6555         * data.c (swap_in_global_binding): New function.
6557 2000-06-13  Eli Zaretskii  <eliz@is.elta.co.il>
6559         * msdos.c (IT_write_glyphs): Don't use CODING_REQUIRE_ENCODING
6560         macro, instead AND with CODING_REQUIRE_ENCODING_MASK.
6562 2000-06-13  Eli Zaretskii  <eliz@is.elta.co.il>
6564         * msdos.h (EMACS_MSDOS_H): Renamed from MSDOS_H_.
6566 2000-06-12  Jason Rumney  <jasonr@gnu.org>
6568         * w32bdf.h (EMACS_W32BDF_H): Renamed from __W32BDF_H__
6570         * w32.h (EMACS_W32_H): Renamed from _NT_H_
6572         * w32gui.h (EMACS_W32GUI_H): Renamed from __W32GUI_H__
6574         * w32inevt.h (EMACS_W32INEVT_H): Renamed from __NTINEVT_H__
6576 2000-06-12  Gerd Moellmann  <gerd@gnu.org>
6578         * xfaces.c (Fdump_colors) [DEBUG_X_COLORS]: New function.
6579         (syms_of_xfaces): Defsubr Sdump_colors.
6580         (x_free_colors): Don't treat b&w specially on default visual.
6581         (x_free_dpy_colors): New function.
6582         (free_face_colors): Don't check visual class; it's done
6583         in x_free_colors.
6585         * xterm.c (x_frame_of_widget): New function.
6586         (x_alloc_nearest_color_for_widget): Use it.
6587         (x_copy_dpy_color): New function.
6588         (x_destroy_window): Free various colors.
6590 2000-06-12  Kenichi Handa  <handa@etl.go.jp>
6592         * ccl.h (EMACS_CCL_H): Renamed from _CCL_H.
6594         * charset.h (EMACS_CHARSET_H): Renamed from _CHARSET_H.
6596         * coding.h (EMASC_CODING_H): Renamed from _CODING_H.
6598         * composite.h (EMACS_COMPOSITE_H): Renamed from _COMPOSITE_H.
6600         * fontset.h (EMACS_FONTSET_H): Renamed from _FONTSET_H.
6602 2000-06-11  Dave Love  <fx@gnu.org>
6604         * systime.h (EMACS_SYSTIME_H): Renamed from _SYSTIME_H.
6606 2000-06-11  Eli Zaretskii  <eliz@is.elta.co.il>
6608         * msdos.h: Don't use _MSDOS_H_ as a symbol, use MSDOS_H_ instead.
6610 2000-06-11  Gerd Moellmann  <gerd@gnu.org>
6612         * xmenu.c (xmenu_show): Cast second parameter of lw_popup_menu
6613         to `XEvent *'.
6615 2000-06-10  Kenichi Handa  <handa@etl.go.jp>
6617         * regex.c (MAKE_CHAR) [!emacs]: Dummy macro for non-Emacs env.
6618         (regex_compile): Fix the code for handling the case of single byte
6619         char and multibyte char being mixed in a range within [...].
6621         * fileio.c (Finsert_file_contents): Be sure to setup src_multibyte
6622         and dst_multibyte members of coding.
6624         * charset.c (update_charset_table): Update the table
6625         bytes_by_char_head.
6626         (init_charset_once): Initialize elements of bytes_by_char_head to
6627         1 except for leading codes for private charases.
6629         * charset.h (CHARSET_8_BIT_GRAPHIC): Define as 0x80.
6630         (UNIBYTE_STR_AS_MULTIBYTE_P): Fix for an invalid multibyte
6631         sequence.
6633 2000-06-09  Ken Raeburn  <raeburn@gnu.org>
6635         * xterm.c (x_connection_closed): If dpyinfo is NULL, don't try to
6636         access the data it doesn't point to.
6638 2000-06-08  Gerd Moellmann  <gerd@gnu.org>
6640         * xterm.c (XTread_socket) <FocusIn>: Queue a FOCUS_IN_EVENT which
6641         will be translated to a switch-frame event when reading the
6642         event queue.  This is necessary because Emacs otherwise won't
6643         perform a switch-frame to a new frame until some other event, for
6644         example a keystroke event, forces it to do so.  This has various
6645         effects, one visible being that the cursor of a frame created with
6646         C-x 5 2 or switched to with a window manager key binding like
6647         A-TAB stays hollow because selected_window isn't on the newly
6648         focused frame until the switch-frame is performed.
6650         * keyboard.c (kbd_buffer_get_event): Handle FOCUS_IN_EVENT by
6651         generating a switch-frame event if necessary.
6653         * termhooks.h (enum event_kind): Add FOCUS_IN_EVENT.
6655         * xdisp.c (handle_fontified_prop): Don't GCPRO local var `pos';
6656         it's an integer.
6658 2000-06-08  Kenichi Handa  <handa@etl.go.jp>
6660         * fontset.c (Fset_fontset_font): The arg CHARACTER may be a
6661         charset.
6663 2000-06-07  Gerd Moellmann  <gerd@gnu.org>
6665         * window.c (displayed_window_lines): Take empty lines at
6666         the bottom of a window into account.
6668         * window.c (displayed_window_lines): New function.
6669         (Fmove_to_window_line): Use displayed_window_lines to determine
6670         the number of lines to move, instead of using the window's height.
6672         * lread.c (readevalloop): If READCHARFUN sets point to ZV, arrange
6673         to stop reading, even if the form read sets point to a different
6674         value when evaluated.
6676         * xdisp.c (display_line): Fix code deciding in which line to
6677         put the cursor.
6679 2000-06-07  Kenichi Handa  <handa@etl.go.jp>
6681         * fileio.c (e_write): Free composition data if stored in
6682         coding->cmp_data.
6684 2000-06-06  Gerd Moellmann  <gerd@gnu.org>
6686         * xdisp.c (display_line): Set row's and iterator's
6687         starts_in_middle_of_char_p and ends_in_middle_of_char_p flags.
6688         Set cursor even if row ends in the middle of a character.
6689         (dump_glyph_row): Print values of new flags.
6690         (redisplay_window) <cursor movement in unchanged window>: When
6691         point has been moved forward, and PT is at the end of the cursor
6692         row, don't place the cursor in the next row if the cursor row ends
6693         in the middle of a character or at ZV.
6695         * dispextern.h (struct it): Add starts_in_middle_of_char_p.
6696         (struct glyph_row): Add starts_in_middle_of_char_p and
6697         ends_in_middle_of_char_p.
6698         (MATRIX_ROW_ENDS_IN_MIDDLE_OF_CHAR_P): Test row's
6699         ends_in_middle_of_char_p flag.
6700         (MATRIX_ROW_STARTS_IN_MIDDLE_OF_CHAR_P): Likewise.
6702         * term.c (append_glyph): Revert change of 2000-06-06.
6704         * xdisp.c (display_line): Revert change of 2000-06-06.  Treat
6705         padding glyph not fitting on line as whole character not
6706         fitting on line.
6708         * xterm.c (x_produce_glyphs): Don't xassert `it->descent > 0';
6709         this isn't true for images with `:ascent 100'.
6711 2000-06-06  Kenichi Handa  <handa@etl.go.jp>
6713         * buffer.c (Fset_buffer_multibyte): Don't make the current buffer
6714         as modified if it is originally unmodified.
6716         * term.c (encode_terminal_code): Change the way to check if
6717         terminal coding does any conversion.
6718         (append_glyph): Set glyph->pixel_width correctly.
6720         * xdisp.c (display_line): While checking line continuation, pay
6721         attention to a padding glyph.
6723 2000-06-05  Gerd Moellmann  <gerd@gnu.org>
6725         * xdisp.c (redisplay_window): Always use set_buffer_internal_1.
6727 2000-06-05  Dave Love  <fx@gnu.org>
6729         * xdisp.c: Include fontset.h.
6731         * xfns.c (x_real_positions): Declare tmp_nchildren as unsigned.
6733         * xterm.c (x_calc_absolute_position): Declare nchildren unsigned.
6735         * dispnew.c: Conditionally include term.h.
6737         * coding.h: Declare code_convert_string_norecord.
6739         * frame.h (struct frame): Use volatile unconditionally.
6741         * buffer.h: Remove Vbefore_change_function, Vafter_change_function.
6743         * xmenu.c (menu_item_selection): Declare volatile unconditionally.
6745         * systime.h: Protect against multiple inclusion.
6746         (timezone) [USG5_4]: Define as time_t.
6748         * lisp.h (DEFUN, EXFUN): Test PROTOTYPES.
6749         (Foptimize_char_table, make_temp_name): Declare.
6751         * Makefile.in (xdisp.o): Depend on fontset.h.
6753         * xterm.c (x_calc_absolute_position): Declare nchildren unsigned.
6755         * lisp.h (DEFUN, EXFUN): Test PROTOTYPES.
6756         (Foptimize_char_table, make_temp_name): Declare.
6758         * s/irix4-0.h:
6759         * s/irix5-0.h:
6760         * s/netbsd.h: Don't define autoconfiscated MATHERR.
6762 2000-06-02  Dave Love  <fx@gnu.org>
6764         * lread.c (_XOPEN_SOURCE, __EXTENSIONS__): Don't define.
6766 2000-06-02  Gerd Moellmann  <gerd@gnu.org>
6768         * xfaces.c (realize_x_face): When copying BASE_FACE bitwise to the
6769         result face, set flags in that face indicating that colors may not
6770         be freed.
6772         * xterm.c (x_set_mouse_face_gc): If first glyph isn't a character
6773         glyph, use the ASCII NUL character to determine the face.
6775 2000-06-02  Dave Love  <fx@gnu.org>
6777         * sysdep.c: Conditionally include stdlib.h, unistd.h.
6778         (VFORK_RETURN_TYPE): Remove.
6780         * config.in: Add NO_MATHERR.
6782 2000-06-01  Dave Love  <fx@gnu.org>
6784         * cmds.c (internal_self_insert): Don't check
6785         Vbefore_change_function, Vafter_change_function.
6787         * insdel.c (signal_before_change, signal_after_change): Likewise.
6789         * buffer.c (Vbefore_change_function, Vafter_change_function):
6790         Variables and their initializations deleted.
6792         * callint.c (Fcall_interactively): Doc fix.
6794         * terminfo.c (ospeed) [HAVE_SPEED_T]: Don't declare extern.
6796 2000-05-31  Dave Love  <fx@gnu.org>
6798         * textprop.c: Revert last change -- duplicated.
6800 2000-05-31  Gerd Moellmann  <gerd@gnu.org>
6802         * dispnew.c (find_glyph_row_slice, swap_glyphs_in_rows): Put
6803         in #if 0.
6805         * lisp.h (eassert) [!ENABLE_CHECKING]: Define as `(void) 0'.
6807 2000-05-31  Jason Rumney  <jasonr@gnu.org>
6809         * search.c (Fre_search_forward, Fre_search_backward)
6810         (Fposix_search_backward, Fposix_search_forward): Fix newlines in docs.
6812         * w32select.c (Fw32_set_clipboard_data): Change QNil to Qnil.
6814 2000-05-30  Jason Rumney  <jasonr@gnu.org>
6816         * coding.h (ENCODE_SYSTEM, DECODE_SYSTEM) [WINDOWSNT]: New macros.
6817         [WINDOWSNT]: Add extern for Vw32_system_coding_system.
6819         * dispextern.h (struct glyph) [WINDOWSNT]: Add w32_font_type
6820         member.
6822         * fileio.c (Fread_file_name) [HAVE_NTGUI]: Use file dialog.
6823         (Fread_file_name) [HAVE_NTGUI, USE_MOTIF]: Do not attempt to
6824         expand a nil default_filename.
6826         * keyboard.c (make_lispy_event) [WINDOWS_NT]: Pass a window
6827         pointer to glyph_to_pixel_coords, not a frame.
6829         * makefile.nt (w32fns.obj, w32menu.obj): Add charset.h and
6830         coding.h to dependencies.
6832         * w32bdf.c (w32_load_bdf_font): Initialize font->double_byte_p.
6834         * w32console.c (glyph_to_pixel_coords): Change first parameter to
6835         window pointer to be consistent with w32term.c and xterm.c.
6837         * w32fns.c: Format and doc changes to bring closer to xfns.c.
6838         (VIETNAMESE_CHARSET): Define if not defined in system headers.
6839         (Qline_spacing, Qcenter): New variables.
6840         (Qw32_charset_*, w32_codepage_for_font): Moved from w32term.c.
6841         (x_set_line_spacing): New function.
6842         (x_set_frame_parameters): Use FRAME_NEW_WIDTH, FRAME_NEW_HEIGHT
6843         macros.
6844         (x_specified_cursor_type): New function.
6845         (x_set_cursor_type): Use it.
6846         (x_set_name, x_set_title): Use ENCODE_SYSTEM to encode titlebar
6847         and icon strings.
6848         (validate_x_resource_name, x_get_resource_string): Measure lengths
6849         of external strings in bytes.
6850         (w32_wnd_proc) [WM_MEASURE_ITEM]: Avoid calling
6851         GetTextExtentPoint32 with NULL title.
6852         (Fx_create_frame): Initialize Qline_spacing.
6853         (w32_load_system_font): Initialize font->double_byte_p.
6854         (x_to_w32_charset): Use Vw32_charset_info_alist.
6855         (Image, busy cursor, tooltip functions): Merged changes from
6856         xfns.c. Not yet functional on Windows.
6858         * w32gui.h (W32FontStruct): Add double_byte_p member.
6860         * w32inevt.c (NUM_TRANSLATED_MOUSE_BUTTONS): New constant.
6861         (emacs_button_translation): Use it.
6862         (do_mouse_event): Allow up to 32 mouse buttons by allowing any bit
6863         in `mask' to be set.
6865         * w32menu.c (single_submenu, w32_menu_show): Call ENCODE_SYSTEM on
6866         menu strings.
6868         * w32term.c: Format and doc changes to bring closer to xterm.c.
6869         (w32_char_font_type): New enum.
6870         (Qw32_charset_*, w32_codepage_for_font): Moved to w32fns.c.
6871         (w32_per_char_metric): Use w32_char_font_type instead of unicode_p.
6872         (w32_encode_char): New function.
6873         (x_encode_char): Removed.
6874         (x_get_glyph_and_face_encoding): Use w32_encode_char in place of
6875         x_encode_char and w32_font_is_double_byte.
6876         (x_produce_image_glyph): Use image_ascent.
6877         (x_produce_glyphs): Use new version of w32_per_char_metric and
6878         handle NULL return value. Allow extra line spacing.
6879         (W32_TEXTOUT): Distinguish between Unicode and DBCS text.
6880         (w32_get_glyph_overhangs): Remove unicode_p param. Use
6881         w32_font_type member of glyph instead.
6882         (x_draw_glyph_string): Draw underline and strike-out for BDF fonts.
6883         (fast_find_position): Make sure not to consider rows not visible
6884         in the window.
6885         (w32_read_socket) [WM_MENUSELECT]: Cannot call
6886         w32_menu_display_help with input blocked, as it can abort.
6887         (x_display_and_set_cursor): Choose cursor depending
6888         on buffer-local value of cursor_type.
6889         (x_draw_bar_cursor): Add parameter WIDTH.
6891         * w32term.h (CP_DEFAULT): Define.
6892         (Fx_display_color_p, Fx_display_grayscale_p, image_ascent): Declare.
6894 2000-05-30  Gerd Moellmann  <gerd@gnu.org>
6896         * search.c (Fre_search_forward, Fre_search_backward)
6897         (Fposix_search_backward, Fposix_search_forward): Doc fix.
6899 2000-05-30  Kenichi Handa  <handa@etl.go.jp>
6901         * coding.c (detect_coding_iso2022): Fix code for checking
6902         CODING_CATEGORY_MASK_ISO_8_2.
6904 2000-05-29  Stefan Monnier  <monnier@cs.yale.edu>
6906         * regex.c (PREFETCH_NOLIMIT): New function.
6907         (re_match_2_internal): Use it and adjust the end_match_2 logic.
6909 2000-05-29  Gerd Moellmann  <gerd@gnu.org>
6911         * syntax.c (find_defun_start): Move test for
6912         open_paren_in_column_0_is_defun_start outside of the loop.
6914         * xdisp.c (redisplay_window): Really switch buffers when
6915         displaying mode lines, and temporarily set selected_frame to the
6916         frame of the window that's redisplayed.
6918         * xfaces.c (free_realized_faces): Block/unblock input.
6919         (free_realized_multibyte_face): Ditto.
6921 2000-05-29  Dave Love  <fx@gnu.org>
6923         * textprop.c (Qkeymap): New variable.
6924         (syms_of_textprop): Intern it.
6926         * keymap.c: Include intervals.h.
6927         (Fkey_binding, Fwhere_is_internal): Deal with `keymap' property.
6929         * Makefile.in (keymap.o): Depend on intervals.h.
6931         * keyboard.c (menu_bar_items, tool_bar_items)
6932         (Fexecute_extended_command): Deal with `keymap' property.
6933         (read_key_sequence): Track map from `keymap' property as well as
6934         `local_map'.
6936         * intervals.c (get_local_map): Extra arg to allow looking for
6937         `keymap' too.
6939         * intervals.h (map_property): New enum.
6940         (get_local_map): Extra arg using it.
6941         (Qkeymap): Declare.
6943         * lisp.h (get_local_map): Don't declare here.
6945 2000-05-29  Kenichi Handa  <handa@etl.go.jp>
6947         * Makefile.in (callproc.o): Depend on composite.h.
6949         * callproc.c: Include composite.h.
6950         (Fcall_process): Handle composition correctly.
6952         * coding.h (coding_allocate_composition_data): Extern it.
6953         (coding_restore_composition): Likewise.
6955         * coding.c (DECODE_COMPOSITION_START): If coding->cmp_data is not
6956         yet allocated, finish decoding with result
6957         CODING_FINISH_INSUFFICIENT_CMP.
6958         (coding_allocate_composition_data): Make it non-static.
6959         (coding_restore_composition): Likewise.
6961 2000-05-29  Eli Zaretskii  <eliz@is.elta.co.il>
6963         * charset.c (syms_of_charset): Revert last change.
6965 2000-05-28  Eli Zaretskii  <eliz@is.elta.co.il>
6967         * term.c (produce_glyphs): Treat characters from the eight-bit-*
6968         charsets as unibyte, with 1-column screen width.  Sent by Kenichi
6969         Handa.
6971 2000-05-28  Eli Zaretskii  <eliz@is.elta.co.il>
6973         * charset.c (syms_of_charset): Set width of character sets
6974         eight-bit-control and eight-bit-graphic to 1 column.
6976 2000-05-26  Gerd Moellmann  <gerd@gnu.org>
6978         * config.in (HAVE_SPEED_T): New define.
6980         * sysdep.c, terminfo.c (ospeed) [HAVE_SPEED_T]: Declare as
6981         `extern speed_t'.
6983 2000-05-26  Dave Love  <fx@gnu.org>
6985         * coding.c (shrink_decoding_region): Initialize eol_conversion.
6987         * data.c (Qsubrp, Qmany, Qunevalled): New variables.
6988         (Fsubr_arity): New function.
6989         (syms_of_data): Install them.
6991 2000-05-26  Kenichi Handa  <handa@etl.go.jp>
6993         * charset.c (init_charset_once): Set the table bytes_by_char_head
6994         correctly.
6996         * fontset.c (syms_of_fontset): Adjust the font name for ascii of
6997         the default fontset to what Emacs uses by default.
6998         (check_registry_encoding): This function deleted.
6999         (Fset_fontset_font): Remove the adhoc condition for the default
7000         fontset.  Allow cons in FONTNAME.
7002         * fns.c (map_char_table): Ignore char-table entries for
7003         charsets eight-bit-control and eight-bit-graphic.
7005 2000-05-25  Ken Raeburn  <raeburn@gnu.org>
7007         * emacs.c (main): Initialize keyboard syms before initializing
7008         window code, so face names are available.
7010 2000-05-25  Stefan Monnier  <monnier@cs.yale.edu>
7012         * regex.c (at_begline_loc_p): Also recognize the \\(?:^ case
7013         of an anchor at the beginning of a shy-group.
7015 2000-05-25  Gerd Moellmann  <gerd@gnu.org>
7017         * xdisp.c (handle_invisible_prop): Don't try to skip over
7018         invisible text if end of text is already reached.
7020 2000-05-25  Dave Love  <fx@gnu.org>
7022         * xdisp.c (Fdump_glyph_matrix): Declare the arg.
7024         * coding.c (encode_eol): Add null statement after label.
7026 2000-05-25  Eli Zaretskii  <eliz@is.elta.co.il>
7028         * w16select.c (Fw16_set_clipboard_data): Fix the change from
7029         2000-05-20.
7031 2000-05-25  Kenichi Handa  <handa@etl.go.jp>
7033         * ccl.c (ccl_driver): Fix previous change.
7035 2000-05-25  Kenichi Handa  <handa@etl.go.jp>
7037         * coding.c (run_pre_post_conversion_on_str): Set point to the
7038         beginning of buffer before calling coding->post_read_conversion.
7039         (decode_coding_string): Give correct args to
7040         run_pre_post_conversion_on_str.
7041         (encode_coding_string): Likewise.
7043         * ccl.c (ccl_driver) <CCL_ReadMultibyteChar2>
7044         <CCL_WriteMultibyteChar2>:  Handle charsets eight-bit-control and
7045         eight-bit-graphic correctly.
7047 2000-05-24  Kenichi HANDA  <handa@etl.go.jp>
7049         * fileio.c (Finsert_file_contents): Even if a file is not found,
7050         execute codes for setting up coding system.  Call
7051         after-insert-file-functions unconditionally.
7053 2000-05-24  Gerd Moellmann  <gerd@gnu.org>
7055         * callproc.c, emacs.c, sysdep.c (setpgrp): Don't define if USG and
7056         BSD_PGRPS are not defined.
7058 2000-05-24  Kenichi Handa  <handa@etl.go.jp>
7060         * charset.c (update_charset_table): Accept nil in LONG_NAME and
7061         DESCRIPTION.
7062         (syms_of_charset): Avoid building same strings.
7064 2000-05-23  Gerd Moellmann  <gerd@gnu.org>
7066         * lread.c (Fload): Add a comment about the meaning of
7067         Vuser_init_file being t.
7069         * puresize.h (BASE_PURESIZE): Increase to 675000.
7071         * s/gnu-linux.h (setpgrp): Don't define it here because this
7072         prevents compilation on GNU/Linux systems with glib 2.2.
7074         * callproc.c, emacs.c, sysdep.c (setpgrp) [HAVE_SETPGID]: Define
7075         as setpgid.
7077 2000-05-23  Eli Zaretskii  <eliz@is.elta.co.il>
7079         * Makefile.in (SOME_MACHINE_LISP): Add disp-table.elc,
7080         dos-vars.elc, ccl.elc, and codepage.elc, all loaded by the MS-DOS
7081         version.
7082         (MSDOS_SUPPORT): Add dos-vars.elc, ccl.elc, and codepage.elc.
7084 2000-05-23  Kenichi Handa  <handa@etl.go.jp>
7086         * syntax.c (skip_chars): Use FETCH_STRING_CHAR_ADVANCE
7087         unconditionally.
7089         * msdos.c (IT_write_glyphs): Set coding->src_multibyte to 1.
7091         * term.c (encode_terminal_code): Set coding->src_multibyte
7092         properly.
7094         * coding.c (encode_eol): Fix a bug of DOS style EOL encoding.
7096 2000-05-22  Kenichi Handa  <handa@etl.go.jp>
7098         * keyboard.c (read_char): Allow character codes 128..255 to be
7099         handled by input-method-function.
7101         * insdel.c (adjust_markers_for_replace): Fix previous change.
7102         (adjust_after_replace): If PREV_TEXT is nil, call
7103         adjust_markers_for_insert, not adjust_markers_for_replace.
7105 2000-05-20  NIIBE Yutaka  <gniibe@mri.co.jp>
7107         * s/gnu-linux.h (UNIX98_PTYS) [HAVE_GRANDPT]: Define.
7108         (PTY_ITERATION, PTY_NAME_SPRINTF, PTY_OPEN, PTY_TTY_NAME_SPRINTF)
7109         [HAVE_GRANDPT]: Define.
7110         (C_SWITCH_SYSTEM): Add -D_XOPEN_SOURCE.
7112         * sysdep.c (setup_pty): Treat case that UNIX98_PTYS is defined
7113         like SYSV_PTYS.
7115         * config.in (HAVE_GRANDPT, HAVE_GETPT): New defines.
7117         * process.c (toplevel) [UNIX98_PTYS]: Include stdlib.h.
7119 2000-05-20  Kenichi Handa  <handa@etl.go.jp>
7121         The following changes are to handle 8-bit characters in a
7122         multibyte buffer/string without facing with byte combining
7123         problem.  Two new charsets eight-bit-control (for 0x80..0x9F) and
7124         eight-bit-graphic (for 0xA0..0xFF) are introduced.
7126         * Makefile.in (fns.o): Depend on charset.h.
7128         * alloc.c (Fmake_byte_code): If BYTECODE-STRING is multibyte,
7129         convert it to unibyte.
7130         (make_string): Use parse_str_as_multibyte, not chars_in_text.
7132         * buffer.c (advance_to_char_boundary): Don't use DEC_POS to find a
7133         apparent char boundary.
7134         (Fset_buffer_multibyte): Convert 8-bit characters in the range
7135         0x80..0x9F to/from multibyte form.
7137         * bytecode.c (Fbyte_code): If arg BYTESTR is multibyte, convert it
7138         to unibyte.
7140         * callproc.c (Fcall_process): Always encode an argument string if
7141         it is multibyte.  Setup src_multibyte and dst_multibyte members of
7142         process_coding properly.
7144         * category.c (Fmodify_category_entry): Use SPLIT_CHAR, not
7145         SPLIT_NON_ASCII_CHAR.
7147         * ccl.c (CCL_WRITE_CHAR): Be sure to write single byte characters
7148         as is.
7149         (CCL_MAKE_CHAR): Use MAKE_CHAR, not MAKE_NON_ASCII_CHAR.
7151         * charset.c (Qeight_bit_control, Qeight_bit_graphic): New
7152         variables.
7153         (SPLIT_CHARACTER_SEQ): This macro deleted.
7154         (SPLIT_MULTIBYTE_SEQ): Assume that multibyte sequence at STR is
7155         valid.
7156         (CHAR_COMPONENTS_VALID_P): Handle new charsets; eight-bit-control
7157         and eight-bit-graphic.
7158         (char_to_string): Likewise.  Signal an error for too large
7159         character code.
7160         (char_printable_p): Return 0 for 8-bit characters.
7161         (update_charset_table): Update iso_charset_table only when a final
7162         character is non-negative.
7163         (find_charset_in_text): Renamed from find_charset_in_str.
7164         Arguments and return value changed.  Callers changed.
7165         (Fdefine_charset): Args ISO-FINAL-CHAR and ISO-GRAPHIC-PLANE can
7166         be -1 if CHARSET is used only internally.
7167         (Fmake_char_internal): Handle new charsets; eight-bit-control and
7168         eight-bit-graphic.
7169         (Fcharset_after): Simplified.
7170         (char_valid_p): Use SPLIT_CHAR, not SPLIT_NON_ASCII_CHAR.
7171         (char_bytes): Return 2 for chars of the range 0xA0..0xFF.
7172         (multibyte_chars_in_text): Simplified by assuming there's no
7173         invalid multibyte sequence.
7174         (parse_str_as_multibyte, str_as_multibyte, str_to_multibyte,
7175         str_as_unibyte): New functions.
7176         (Fstring): Simpified by assuming that byte combining never
7177         happens.
7178         (init_charset_once): Initialization for
7179         LEADING_CODE_8_BIT_CONTROL.
7180         (syms_of_charset): Intern and staticpro Qeight_bit_control and
7181         Qeight_bit_graphic.  Include them in Vcharset_list.  Make charsets
7182         eight-bit-control and eight-bit-graphic.
7184         * charset.h (LEADING_CODE_8_BIT_CONTROL, CHARSET_8_BIT_CONTROL,
7185         CHARSET_8_BIT_GRAPHIC): New macros.
7186         (SINGLE_BYTE_CHAR_P): Make it faster by using casting.
7187         (CHARSET_ISO_GRAPHIC_PLANE): Use XINT instead of XFASTINT.
7188         (CHARSET_REVERSE_CHARSET): Likewise.
7189         (CHARSET_VALID_P): Handle new charsets; eight-bit-control and
7190         eight-bit-graphic.
7191         (BYTES_BY_CHAR_HEAD, WIDTH_BY_CHAR_HEAD): Optimize for ASCII.
7192         (CHAR_CHARSET, MAKE_CHAR, SPLIT_CHAR, CHAR_BYTES): Likewise.
7193         (PARSE_MULTIBYTE_SEQ) [BYTE_COMBINING_DEBUG]: Abort if we
7194         encounter an invalid multibyte sequence.
7195         (PARSE_MULTIBYTE_SEQ) [not BYTE_COMBINING_DEBUG]: Assume multibyte
7196         sequence is always valid.
7197         (MAKE_NON_ASCII_CHAR, SPLIT_NON_ASCII_CHAR): These macros Deleted.
7198         (UNIBYTE_STR_AS_MULTIBYTE_P, MULTIBYTE_STR_AS_UNIBYTE_P): New
7199         macros.
7200         (CHAR_STRING): For 8-bit characters, call char_to_string.
7201         (INC_POS) [not BYTE_COMBINING_DEBUG]: Faster version.  Assume
7202         multibyte sequence is always valid.
7203         (BUF_INC_POS) [not BYTE_COMBINING_DEBUG]: Likewise.
7204         (parse_str_as_multibyte, str_as_multibyte, str_to_multibyte,
7205         str_as_unibyte): Extern them.
7206         (BCOPY_SHORT): Fix a bug.
7207         (CHAR_LEN): This macro deleted.  Callers changed to use
7208         CHAR_BYTES.
7209         (FETCH_STRING_CHAR_ADVANCE): Check multibyteness of STRING.
7210         (FETCH_STRING_CHAR_ADVANCE_NO_CHECK): New macro.
7211         (FETCH_CHAR_ADVANCE): Check multibyteness of the current buffer.
7213         * coding.c (ONE_MORE_BYTE, TWO_MORE_BYTES): Set coding->result to
7214         CODING_FINISH_INSUFFICIENT_SRC if there's not enough source.
7215         (ONE_MORE_CHAR, EMIT_CHAR, EMIT_ONE_BYTE, EMIT_TWO_BYTE,
7216         EMIT_BYTES): New macros.
7217         (THREE_MORE_BYTES, DECODE_CHARACTER_ASCII,
7218         DECODE_CHARACTER_DIMENSION1, DECODE_CHARACTER_DIMENSION2): These
7219         macros deleted.
7220         (CHECK_CODE_RANGE_A0_FF): This macro deleted.
7221         (detect_coding_emacs_mule): Use UNIBYTE_STR_AS_MULTIBYTE_P to
7222         check the validity of multibyte sequence.
7223         (decode_coding_emacs_mule): New function.
7224         (encode_coding_emacs_mule): New macro.
7225         (detect_coding_iso2022): Use ONE_MORE_BYTE to fetch a byte from
7226         the source.
7227         (DECODE_ISO_CHARACTER): Just return a character code.
7228         (DECODE_COMPOSITION_START): Set coding->result instead of result.
7229         (decode_coding_iso2022, decode_coding_sjis_big5, decode_eol): Use
7230         EMIT_CHAR to produced decoded characters.  Exit the loop only by
7231         macros ONE_MORE_BYTE or EMIT_CHAR.  Don't handle the case of last
7232         block here.
7233         (ENCODE_ISO_CHARACTER): Don't translate character here.  Produce
7234         only position codes for an invalid character.
7235         (encode_designation_at_bol): Return new destination pointer.  5th
7236         arg DSTP is changed to DST.
7237         (encode_coding_iso2022, decode_coding_sjis_big5): Get a character
7238         from the source by ONE_MORE_CHAR.  Don't handle the case of last
7239         block here.
7240         (DECODE_SJIS_BIG5_CHARACTER, ENCODE_SJIS_BIG5_CHARACTER): These
7241         macros deleted.
7242         (detect_coding_sjis, detect_coding_big5, detect_coding_utf_8,
7243         detect_coding_utf_16, detect_coding_ccl): Use ONE_MORE_BYTE and
7244         TWO_MORE_BYTES to fetch a byte from the source.
7245         (encode_eol): Pay attention to coding->src_multibyte.
7246         (detect_coding, detect_eol): Preserve members src_multibyte and
7247         dst_multibyte.
7248         (DECODING_BUFFER_MAG): Return 2 even for coding_type_raw_text.
7249         (encoding_buffer_size): Set magnification to 3 for all coding
7250         systems that require encoding.
7251         (ccl_coding_driver): For decoding, be sure that the result is
7252         valid multibyte sequence.
7253         (decode_coding): Initialize coding->errors and coding->result.
7254         For emacs-mule, call decode_coding_emacs_mule.  For no-conversion
7255         and raw-text, always call decode_eol.  Handle the case of last
7256         block here.  If not coding->dst_multibyte, convert the resulting
7257         sequence to unibyte.
7258         (encode_coding): Initialize coding->errors and coding->result.
7259         For emacs-mule, call encode_coding_emacs_mule.  For no-conversion
7260         and raw-text, always call encode_eol.  Handle the case of last
7261         block here.
7262         (shrink_decoding_region, shrink_encoding_region): Detect cases
7263         that we can't skip data more rigidly.
7264         (code_convert_region): Setup src_multibyte and dst_multibyte
7265         members of coding.  For decoding, if the buffer is multibyte,
7266         convert the source sequence to unibyte in advance.  For encoding,
7267         if the buffer is multibyte, convert the resulting sequence to
7268         multibyte afterward.
7269         (run_pre_post_conversion_on_str): New function.
7270         (code_convert_string): Deleted and divided into the following two.
7271         (decode_coding_string, encode_coding_string): New functions.
7272         (code_convert_string1, code_convert_string_norecord): Call one of
7273         above.
7274         (Fdecode_sjis_char, Fdecode_big5_char): Use MAKE_CHAR instead of
7275         MAKE_NON_ASCII_CHAR.
7276         (Fset_terminal_coding_system_internal,
7277         Fset_safe_terminal_coding_system_internal): Setup src_multibyte
7278         and dst_multibyte members.
7279         (init_coding_once): Initialize iso_code_class with new enum
7280         ISO_control_0 and ISO_control_1.
7282         * coding.h (enum iso_code_class_type): Member ISO_control_code is
7283         devided into ISO_control_0 and ISO_control_1.
7284         (struct coding_system): New members src_multibyte, dst_multibyte,
7285         errors, and result.  Delete member fake_multibyte.
7286         (CODING_REQUIRE_DECODING): Return 1 if coding->dst_multibyte is
7287         nonzero.
7288         (CODING_REQUIRE_ENCODING): Return 1 if coding->src_multibyte is
7289         nonzero.
7291         * data.c (Faref): Use SPLIT_CHAR instead of SPLIT_NON_ASCII_CHAR.
7292         (Faset): Likewise.
7294         * editfns.c (Fformat): Be sure to convert 8-bit characters to
7295         multibyte form.
7296         (Ftranspose_region) [BYTE_COMBINING_DEBUG]: Abort if byte
7297         combining occurs.
7298         (Ftranspose_region): Delete codes for handling byte combining.
7300         * fileio.c (Finsert_file_contents): Setup src_multibyte and
7301         dst_multibyte members of coding.  On handling REPLACE on unibyte
7302         buffer, convert the result of decode_coding to unibyte.  On
7303         inserting into a mutibyte buffer, always call code_convert_region.
7304         (e_write): Setup coding->src_multibyte according to the
7305         multibyteness of the source (buffer or string).
7307         * fns.c (concat): Handle 8-bit characters correctly.
7308         (Fstring_as_unibyte): Be sure to make all 8-bit characters in
7309         unibyte in the result.
7310         (Fstring_as_multibyte): Be sure to make all 8-bit characters in
7311         valid multibyte form in the result.
7312         (map_char_table): Use MAKE_CHAR instead of MAKE_NON_ASCII_CHAR.
7313         (Fbase64_encode_region, Fbase64_encode_string): If base64_encode_1
7314         return -1, signal an error.
7315         (base64_encode_1): New arg MULTIBYTE.  Get each character by
7316         CHAR_STRING_AND_LENGTH if MULTIBYTE is nonzero.  If a multibyte
7317         character is found, return -1.
7318         (Fbase64_decode_region): Delete codes for handling byte-combining.
7319         Treat each decoded byte as a unibyte character.
7320         (Fbase64_decode_string): Return unibyte string.
7321         (Fcompare_strings, concat, string_byte_to_char): Use
7322         FETCH_STRING_CHAR_ADVANCE_NO_CHECK instead off
7323         FETCH_STRING_CHAR_ADVANCE.
7324         (Fstring_lessp): Use FETCH_STRING_CHAR_ADVANCE unconditionally.
7325         (mapcar1): If SEQ is string, always use FETCH_STRING_CHAR_ADVANCE.
7327         * fontset.c (fontset_ref): Use SPLIT_CHAR instead of
7328         SPLIT_NON_ASCII_CHAR.
7329         (fontset_ref_via_base, fontset_set): Likewise
7331         * insdel.c (adjust_markers_for_record_delete): Deleted.
7332         (adjust_markers_for_insert): Argument changed.  Caller changed.
7333         (adjust_markers_for_replace): Likewise.
7334         (ADJUST_CHAR_POS, combine_bytes, byte_combining_error,
7335         CHECK_BYTE_COMBINING_FOR_INSERT): Deleted.
7336         (copy_text): Delete unused local varialbe c_save.  For converting
7337         to multibyte, be sure to make all 8-bit characters in valid
7338         multibyte form.
7339         (count_size_as_multibyte): Handle 8-bit characters correctly.
7340         (insert_1_both, insert_from_string_1, insert_from_buffer_1,
7341         adjust_after_replace, replace_range, del_range_2)
7342         [BYTE_COMBINING_DEBUG]: Abort if byte combining occurs.
7343         (insert_1_both, insert_from_string_1, insert_from_buffer_1,
7344         adjust_after_replace, replace_range, del_range_2) Delete codes for
7345         handling byte combining.
7346         (adjust_before_replace): Deleted.
7348         * keymap.c (Fsingle_key_description): Use SPLIT_CHAR instead of
7349         SPLIT_NON_ASCII_CHAR.
7350         (describe_vector): Use MAKE_CHAR instead of MAKE_NON_ASCII_CHAR.
7351         (Faccessible_keymaps): Use FETCH_STRING_CHAR_ADVANCE
7352         unconditionally.
7353         (Fkey_description): Likewise.
7355         * lread.c (read1): On reading multibyte string, be sure to make
7356         all 8-bit chararacters in valid multibyte form.
7357         (readchar): Use FETCH_STRING_CHAR_ADVANCE unconditionally.
7359         * print.c (print_object): Use FETCH_STRING_CHAR_ADVANCE
7360         unconditionally.
7362         * process.c (Fstart_process): GCPRO current_dir before calling
7363         Ffind_operation_coding_system.  Encode arguments here.
7364         (create_process): Don't encode arguments here.  Setup
7365         src_multibyte and dst_multibyte members of struct coding.
7366         (read_process_output): Setup src_multibyte and dst_multibyte
7367         members of struct coding.  If the output is to multibyte buffer,
7368         always decode the output of the process.  Adjust the
7369         representation of 8-bit characters to the multibyteness of the
7370         output.
7371         (send_process): Setup coding->src_multibyte according to the
7372         multibyteness of the source.
7374         * search.c (wordify): Use FETCH_STRING_CHAR_ADVANCE
7375         unconditionally.
7376         (Freplace_match): Use FETCH_STRING_CHAR_ADVANCE and
7377         FETCH_STRING_CHAR_ADVANCE_NO_CHECK appropriately.
7379         * term.c (produce_special_glyphs): Use CHAR_BYTES instead of
7380         CHAR_LEN.
7382         * w16select.c (Fw16_set_clipboard_data): Setup members
7383         src_multibyte and dst_multibyte of coding.  Adjusted for the
7384         change for find_charset_in_str.
7385         (Fw16_get_clipboard_data): Likewise.
7387         * w32fns.c (w32_to_x_font): Setup members src_multibyte and
7388         dst_multibyte of coding.
7389         (x_to_w32_font): Likewise.
7391         * w32select.c (Fw32_set_clipboard_data): Setup members
7392         src_multibyte and dst_multibyte of coding.  Adjusted for the
7393         change for find_charset_in_str.
7394         (Fw32_get_clipboard_data): Likewise.
7396         * xdisp.c (get_next_display_element): Handle 8-bit characters
7397         correctly.
7398         (next_element_from_display_vector): Use CHAR_BYTES instead of
7399         CHAR_LEN.
7400         (disp_char_vector): Use SPLIT_CHAR instead of
7401         SPLIT_NON_ASCII_CHAR.
7403         * xselect.c (selection_data_to_lisp_data): Setup members
7404         src_multibyte and dst_multibyte of coding.  Adjusted for the
7405         change for find_charset_in_str.
7406         (lisp_data_to_selection_data): Likewise.
7408 2000-05-19  Gerd Moellmann  <gerd@gnu.org>
7410         * buffer.c (Fbury_buffer): Avoid trouble from burying a killed
7411         buffer.
7413         * dispextern.h (Vimage_types): Add extern declaration.
7415         * xdisp.c (Vimage_types): Moved here from xfns.c.
7416         (syms_of_xdisp): Move `image-types' variable here from xfns.c.
7418         * xfns.c (Vimages_types): Moved to xdisp.c.
7419         (syms_of_xfns): Move `image-types' to xdisp.c.
7421         * w32fns.c (Vimage_types): Removed.
7422         (syms_of_w32fns): Remove `image-types'.
7424 2000-05-18  Kenichi Handa  <handa@etl.go.jp>
7426         * fns.c (map_char_table): Pay attention to character number of
7427         charset.  Check the validity of charset at the first level.   For
7428         leaf nodes that has nil value, call C_FUNCTION or FUNCTION with
7429         the default value.
7431         * fontset.c: Include "buffer.h".
7432         (fs_load_font): If the face has fontset, record the face ID in
7433         that fontset.
7434         (Finternal_char_font): New function.
7435         (accumulate_font_info): New function.
7436         (Ffontset_info): Rewritten for the new fontset implementation.
7437         (syms_of_fontset): Register Vdefault_fontset in the first element
7438         of Vfontset_table.  Include Vdefault_fontset in
7439         Vfontset_alias_alist.  Declare `internal-char-font' as a Lisp
7440         function.
7442 2000-05-16  Dave Love  <fx@gnu.org>
7444         * m/iris5d.h: Deleted -- unused.
7446 2000-05-16  Gerd Moellmann  <gerd@gnu.org>
7448         * xdisp.c, w32.c, print.c, msdos.c, emacs.c: Use the term
7449         `invalid' instead of `illegal'.
7451         * indent.c (Fmove_to_column): When ending within a tab, insert
7452         spaces first so that markers at the end of the tab get adjusted.
7454         * frame.c (frames_bury_buffer): Don't add a buffer to the frame's
7455         buffer list that wasn't selected in that frame.
7457         * filelock.c (get_boot_time): To obtain an 8 char file name, which
7458         is needed on mescaline, use a 2 char prefix, and call
7459         make_temp_name with second arg non-zero.
7461         * fileio.c (make_temp_name): New function, extracted from
7462         Fmake_temp_name.
7463         (Fmake_temp_name): Use it.
7465 2000-05-15  Eli Zaretskii  <eliz@is.elta.co.il>
7467         * window.c (coordinates_in_window): Subtract 1 when computing
7468         right_x.
7470 2000-05-15  Gerd Moellmann  <gerd@gnu.org>
7472         * Makefile.in (lisp): Add env.elc.
7474         * callproc.c (Fgetenv_internal): Renamed from Fgetenv.
7476 2000-05-12  Gerd Moellmann  <gerd@gnu.org>
7478         * search.c (Freplace_match): Handle case of `\N' in the
7479         replacement when there's no group N.
7481 2000-05-11  Gerd Moellmann  <gerd@gnu.org>
7483         * xdisp.c (add_to_log): Don't pass the terminating NUL byte
7484         of the message to message_dolog.
7486         * keyboard.c (read_char): Don't clear current message for help
7487         events; let the code handling help events handle this.  Change
7488         code detecting help events that should be ignored.
7490         * xdisp.c (handle_single_display_prop): Don't try to set PT if
7491         we're interating over a string.
7493 2000-05-09  Dave Love  <fx@gnu.org>
7495         * fileio.c (Fwrite_region): If APPEND arg is an integer, seek to
7496         that offset before writing.  Move gcpro region past call of
7497         Ffile_regular_p.
7499 2000-05-04  Dave Love  <fx@gnu.org>
7501         * buffer.c (syms_of_buffer) [auto-fill-function]: Doc fix.
7503 2000-05-04  Gerd Moellmann  <gerd@gnu.org>
7505         * insdel.c (insert_from_buffer_1): Adjust FROM position by number
7506         of inserted characters when BUF equals the current buffer, and PT
7507         is in front of or equal to FROM.
7509 2000-05-03  Gerd Moellmann  <gerd@gnu.org>
7511         * xdisp.c (handle_single_display_prop): If display property value
7512         is invalid, or something not supported on the frame, restore
7513         iterator's position to what it was initially.  Make sure to return
7514         0 for invalid and unsupported property values.
7516         * xterm.c (x_produce_glyphs) <composite chars>: Handle case
7517         that x_per_char_metric returns null.
7519 2000-05-02  Gerd Moellmann  <gerd@gnu.org>
7521         * xterm.h (struct face): Add forward declaration.
7522         (struct image): Ditto.
7523         (image_ascent): Add prototype.
7525         * xterm.c (x_produce_image_glyph, x_draw_image_foreground)
7526         (x_draw_image_relief, x_draw_image_foreground_1): Call function
7527         image_ascent instead of using IMAGE_ASCENT.
7529         * dispextern.h (DEFAULT_IMAGE_HEIGHT): New macro.
7530         (IMAGE_ASCENT): Removed.
7532         * xfns.c (Qcenter): New variable.
7533         (enum image_value_type): Add IMAGE_ASCENT_VALUE.
7534         (parse_image_spec): Handle IMAGE_ASCENT_VALUE.
7535         (image_ascent): New function.
7536         (lookup_image): Recognize `:ascent center'.
7537         (xbm_format, xpm_format, pbm_format, png_format, jpeg_format)
7538         (tiff_format, gif_format, gs_format): Use IMAGE_ASCENT_VALUE.
7539         (xbm_load): Don't set image's ascent here.
7540         (xbm_image_p, xpm_image_p, pbm_image_p, png_image_p)
7541         (jpeg_image_p, tiff_image_p, gif_image_p, gs_image_p): Don't
7542         check ascent values here.
7543         (Fimagep, Flookup_image [GLYPH_DEBUG]: Removed.
7544         (syms_of_xfns) [GLYPH_DEBUG]: Don't defsubr removed functions.
7545         (syms_of_xfns): Initialize Qcenter.
7547         * eval.c (Fsignal): If lisp_eval_depth or spepdl_size are near
7548         to the limits, increase the limits.
7550 2000-05-01  Kenichi Handa  <handa@etl.go.jp>
7552         * fontset.c (fs_load_font): By default, use 0x00..0x7f for ASCII.
7553         Check Vfont_encoding_alist against the full name of the opened
7554         font.
7556 2000-04-28  Gerd Moellmann  <gerd@gnu.org>
7558         * xdisp.c (make_cursor_line_fully_visible): Handle case of rows
7559         taller than the window.
7561 2000-04-28  Kenichi Handa  <handa@etl.go.jp>
7563         * xfaces.c (realize_x_face): Fix the argument of the second
7564         xassert.  BASE_FACE may not be a face for ASCII.
7566 2000-04-27  Gerd Moellmann  <gerd@gnu.org>
7568         * print.c (print_object): Treat print-length < 0 as nil.
7570         * Makefile.in (termcapobj): Don't use TERMCAP_OBJ.
7572         * s/freebsd.h (TERMCAP_OBJ): Removed.
7573         (LIBS_TERMCAP): Don't define for __FreeBSD_version >= 400000.
7575         * lread.c (read1): Don't treat period followed by certain
7576         characters as symbol start.
7578         * xfns.c (slurp_file): New function.
7579         (xbm_image_p): Handle case of in-memory XBM files.
7580         (xbm_scan): Rewritten to work on memory buffers instead of files.
7581         (xbm_read_bitmap_data): Renamed from xbm_read_bitmap_file_data.
7582         Work on memory buffers instead of files.  If DATA is null test
7583         if buffer looks like an in-memory XBM file.
7584         (xbm_load_image): Renamed from xbm_load_image_file.  Work on
7585         memory buffers instead of files.
7586         (xbm_file_p): New function.
7587         (xbm_load): Accept :data DATA where DATA is an in-memory XBM file.
7589         * lread.c (end_of_file_error): New function.
7590         (read1): Call it instead of signaling `end-of-file' directly.
7592         * print.c (print_error_message): Print data of `end-of-file'
7593         with Fprinc instead of Fprin1.
7595 2000-04-26  Ken Raeburn  <raeburn@gnu.org>
7597         * window.c (freeze_window_start): Check that minibuffer scroll
7598         window isn't nil before extracting the window structure pointer
7599         from it.
7601         * undo.c (record_delete): If we hit the end of the undo list, stop
7602         picking elements apart.
7604 2000-04-26  Gerd Moellmann  <gerd@gnu.org>
7606         * xdisp.c (display_line): If lines are continued, restore
7607         iterator's ascent/descent information to the values before the
7608         first glyph not fitting on the line.
7610 2000-04-25  Gerd Moellmann  <gerd@gnu.org>
7612         * xdisp.c (try_window_id) <all changes above window start>: Adjust
7613         positions in glyph matrix.  Don't compute new window end
7614         positions.
7616         * dispnew.c (increment_matrix_positions): Renamed from
7617         increment_glyph_matrix_buffer_positions.
7618         (increment_row_positions): Renamed from
7619         increment_glyph_row_buffer_positions.
7621         * dispextern.h: Change names of renamed functions from dispnew.c
7622         in prototypes.
7624 2000-04-24  Gerd Moellmann  <gerd@gnu.org>
7626         * fileio.c (Fdo_auto_save): Create directories for auto-save
7627         list file if necessary.
7629         * xdisp.c (init_iterator): Set iterator's extra_line_spacing
7630         from buffer or frame.
7631         (automatic_hscrolling_p): New variable.
7632         (hscroll_windows): Scroll windows horizontally only if automatic
7633         hscrolling is allowed.
7634         (syms_of_xdisp): New variable `automatic-hscrolling'.
7636         * frame.h (struct frame): Add member extra_line_spacing.
7638         * xfns.c (x_set_line_spacing): New function.
7639         (Fx_create_frame): Set line spacing from resources.
7640         (Qline_spacing): New variable.
7641         (syms_of_xfns): Initialize Qline_spacing.
7643         * emacs.c (USAGE2): Add `--line-spacing' and `-lsp'.
7645         * buffer.c (init_buffer_once): Handle extra_line_spacing.
7646         (syms_of_buffer): Add `default-line-spacing' and `line-spacing'.
7647         (reset_buffer): Don't initialize extra2 and extra3.  Initialize
7648         extra_line_spacing from default value.
7649         (init_buffer_once): Initialize default value of extra_line_spacing.
7651         * buffer.h (struct buffer): Add extra_line_spacing, remove extra2
7652         and extra3.
7654         * xterm.c (x_produce_glyphs): Remove reference to struct it's
7655         prompt_width.  Add extra line spacing.
7657         * term.c (produce_glyphs): Remove reference to struct it's
7658         prompt_width.
7660         * dispextern.h (struct it): Remove member prompt_width, add
7661         extra_line_spacing.
7663 2000-04-22  Gerd Moellmann  <gerd@gnu.org>
7665         * dispnew.c (update_frame_line): When writing a whole line, make
7666         sure cursor is in the right row afterwards, otherwise a use of
7667         capability `ch' in cmgoto might leave the cursor in the row below.
7669 2000-04-21  Gerd Moellmann  <gerd@gnu.org>
7671         * lisp.h (struct Lisp_Buffer_Cons): Remove.
7673         * keyboard.c (timer_check): Fix typo in comment.
7675 2000-04-21  Kenichi Handa  <handa@etl.go.jp>
7677         * fontset.c (Fset_fontset_font): Fix docstring.  Local variable
7678         name change: ch -> character.
7680 2000-04-20  Gerd Moellmann  <gerd@gnu.org>
7682         * keyboard.c (echo_message_buffer): New variable.
7683         (echo_now): Set echo_message_buffer to the echo area buffer used
7684         to display the echo.
7685         (cancel_echoing): Reset echo_message_buffer to nil.
7686         (read_char): Code rewritten that handles canceling an echo or
7687         echoing a dash, respectively.
7689         * fileio.c (Ffile_writable_p) [WINDOWSNT]: Return nil if parent
7690         directory doesn't exist.
7692 2000-04-19  Dave Love  <fx@gnu.org>
7694         * fns.c (syms_of_fns): Defsubr mapc.
7695         (concat): Don't allow numeric args.
7696         (Fconcat): Doc change.
7698 2000-04-19  Stefan Monnier  <monnier@cs.yale.edu>
7700         * regex.c (re_match_2_internal): Don't shorten the strings anymore,
7701         instead define end_match(1|2) more carefully.
7702         Use GET_CHAR_BEFORE_2 for `begline'.
7704 2000-04-19  Gerd Moellmann  <gerd@gnu.org>
7706         * frame.h (SELECTED_FRAME): Change definition to compile cleanly
7707         on 64-bit systems where NULL is defined as `0'.
7709         * xdisp.c (with_echo_area_buffer): Add more `int' parameters for
7710         the `variable argument list' to make it work on Alpha.
7712         * m/alpha.h (_LP64) [!_LP64]: Define.
7713         (ORDINARY_LINK): Define for NetBSD.
7715         * m/macppc.h (ORDINARY_LINK): Define for NetBSD.
7717 2000-04-19  Dave Love  <fx@gnu.org>
7719         * s/bsd386.h, s/freebsd.h, s/gnu.h, s/netbsd.h: Revert 2000-04-14
7720         change.
7722         * Makefile.in (LIBS): Don't use.
7723         (GETLOADAVG_OBJ): Define again.
7724         (otherobj): Add GETLOADAVG_OBJ.
7726         * buffer.c (Fmake_indirect_buffer): Escape newline in doc.
7728 2000-04-18  Gerd Moellmann  <gerd@gnu.org>
7730         * lread.c (read_filtered_event): Cancel and start busy cursor.
7732         * xterm.c (x_produce_glyphs) <ASCII chars>: Take into account
7733         that the per-character metrics may be null.
7735 2000-04-17  Gerd Moellmann  <gerd@gnu.org>
7737         * buffer.c (clone_per_buffer_values): New function.
7738         (Fmake_indirect_buffer): Add optional argument CLONE.  Call
7739         clone_per_buffer_values if CLONE is not nil.
7741         * xfaces.c (Ftty_suppress_bold_inverse_default_colors): Doc fix.
7743 2000-04-16  Dave Love  <fx@gnu.org>
7745         * Makefile.in: Remove obsolete localcpp stuff.
7746         (GETLOADAVG_OBJ): Don't define.
7747         (obj): Move LIBOBJS...
7748         (otherobj): ... to here.
7749         (MSDOS_OBJ): Convert to make variable -- preprocessing zapped
7750         whitespace-only lines after the continuation (Irix).
7752 2000-04-14  Gerd Moellmann  <gerd@gnu.org>
7754         * xfns.c (xpm_load) [DEBUG_X_COLORS]: Register colors.
7756         * s/freebsd.h (LD_SWITCH_SYSTEM): Add `-L /usr/local/lib'.
7758 2000-04-14  Dave Love  <fx@gnu.org>
7760         * s/aix3-1.h, s/bsd4-2.h, s/bsd4-3.h, s/cxux.h, s/dgux.h, s/gnu.h:
7761         * s/hpux.h, s/iris3-5.h, s/iris3-6.h, s/irix3-3.h, s/rtu.h:
7762         * s/unipl5-0.h, s/unipl5-2.h, s/usg5-0.h, s/usg5-2-2.h, s/usg5-2.h:
7763         * s/usg5-3.h, s/xenix.h, s/umax.h: Don't define autoconfiscated
7764         NLIST_STRUCT.
7766         * s/bsd386.h, s/freebsd.h, s/gnu.h, s/netbsd.h: Don't define
7767         autoconfiscated HAVE_GETLOADAVG.
7769         * s/nextstep.h, s/sco4.h, s/sco5.h: Don't define autoconfiscated
7770         BROKEN_MKTIME.
7772 2000-04-14  Gerd Moellmann  <gerd@gnu.org>
7774         * filelock.c (MAKE_LOCK_NAME): Allocate 2 more bytes.
7775         (fill_in_lock_file_name): Avoid existing files that aren't
7776         links.
7778 2000-04-14  Dave Love  <fx@gnu.org>
7780         * Makefile.in (LIBS, LIBOBJS): New variable.
7781         (INTERVAL_SRC): Convert to make variable.
7782         (INTERVAL_OBJ, MKTIME_OBJ, FLOAT_SUPPORT, FACE_SUPPORT)
7783         (HAVE_X_WINDOWS, OBJECTS_SYSTEM): Remove.
7784         (obj): Substitute INTERVAL_OBJ, add MKTIME_OBJ, GETLOADAVG_OBJ and
7785         add LIBOBJS.
7786         (SOME_MACHINE_OBJECTS): Remove interval stuff.
7787         (lisp): Substitute FACE_SUPPORT, FLOAT_SUP.
7788         (shortlisp): Add facemenu, float-sup, frame.
7789         (SOME_MACHINE_LISP): Remove them from here.
7790         (LIBES): Change unused LDLIBS to autoconf LIBS.
7792         * config.in: Add BROKEN_MKTIME, NLIST_STRUCT, NLIST_NAME_UNION.
7794 2000-04-14  Kenichi Handa  <handa@etl.go.jp>
7796         * composite.c (update_compositions): If FROM and TO are not in a
7797         valid range, do nothing.
7799 2000-04-13  Gerd Moellmann  <gerd@gnu.org>
7801         * tparam.c (tparam1): Abort when encountering an unknown
7802         `%'-specifier.
7804         * s/freebsd.h (TERMCAP_OBJ) [__FreeBSD__ >= 4]: Define as
7805         terminfo.o.
7807         * Makefile.in (termcapobj) [LIBS_TERMCAP && TERMCAP_OBJ]: Define
7808         as TERMCAP_OBJ.
7810 2000-04-13  Eli Zaretskii  <eliz@is.elta.co.il>
7812         * fileio.c (a_write): Remove redundant semi-colons.
7813         (e_write): Return -1 if failed to write all the data.
7814         This fixes the changes made at 1999-12-15.
7816 2000-04-12  Dave Love  <fx@gnu.org>
7818         * fns.c (mapcar1): Test for null vals to support mapc.
7819         (Fmapc): New function.
7821 2000-04-12  Eli Zaretskii  <eliz@is.elta.co.il>
7823         * msdos.c (NUM_MOUSE_BUTTONS): Define.
7824         (IT_frame_up_to_date): Support the buffer local value of
7825         cursor-type, if defined.
7827 2000-04-10  Dave Love  <fx@gnu.org>
7829         * editfns.c (preceding-char, following-char): Doc fix.
7831 2000-04-10  Ken Raeburn  <raeburn@gnu.org>
7833         * Makefile.in (temacs): Revert 2000-03-12 change.
7835 2000-04-10  Jason Rumney  <jasonr@gnu.org>
7837         * xfaces.c (realize_face): Change FRAME_X_P to FRAME_WINDOW_P.
7839 2000-04-10  Gerd Moellmann  <gerd@gnu.org>
7841         * xdisp.c (setup_echo_area_for_printing): Choose an echo
7842         area buffer, if it's not set up yet.
7844         * indent.c (compute_motion): Set immediate_quit.
7846 2000-04-09  Gerd Moellmann  <gerd@gnu.org>
7848         * xfaces.c (tty_suppress_bold_inverse_default_colors_p): New
7849         variable.
7850         (realize_tty_face): Suppress boldness if colors are the inverse of
7851         the default colors, and tty_suppress_bold_inverse_default_colors_p
7852         is set.
7853         (Ftty_suppress_bold_inverse_default_colors): New function.
7854         (syms_of_xfaces): Defsubr it.
7856         * buffer.c (Frestore_buffer_modified_p): New function.
7857         (syms_of_buffer): Defsubr it.
7859 2000-04-08  Ken Raeburn  <raeburn@gnu.org>
7861         * charset.c (Fmake_char_internal): CHAR_COMPONENTS_VALID_P takes a
7862         charset id (int) argument, not a charset (Lisp_Object).
7864         * coding.h (code_convert_string): Declare.
7865         * coding.c (code_convert_string_norecord): Pass an int, not a lisp
7866         object, as the fourth argument to code_convert_string.
7868         * fontset.c (make_fontset_for_ascii_face): Use XINT on return
7869         value.
7870         (Fset_fontset_font): Use EQ to compare lisp objects.
7872 2000-04-05  Ken Raeburn  <raeburn@gnu.org>
7874         * intervals.h (SET_INTERVAL_PARENT): Use INT_LISPLIKE to test for
7875         a pointer that looks like a lisp object.
7876         (SET_INTERVAL_OBJECT): Don't explicitly compare the object with
7877         zero, instead see whether it's an integer object, since they can't
7878         have intervals.
7879         (GET_INTERVAL_OBJECT): Simply assign to the destination.
7881         * dispnew.c (allocate_matrices_for_frame_redisplay,
7882         direct_output_forward_char): Use X(U)INT and make_number as needed
7883         to convert between (unsigned) int values and lisp integers.
7884         * keyboard.c (read_key_sequence): Likewise.
7885         * lread.c (substitute_object_recurse): Likewise.
7886         * fns.c (concat, hash_lookup, hash_remove): Likewise.
7887         * minibuf.c (do_completion, Fminibuffer_complete_word,
7888         Fminibuffer_completion_help): Likewise.
7889         * term.c (produce_special_glyphs): Likewise.
7891         * fileio.c (Fwrite_region): Use EQ when comparing lisp objects.
7892         * print.c (print_preprocess, print_object): Likewise.
7894         * search.c (compile_pattern): Use NILP when checking for nil.
7896         * lisp.h (make_number) [!NO_UNION_TYPE && __GNUC__ >= 2 &&
7897         __OPTIMIZE__]: Provide a GNU C macro version that handles
7898         lisp-object unions.
7899         (XSET) [!NO_UNION_TYPE]: Set the value field first, then the type
7900         field, to better cope with ENABLE_CHECKING and calls that modify a
7901         Lisp_Object using its old value.
7903 2000-04-04  Gerd Moellmann  <gerd@gnu.org>
7905         * window.c (compare_window_configurations): Signal an error
7906         if parameters C1 or C2 aren't window configurations.
7908         * bytecode.c (Fbyte_code): Add a bunch of BEFORE_POTENTIAL_GC/
7909         AFTER_POTENTIAL_GC calls around calls to functions that can
7910         signal an error and thus invoke the debugger.
7912 2000-04-03  Gerd Moellmann  <gerd@gnu.org>
7914         * fns.c (Fbase64_decode_region, Fbase64_decode_string): Signal
7915         an error if decoding fails.
7917         * keyboard.c (lispy_mouse_names): Variable removed.
7918         (Vlispy_mouse_stem): New variable.
7919         (syms_of_keyboard): Initialize Vlispy_mouse_stem.
7920         (make_lispy_event) <mouse_click, scroll_bar_click>: Don't abort
7921         for any mouse button number.  Increase size of mouse_syms and
7922         button_down_location as needed.  Call modify_event_symbol with
7923         different arguments.
7924         (make_lispy_event) <scroll_bar_click> [USE_TOOLKIT_SCROLL_BARS]:
7925         Call modify_event_symbol with different arguments.
7926         (make_lispy_event) <w32_scroll_bar_click> [WINDOWSNT]: Don't abort
7927         for any button number.  Call modify_event_symbol with different
7928         arguments.
7929         (modify_event_symbol): Rename NAME_ALIST to NAME_ALIST_OR_STEM.
7930         Accept a string for NAME_ALIST_OR_STEM.
7932         * lisp.h (larger_vector): Add prototype.
7934         * fns.c (larger_vector): Make externally visible.
7936         * termhooks.h (NUM_MOUSE_BUTTONS): Removed.
7938 2000-04-02  Stefan Monnier  <monnier@cs.yale.edu>
7940         * regex.c (PTR_TO_OFFSET) [!emacs]: Remove.
7941         (RE_MULTIBYTE_P, RE_STRING_CHAR_AND_LENGTH): New macros.
7942         (GET_CHAR_BEFORE_2): Moved from charset.h plus fixed minor bug when
7943         we are between str1 and str2.
7944         (MAX_MULTIBYTE_LENGTH, CHAR_STRING) [!emacs]: Provide trivial default.
7945         (PATFETCH): Use `TRANSLATE'.
7946         (PATFETCH_RAW): Fetch multibyte char if applicable.
7947         (PATUNFETCH): Remove.
7948         (regex_compile): Rely on PATFETCH to do most of the multibyte magic.
7949         When writing a char, write it directly into the pattern buffer rather
7950         than going needlessly through a temp char-array.
7951         (re_match_2_internal): Similarly, rely on RE_STRING_CHAR to do the
7952         multibyte magic and remove the useless `#ifdef emacs'.
7953         (bcmp_translate): Don't compare as multibyte chars when in a unibyte
7954         buffer.
7956         * regex.h (struct re_pattern_buffer): Make field `multibyte'
7957         conditional on `emacs'.
7959         * charset.h (GET_CHAR_BEFORE_2): Moved to regex.c.
7961 2000-04-01  Ken Raeburn  <raeburn@gnu.org>
7963         * alloc.c (MARK_STRING, UNMARK_STRING, STRING_MARKED_P): Expand
7964         non-union-type versions of XMARK and friends here, because XMARK
7965         and friends won't work on an integer field if NO_UNION_TYPE is not
7966         defined.
7967         (make_number): Define as a function if it's not defined as a
7968         macro.
7970         * composite.c (run_composite_function): Use NILP when checking for
7971         nil.
7972         (syms_of_composite): Delete local var NARGS, pass an int as first
7973         argument to Fmake_hash_table.
7975         * editfns.c (text_property_stickiness): Use NILP to test
7976         Lisp_Object boolean value.
7977         (Fmessage_or_box): Don't use NILP to test int variable.
7978         (Fformat): Use a temporary variable to avoid ENABLE_CHECKING
7979         problems reading from and changing the same lisp value in an
7980         XSETSTRING call.
7982 2000-04-01  Gerd Moellmann  <gerd@gnu.org>
7984         * term.c (TN_no_color_video): New variable.
7985         (term_init): Intitialize TN_no_color_video.
7986         (enum no_color_bit): New enumeration.
7987         (MAY_USE_WITH_COLORS_P): New macro.
7988         (turn_on_face): Use it to determine if attributes may be used
7989         combined with colors.
7991 2000-04-01  Ken Raeburn  <raeburn@gnu.org>
7993         * window.c (CURBEG, CURSIZE): Don't overload lisp object lvalues
7994         with int lvalues via casts; instead, just yield lisp object
7995         lvalues.
7996         (enlarge_window): Variable sizep now points to Lisp_Object.  Use
7997         proper accessor macros.
7998         (shrink_window_lowest_first): w->top is Lisp_Object; use XINT.
7999         (grow_mini_window): Fix typo getting int value of root->height.
8001         * xdisp.c (compute_string_pos): Fix order of arguments to
8002         string_pos_nchars_ahead.
8003         (handle_fontified_prop, add_to_log): Pass int, not Lisp_Object, as
8004         count arg to variable-arg routines like Frun_hook_with_args and
8005         Fformat.
8006         (back_to_previous_visible_line_start)
8007         (build_desired_tool_bar_string): Pass Lisp_Object, not int, to
8008         fixed-arg routines like Fget_char_property and Fmake_string.
8009         (reconsider_clip_changes): Use XINT when comparing integer lisp
8010         objects, or passing them as int arguments.
8011         (mark_window_display_accurate, insert_left_trunc_glyphs)
8012         (append_space, extend_face_to_end_of_line): Use make_number when
8013         storing or passing integer values as lisp objects.
8014         (set_cursor_from_row, highlight_trailing_whitespace): Use
8015         INTEGERP, not implicit test against zero, for glyph object.
8016         (try_window_id): Don't use make_number when we want an int value.
8018         * xfaces.c (xlfd_symbolic_value): Make last argument a
8019         Lisp_Object, to be consistent with callers.
8020         (Fbitmap_spec_p): Use XINT to get numeric value of height.
8021         (lface_hash): Apply XFASTINT to lisp values before folding in.
8023         * xfns.c (Fx_show_tip): Use make_number to get lisp objects to
8024         fill in window width and height.  Pass an int, not a lisp object,
8025         as first arg to Finsert.
8027 2000-04-01  Gerd Moellmann  <gerd@gnu.org>
8029         * xfaces.c (realize_basic_faces): Block input while realizing
8030         the faces.
8032         * keyboard.c (lispy_mouse_names): Add additional mouse names.
8034         * termhooks.h (NUM_MOUSE_BUTTONS): Increase to 15.
8036 2000-03-31  Gerd Moellmann  <gerd@gnu.org>
8038         * xterm.c (x_produce_glyphs): When displaying unibyte text
8039         or ASCII, handle case that per-char metric is null.
8041 2000-03-30  Ken Raeburn  <raeburn@gnu.org>
8043         * lisp.h (NO_UNION_TYPE) [ENABLE_CHECKING]: Undef.
8045         * lisp.h (XCONS, XSTRING, XSYMBOL, XFLOAT, XPROCESS, XWINDOW,
8046         XSUBR, XBUFFER): Verify correct object type before returning
8047         pointer, using eassert.
8048         * frame.h (XFRAME): Likewise.
8050         * buffer.c (Frename_buffer, Fset_buffer_multibyte,
8051         swap_out_buffer_local_variables, Fmove_overlay): Don't apply
8052         XSYMBOL, XBUFFER, etc, to values that may be nil or of the wrong
8053         type.
8054         * data.c (set_internal): Likewise.
8055         * dispextern.h (WINDOW_WANTS_MODELINE_P,
8056         WINDOW_WANTS_HEADER_LINE_P): Likewise.
8057         * fileio.c (auto_save_1): Likewise.
8058         * insdel.c (check_markers): Likewise.
8059         * marker.c (buf_charpos_to_bytepos, unchain_marker): Likewise.
8060         * undo.c (record_insert): Likewise.
8061         * vmsproc.c (child_sig): Likewise.
8062         * window.c (unshow_buffer, window_loop): Likewise.
8063         * xterm.c (x_erase_phys_cursor): Likewise.
8065 2000-03-30  Gerd Moellmann  <gerd@gnu.org>
8067         * xfns.c (free_image_cache): Free the cache structure itself
8068         last, after all its members have been freed.
8070         * lisp.h (xstrdup): Add prototype.
8072         * alloc.c (xstrdup): Moved here from xfaces.c.
8073         (allocating_for_lisp): Variable removed.
8074         (lisp_malloc): Block input around the calls to malloc and
8075         mem_insert.
8077         * xfaces.c (realize_tty_face): Use find_symbol_value instead
8078         of Fsymbol_value.
8079         (xstrdup): Moved to alloc.c.
8081 2000-03-29  Ken Raeburn  <raeburn@gnu.org>
8083         * scroll.c (CHECK_BOUNDS): Renamed from CHECK.
8085         * emacs.c (main): Fix sense of no-loadup test.
8087         * config.in (ENABLE_CHECKING): Undef.
8089         * lisp.h (struct interval): Replace "parent" field with a union of
8090         interval pointer and Lisp_Object; add new bitfield to use as
8091         discriminant.  Change other flag fields to bitfields.
8092         (CHECK): New macro for consistency checking.  If ENABLE_CHECKING
8093         is defined and the supplied test fails, print a message and
8094         abort.
8095         (eassert): New macro.  Use CHECK to provide an assert-like
8096         facility.
8098         * intervals.h (NULL_INTERVAL_P): Now applies only to real interval
8099         pointers; abort if the value looks like a lisp object.
8100         (NULL_INTERVAL_P, NULL_PARENT, HAS_PARENT, HAS_OBJECT, SET_PARENT,
8101         SET_OBJECT, INTERVAL_PARENT, GET_INTERVAL_OBJECT, COPY_PARENT):
8102         Modify for new interval parent definition.
8104         * alloc.c (mark_interval_tree, MARK_INTERVAL_TREE,
8105         UNMARK_BALANCE_INTERVALS): Update references that need an
8106         addressable lisp object in the interval structure.
8107         (die): New function.
8108         (suppress_checking): New variable.
8110         * intervals.c (interval_start_pos): Just return 0 if there's no
8111         parent object.
8113 2000-03-29  Gerd Moellmann  <gerd@gnu.org>
8115         * lread.c (read1): Accept `.' (period) as symbol start like in CL
8116         and earlier Emacs versions.
8118         * keyboard.c (Ftop_level): Cancel busy-cursor.
8120         * eval.c (call_debugger): Cancel busy-cursor.
8122 2000-03-29  Kenichi Handa  <handa@etl.go.jp>
8124         * search.c (Freplace_match): Adjust multibyteness of the current
8125         buffer and NEWTEXT.  Free allocated memory before signaling an
8126         error.
8128 2000-03-28  Stefan Monnier  <monnier@cs.yale.edu>
8130         * regex.c (analyse_first): New function obtained by ripping out most
8131         of re_compile_fastmap and generalizing it a little bit so that it
8132         can also just return whether a given (sub)pattern can match the empty
8133         string or not.
8134         (regex_compile): Use `analyse_first' to decide whether the loop-check
8135         needs to be done or not for *, +, *? and +? (the loop check is costly
8136         for non-greedy repetition).
8137         (re_compile_fastmap): Delegate the actual work to `analyse_first'.
8139 2000-03-28  Dave Love  <fx@gnu.org>
8141         * s/gnu-linux.h (GC_SETJMP_WORKS): Define for i386, sparc, m68k,
8142         alpha.
8144         * alloc.c: Include stdio.h.  Test STDC_HEADERS, not __STDC__.
8146 2000-03-27  Stefan Monnier  <monnier@cs.yale.edu>
8148         * regex.c (REGEX_FREE_STACK, RESET_FAIL_STACK): Make them usable as
8149         an expression.
8150         (enum re_opcode_t): Update description of succeed_n.
8151         (PATFETCH): Always define.
8152         (regex_compile): Use lookahead rather than PATUNFETCH (for repetition
8153         operators, char classes, shy-groups and intervals).
8154         Optimize special cases of intervals so as to only use succeed_n and
8155         jump_n when really needed.
8156         (re_compile_fastmap): Simplify handling of jump_n and succeed_n now
8157         that we don't have to handle the special cases any more.
8158         Simplify on_failure_jump handling as well.
8160 2000-03-28  Jason Rumney  <jasonr@gnu.org>
8162         * lread.c (Fload): Move safe_p definition to above #ifdef DOS_NT.
8164 2000-03-27  Gerd Moellmann  <gerd@gnu.org>
8166         * s/freebsd.h (GC_SETJMP_WORKS): Define.
8168         * s/msdos.h (GC_SETJMP_WORKS): Define.
8170         * alloc.c (mark_maybe_object): New function.
8171         (mark_memory): Use it.
8172         (SETJMP_WILL_LIKELY_WORK, SETJMP_WILL_NOT_WORK): New macros.
8173         (setjmp_tested_p, longjmp_done): New variables.
8174         (test_setjmp): New function.
8175         (mark_stack) [!GC_SETJMP_WORKS]: Call test_setjmp.
8176         (init_alloc): Initialize setjmp_tested_p and longjmp_done.
8178         * xdisp.c (face_before_or_after_it_pos): Pass multibyteness
8179         to DEC_TEXT_POS and INC_TEXT_POS.
8181         * dispnew.c (direct_output_for_insert): Use DEC_TEXT_POS
8182         with parameter MULTIBYTE_P.
8184         * dispextern.h (INC_TEXT_POS, DEC_TEXT_POS): Add parameter
8185         MULTIBYTE_P.
8187         * editfns.c (Fsubst_char_in_region): Don't use INC_POS in unibyte
8188         buffers because it looks for multibyte character byte sequences
8189         which don't exist in unibyte text.
8191         * xterm.h (x_specified_cursor_type, x_copy_color): Add prototypes.
8193         * xfaces.c (register_color, unregister_color, unregister_colors)
8194         [DEBUG_X_COLORS]: New functions.
8195         (x_free_colors) [DEBUG_X_COLORS]: Unregister colors.
8197         * xfns.c (x_set_cursor_color): Get color reference counts right.
8199         * xterm.c (x_copy_color): New function.
8200         (x_alloc_nearest_color) [DEBUG_X_COLORS]: Call register_color.
8202         * buffer.h (MAX_PER_BUFFER_VARS): Renamed from MAX_BUFFER_LOCAL_VARS.
8203         (PER_BUFFER_VAR_OFFSET): Renamed from BUFFER_LOCAL_VAR_OFFSET.
8204         (PER_BUFFER_VAR_IDX): Renamed from BUFFER_LOCAL_VAR_IDX.
8205         (PER_BUFFER_VALUE_P): Renamed from BUFFER_HAS_LOCAL_VALUE_P.
8206         (SET_PER_BUFFER_VALUE_P): Renamed from SET_BUFFER_HAS_LOCAL_VALUE_P.
8207         (PER_BUFFER_IDX): Renamed from BUFFER_LOCAL_IDX.
8208         (PER_BUFFER_DEFAULT): Renamed from BUFFER_LOCAL_DEFAULT_VALUE.
8209         (PER_BUFFER_VALUE): Renamed from BUFFER_LOCAL_VALUE.
8210         (PER_BUFFER_SYMBOL): Renamed from BUFFER_LOCAL_SYMBOL.
8211         (PER_BUFFER_TYPE): Renamed from BUFFER_LOCAL_TYPE.
8213         * category.c, data.c, syntax.c, print.c, lread.c: Use new macro
8214         names for handling per-buffer variables.
8216         * buffer.c (buffer_permanent_local_flags): Use MAX_PER_BUFFER_VARS
8217         instead of MAX_BUFFER_LOCAL_VARS.
8218         (last_per_buffer_idx): Renamed from max_buffer_local_idx.
8220         * xfaces.c (lookup_face): Don't assert FACE_SUITABLE_FOR_CHAR_P.
8222         * xfns.c (x_specified_cursor_type): New function.
8223         (x_set_cursor_type): Use it.
8225         * buffer.h (struct buffer): Add cursor_type.
8227 2000-03-26  Stefan Monnier  <monnier@cs.yale.edu>
8229         * regex.c (enum re_opcode_t): New opcode on_failure_jump_nastyloop.
8230         (print_partial_compiled_pattern, re_compile_fastmap): Handle new
8231         opcode.
8232         (regex_compile): Use on_failure_jump_nastyloop for non-greedy loops.
8233         (re_match_2_internal): Add code for on_failure_jump_nastyloop when
8234         executing it as well as when popping it off the stack to find infinite
8235         loops in non-greedy repetition operators.
8237 2000-03-26  Gerd Moellmann  <gerd@gnu.org>
8239         * doc.c (Qfunction_documentation): New variable.
8240         (syms_of_doc): Initialize Qfunction_documentation.
8241         (Fdocumentation): If FUNCTION is a symbol with non-nil
8242         `function-documentation' property, return a documentation derived
8243         from that.
8245         * buffer.c (syms_of_buffer): Add default-cursor-type.
8246         (init_buffer_once): Don't let cursor_type have a local value
8247         in every buffer.
8249         * xterm.c (x_display_and_set_cursor): Choose cursor depending
8250         on buffer-local value of cursor_type.
8251         (x_draw_bar_cursor): Add parameter WIDTH.
8253         * buffer.c (reset_buffer): Initialize buffer's cursor_type.
8254         (init_buffer_once): Set default cursor_type value to t.
8255         Mark cursor_type as local everywhere.
8256         (syms_of_buffer): New per-buffer variable cursor-type.
8258         * buffer.h (struct buffer): Remove member local_var_flags,
8259         add local_flags.
8260         (MAX_BUFFER_LOCAL_VARS): New macro.
8261         (BUFFER_LOCAL_VAR_OFFSET, BUFFER_LOCAL_VAR_IDX)
8262         (BUFFER_HAS_LOCAL_VALUE_P, SET_BUFFER_HAS_LOCAL_VALUE_P)
8263         (BUFFER_LOCAL_IDX, BUFFER_LOCAL_DEFAULT_VALUE, BUFFER_LOCAL_VALUE)
8264         (BUFFER_LOCAL_SYMBOL, BUFFER_LOCAL_TYPE): New macros.
8266         * print.c (print_object): Use new macros for per-buffer
8267         variables.
8269         * category.c (Fset_category_table): Use new macros for per-buffer
8270         variables.
8272         * buffer.c (buffer_permanent_local_flags): Make a char array.
8273         (max_buffer_local_idx): New variable.
8274         (reset_buffer_local_variables, Fbuffer_local_variables): Rewritten
8275         for new handling of per-buffer variables.
8276         (buffer_slot_type_mismatch): Use new macros for per-buffer vars.
8277         (init_buffer_once): Initialize per-buffer vars differently.
8278         Set max_buffer_local_idx.
8280         * syntax.c (Fset_syntax_table): Use new macros for per-buffer
8281         variables.
8283         * lread.c (defvar_per_buffer): Use new macros for per-buffer
8284         variables.
8286         * data.c (do_symval_forwarding, store_symval_forwarding)
8287         (find_symbol_value, set_internal, default_value, Fset_default)
8288         (Fkill_local_variable, Flocal_variable_p): Use new macros for
8289         per-buffer variables.
8291         * Makefile.in (bootstrap-emacs): Use `mv -f' instead of `mv'.
8293 2000-03-24  Gerd Moellmann  <gerd@gnu.org>
8295         * xterm.c (x_term_init): Unblock input around call1 of
8296         Qvendor_specific_keysyms.
8298         * syntax.c (open_paren_in_column_0_is_defun_start): New variable.
8299         (find_defun_start): Consider an open parenthesis in column 0
8300         a defun start only if open_paren_in_column_0_is_defun_start is set.
8301         (syms_of_syntax): New variable open-paren-in-column-0-is-defun-start.
8303 2000-03-24  Stefan Monnier  <monnier@cs.yale.edu>
8305         * eval.c (Fautoload): Add entry in load-history (if after dump).
8306         * lread.c (load-history): Update docstring.
8308 2000-03-24  Gerd Moellmann  <gerd@gnu.org>
8310         * indent.c (Fvertical_motion): Always use the current buffer.
8311         Temporarily change the window's buffer, if necessary.
8313 2000-03-23  Gerd Moellmann  <gerd@gnu.org>
8315         * xterm.c (fast_find_position): Make sure not to consider rows
8316         not visible in the window.
8318 2000-03-22  Stefan Monnier  <monnier@cs.yale.edu>
8320         * regex.c (enum syntaxcode): Provide default for non-Emacs.
8321         (re_compile_fastmap, re_match_2_internal): Undo Dave's previous fix.
8323 2000-03-22  Jason Rumney  <jasonr@gnu.org>
8325         * w32menu.c (single_submenu): Set help string to NULL if none.
8326         (w32_menu_show): Set help string correctly.
8327         (add-menu-item): Set help string in MIIM_DATA for menu item.
8328         Load SetMenuItemInfoA explicitly.
8329         (w32_menu_display_help): New function.
8331         * w32fns.c (w32_wnd_proc): Handle WM_MENUSELECT message.
8332         (QCdata): Moved to xdisp.c.
8334         * w32term.c (w32_read_socket): Handle WM_MENUSELECT message.
8335         (Vw32_charset_to_codepage_alist): Removed.
8336         (Vw32_charset_info_alist): New variable.
8337         (Qw32_charset_[ansi, default, symbol, shiftjis, hangul, gb2312,
8338         chinesebig5, oem, easteurope, turkish, baltic, russian, arabic,
8339         greek, hebrew, thai, johab, mac, unicode]): New symbols.
8340         (x_produce_glyphs): Remove out of date #ifdef 0'd section. Replace
8341         with TODO comment.
8342         (w32_codepage_for_font): Use Vw32_charset_info_alist.
8343         (syms_of_w32term): Remove Vw32_charset_to_codepage_alist.
8344         Define Vw32_charset_info_alist and w32_charset symbols.
8346 2000-03-22  Jason Rumney  <jasonr@gnu.org>
8348         * makefile.nt (w32bdf.obj): Update dependencies.
8350         * w32bdf.c: Include frame.h and dispextern.h before fontset.h.
8352         * w32fns.c: Include fontset.h after dispextern.h.
8353         (Fx_create_frame): Do not create fontset.
8354         (w32_load_system_font): Doc fix.
8355         (Fx_close_connection): Free full_name if it is not shared.
8357         * w32term.c: Include fontset.h after dispextern.h.
8358         (x_get_glyph_face_and_encoding): New parameter two_byte_p. Callers
8359         updated.
8360         (w32_per_char_metric): If PCM is invalid, delete and return NULL.
8361         (x_get_char_and_face_encoding): Use FACE_FOR_CHAR to get face_id.
8362         (w32_font_is_double_byte): New function, needs body.
8363         (x_append_glyph): Set glyph->glyph_not_available_p.
8364         (x_produce_glyphs): Set it->glyph_not_available_p.  Don't set
8365         it->charset.  If it->multibyte_p is zero and it->c is a multibyte
8366         character, convert it to a unibyte character.
8367         (struct glyph_string): Delete member `charset'.
8368         (W32_TEXTOUT): Temporarily remove charset_dim until another way of
8369         calculating it is found.
8370         (x_set_mouse_face_gc): Call FACE_FOR_CHAR to get face_id.  Handle
8371         the case that per char metric is not available correctly.
8372         (x_fill_glyph_string): Handle the case that the specific glyph is
8373         not available correctly.
8374         (BUILD_CHAR_GLYPH_STRINGS): Don't set s->charset.
8375         (BUILD_COMPOSITE_GLYPH_STRING): Likewise.
8376         (x_new_font): Call FS_LOAD_FONT, not fs_load_font.
8377         (x_new_fontset): Call fontset_ascii to get ASCII font name of the
8378         fontset.  Don't call FS_LOAD_FONT.
8380 2000-03-22  Ken Raeburn  <raeburn@gnu.org>
8382         * intervals.h (NULL_INTERVAL): Cast to INTERVAL type.
8383         (INT_LISPLIKE): New macro.
8384         (NULL_INTERVAL_P): Use it.
8385         (INTERVAL_HAS_PARENT, INTERVAL_HAS_OBJECT, SET_INTERVAL_PARENT,
8386         SET_INTERVAL_OBJECT, INTERVAL_PARENT, COPY_INTERVAL_PARENT,
8387         GET_INTERVAL_OBJECT, INTERVAL_PARENT_OR_NULL): New macros.
8389         * alloc.c (make_interval, gc_sweep): Use new macros; eliminate all
8390         explicit references to "parent" field of struct interval and
8391         associated unclean type conversions.
8392         * intervals.c (create_root_interval, root_interval, rotate_right,
8393         rotate_left, balance_possible_root_interval, split_interval_right,
8394         split_interval_left, interval_start_pos, find_interval,
8395         next_interval, previous_interval, update_interval,
8396         adjust_intervals_for_insertion, delete_node, delete_interval,
8397         adjust_intervals_for_deletion, merge_interval_right,
8398         merge_interval_left, reproduce_tree, graft_intervals_into_buffer,
8399         copy_intervals_to_string): Likewise.
8400         * intervals.h (AM_LEFT_CHILD, AM_RIGHT_CHILD, RESET_INTERVAL):
8401         Likewise.
8402         * syntax.c (update_syntax_table): Likewise.
8404         * intervals.c (reproduce_tree_obj): New function, like
8405         reproduce_tree but takes a Lisp_Object for the parent.  Declare
8406         with prototype.
8407         (graft_intervals_into_buffer): Use it when appropriate.
8408         (reproduce_tree): Declare with prototype.
8409         (balance_possible_root_interval): Check that the parent is a lisp
8410         object before trying to examine its type.
8412 2000-03-22  Gerd Moellmann  <gerd@gnu.org>
8414         * xfaces.c (lface_same_font_attributes_p): Compare font attributes
8415         as strings only if both are known to be strings.
8417         * s/openbsd.h (LIBS_TERMCAP): Undef.
8419 2000-03-21  Stefan Monnier  <monnier@cs.yale.edu>
8421         * regex.c (CHAR_CHARSET, CHARSET_LEADING_CODE_BASE): Add default
8422         definitions for non-Emacs compilation.
8423         (enum re_opcode_t): Remove (not)wordchar and move (not)syntaxspec
8424         outside of `#ifdef emacs'.
8425         (print_partial_compiled_pattern): Update.
8426         (regex_compile): Use (not)syntaxspec(Sword) instead of (not)wordchar.
8427         (re_compile_fastmap): Merge handling of charset and charset_not (for
8428         emacs and non-emacs compilation as well).
8429         Similarly for (not)categoryspec and (not)syntaxspec.
8430         Don't use the fastmap when reaching `anychar' since the added
8431         complexity is not justified.
8432         (re_match_2_internal): Merge (not)wordchar (emacs and non-emacs)
8433         and (not)syntaxspec.  Merge (not)categoryspec.
8435 2000-03-22  Kenichi Handa  <handa@etl.go.jp>
8437         * dispextern.h [!HAVE_WINDOW_SYSTEM] (FACE_SUITABLE_FOR_CHAR_P,
8438         FACE_FOR_CHAR): Define them differently for the configuration of
8439         --without-x.
8441 2000-03-21  Dave Love  <fx@gnu.org>
8443         * fontset.c (Fset_fontset_font, Ffontset_font): Fix newlines in
8444         doc string.
8446 2000-03-21  Gerd Moellmann  <gerd@gnu.org>
8448         * xfaces.c (check_lface_attrs) [GLYPH_DEBUG]: Fix syntax error.
8449         (lface_fully_specified_p): Don't check contents of
8450         LFACE_FONT_INDEX because that attribute is optional.
8451         (realize_x_face): Remove now unwarranted xassert.
8453 2000-03-21  Kenichi HANDA  <handa@etl.go.jp>
8455         The following changes are to make font selection based on
8456         characters, not charset.  In addition, they recover fontset
8457         facilities while utilizing the new font selection mechanism.
8459         * Makefile.in (fontset.o): Depend on dispextern.h.
8461         * alloc.c (mark_face_cache): Don't mark face->registry.
8463         * dispextern.h (struct glyph): New member glyph_not_available_p.
8464         Use 22 bits for face_id.
8465         (enum lface_attribute_index): Add LFACE_FONT_INDEX.
8466         (struct face): Delete member registry, new member ascii_face.
8467         (FACE_SUITABLE_FOR_CHAR_P): Renamed from
8468         FACE_SUITABLE_FOR_CHARSET_P.  Caller changed.
8469         (FACE_FOR_CHAR): Renamed from FACE_FOR_CHARSET.  Caller changed.
8470         (struct it): Delete member charset, new member
8471         glyph_not_available_p.
8473         * fontset.h (FONT_NOT_OPENED, FONT_NOT_FOUND): Macros removed.
8474         (struct fontset_info, struct fontset_data): Structs removed.
8475         (allloc_fontset_data, free_fontset_data, fs_regiser_fontset,
8476         Vglobale_fontset_alist, font_idx_temp): Externs removed.
8477         (fs_load_font, fs_query_fontset): Adjusted for new argument.
8478         (fs_free_face_fontset, fontset_font_pattern,
8479         face_suitable_for_char_p, face_for_char,
8480         make_fontset_for_ascii_face): Extern them.
8481         (FS_LOAD_FONT): Adjusted for the change of fontset implementation.
8482         (FS_LOAD_FACE_FONT): New macro.
8484         * fontset.c: All codes rewritten or adjusted for the change of
8485         fontset implementation.  Now fontset is represented by char table.
8486         (Vglobal_fontset_alist, font_idx_temp, my_strcasetbl): Variables
8487         removed.
8488         (my_strcasecmp): Function removed.
8489         (Vfontset_table, next_fontset_id, Vdefault_fontset): New
8490         variables.
8491         (AREF, ASIZE): New macros.
8492         (FONTSET_FROM_ID, FONTSET_ID, FONTSET_NAME, FONTSET_FRAME,
8493         FONTSET_ASCII, FONTSET_BASE, BASE_FONTSET_P, FONTSET_REF,
8494         FONTSET_REF_VIA_BASE, FONTSET_SET): New macros.
8495         (fontset_ref, fontset_ref_via_base, fontset_set, make_fontset,
8496         fontset_id_valid_p, font_family_registry, fontset_name,
8497         fontset_ascii, free_face_fontset, face_suitable_for_char_p,
8498         face_for_char, make_fontset_for_ascii_face, fontset_font_pattern):
8499         New functions.
8500         (fs_load_font): New arg FACE.  Caller changed.
8501         (fs_query_fontset): Argument changed.  Caller changed.
8502         (Fquery_fontset): call fs_query_fontset.
8503         (fs_register_fontset, alloc_fontset_data, free_fontset_data):
8504         Functions removed.
8505         (clear_fontset_elements, check_registry_encoding,
8506         check_fontset_name): New functions.
8507         (syms_of_fontset): Set char-table-extra-slots property of fontset
8508         to 3.  Staticpro and initialize Vfontset_table and
8509         Vdefault_fontset.  Defsubr fontset_font and fontset_list.
8511         * frame.h (struct frame): Member `fontset_data' removed.
8512         (FRAME_FONTSET_DATA): Macro removed.
8514         * frame.c (make_frame): Don't allocate f->fontset_data.
8515         (Fdelete_frame): Don't free f->fontset_data.
8517         * msdos.c (XMenuActivate): Args to lookup_derived_face changed.
8519         * xdisp.c (charset_at_position): Function removed.
8520         (init_iterator): Don't set member charset of struct `it'.
8521         (handle_face_prop, reseat_to_string, set_iterator_to_next,
8522         next_element_from_display_vector, insert_left_trunc_glyphs):
8523         Likewise.
8524         (face_before_or_after_it_pos): Call FACE_FOR_CHAR, not
8525         FACE_FOR_CHARSET.
8526         (get_next_display_element, append_space,
8527         extend_face_to_end_of_line): Likewise.
8529         * xfaces.c (Qx_charset_registry, Vface_default_registry):
8530         Variables removed.
8531         (clear_font_table, frame_update_line_height, load_face_font):
8532         Adjusted for the change of fontset implementation.
8533         (load_face_fontset_font): Function removed.
8534         (pixel_point_size): New function.
8535         (font_list): Argument type changed.  Caller changed.
8536         (LFACE_FONT): New macro.
8537         (check_lface_attrs): Check attr[LFACE_FONT_INDEX].
8538         (set_lface_from_font_name): Type of arg FONTNAME is changed to
8539         Lisp_Object.  Determine the font name by actually loading a font
8540         by the specified pattern.  Set LFACE_FONT (lface) to the specified
8541         pattern.  Even if a font is not found, don't try alternatives.
8542         (Finternal_set_lisp_face_attribute): Handle `font' slot in lface.
8543         (set_font_frame_param): If `font' is specified in lface, use it.
8544         (Finternal_get_lisp_face_attribute): Handle `font' slot in lface.
8545         (lface_same_font_attributes_p): Likewise.
8546         (make_realized_face): Arguent changed.  Caller changed.  Set
8547         face->ascii_face to face itself.
8548         (free_realized_face): Free face->fontset if face is for ASCII.
8549         (face_suitable_for_iso8859_1_p, face_suitable_for_charset_p,
8550         deduce_unibyte_registry, x_charset_registry): Functions removed.
8551         (free_realized_multibyte_face): New function.
8552         (lookup_face, lookup_named_face, lookup_derived_face): Argument
8553         changed.  Caller changed.
8554         (try_font_list): Argument type changed.
8555         (face_fontset): Check `font' slot of ATTRS, not `family' slot.
8556         (choose_face_font): Argument changed.  Handle fontset properly.
8557         (choose_face_fontset_font): Function removed.
8558         (realize_default_face, realize_named_face): Don't remove the
8559         former face here.
8560         (realize_face): Argument changed.  Caller changed.  Remove face
8561         with the arg former_face_id in advance.  Load font for the new
8562         face.
8563         (realize_x_face): Argument changed.  Caller changed.  For a
8564         multibyte character, share fontset with base_face.  For a single
8565         byte character, make a new realized fontset.  Don't load a font
8566         here.
8567         (realize_tty_face): Argument changed.  Caller changed.
8568         (compute_char_face): Call FACE_FOR_CHAR, not FACE_FOR_CHARSET.
8569         (face_at_buffer_position): Don't check multibyte_p for returning
8570         DEFAULT_FACE_ID.
8571         (face_at_string_position): Call FACE_SUITABLE_FOR_CHAR_P, not
8572         FACE_SUITABLE_FOR_CHARSET_P.
8573         (syms_of_xfaces): Remove code for Qx_charset_registry and
8574         Vface_default_registry.
8576         * xterm.c: Include fontset.h after dispextern.h.  Undo the changes
8577         related to PER_CHAR_METRIC done by Gerd on 2000-03-03.
8578         (x_per_char_metric): Don't try FONT->default_char.  Even if
8579         pcm->width is zero, glyph bits may exist.
8580         (x_encode_char): Always initialize char2b->byte1.
8581         (x_get_char_face_and_encoding): Call FACE_FOR_CHAR to get face_id.
8582         (x_get_glyph_face_and_encoding): New arg two_byte_p.  Caller
8583         changed.
8584         (x_append_glyph): Set glyph->glyph_not_available_p.
8585         (x_produce_glyphs): Set it->glyph_not_available_p.  Don't set
8586         it->charset.  Handle the case that per char metric is not
8587         available.  If it->multibyte_p is zero and it->c is a multibyte
8588         character, convert it to a unibyte character.
8589         (struct glyph_string): Delete member `charset'.
8590         (x_set_mouse_face_gc): Call FACE_FOR_CHAR to get face_id.  Handle
8591         the case that per char metric is not available correctly.
8592         (x_fill_glyph_string): Handle the case that the specific glyph is
8593         not available correctly.
8594         (BUILD_CHAR_GLYPH_STRINGS): Don't set s->charset.
8595         (BUILD_COMPOSITE_GLYPH_STRING): Likewise.
8596         (x_new_font): Call FS_LOAD_FONT, not fs_load_font.
8597         (x_new_fontset): Call fontset_ascii to get ASCII font name of the
8598         fontset.  Don't call FS_LOAD_FONT.
8600         * xfns.c (Fx_create_frame): Don't cal fs_register_fontset.
8601         (x_create_tip_frame): Likewise.
8602         (Fx_close_connection): Free full_name of font_info.
8604         * fns.c (optimize_sub_char_table): New function.
8605         (Foptimize_char_table): New function.
8606         (syms_of_fns): Defsubr Soptimize_char_table.
8608 2000-03-20  Gerd Moellmann  <gerd@gnu.org>
8610         * buffer.c (Fset_buffer_modified_p): Set update_mode_lines
8611         only if buffer is displayed in some window.
8613         * xdisp.c (handle_single_display_prop): Initialize local `value'.
8614         (try_window_reusing_current_matrix): Don't call scroll run
8615         function if run's current and desired position are the same;
8616         this prevents cursor flickering.
8618 2000-03-19  Stefan Monnier  <monnier@cs.yale.edu>
8620         * regex.h (RE_TRANSLATE. RE_TRANSLATE_P): Moved to regex.c.
8622         * regex.c (RE_STRING_CHAR): New macro.
8623         (GET_CHAR_AFER_2): Remove.
8624         (RE_TRANSLATE, RE_TRANSLATE_P): New macros moved from regex.h.
8625         (enum re_opcode_t): Remove on_failure_jump_exclusive.
8626         (print_partial_compiled_pattern, re_compile_fastmap)
8627         (re_match_2_internal): Remove on_failure_jump_exclusive.
8628         (regex_compile): Turn optimizable P+ loops into PP*, so that the
8629         optimization only need to work for * (ie. can use of_keep_string_jump).
8630         Remove the special case for .*\n since it is now covered by the general
8631         optimization.
8632         (re_search_2): Don't bother with `room'.
8633         (skip_one_char): New function.
8634         (skip_noops): Simplify since `memory' is not needed any more.
8635         (mutually_exclusive_p): Restructure slightly to use `switch' and
8636         add handling for "all" remaining cases.
8637         (re_match_2_internal): Change on_failure_jump_smart to use
8638         on_failure_keep_string_jump (and redirect the end-of-loop jump)
8639         rather than on_failure_jump_exclusive.
8641 2000-03-19  Gerd Moellmann  <gerd@gnu.org>
8643         * xfns.c (select_visual): Don't set dpyinfo->n_planes to the
8644         number of bits per RGB because it's everywhere used as the depth
8645         of the visual.
8647         * term.c (calculate_costs): Remove code dealing with X frames.
8649 2000-03-19  Richard M. Stallman  <rms@gnu.org>
8651         * lread.c (syms_of_lread): Doc fix for load-convert-to-unibyte.
8653 2000-03-18  Gerd Moellmann  <gerd@gnu.org>
8655         * lread.c (read_integer): Unread the last char not consumed.
8657 2000-03-17  Gerd Moellmann  <gerd@gnu.org>
8659         * xterm.c (x_update_window_cursor): Don't update in frames
8660         which are in the process of being deleted.
8662 2000-03-16  Gerd Moellmann  <gerd@gnu.org>
8664         * Makefile.in (mostlyclean): Add `*.core'.
8665         (clean): Add `bootstrap-emacs'.
8667         * lread.c (read_integer): New function.
8668         (read1): Support read syntax #o, #x, #b, #r.
8670 2000-03-15  Stefan Monnier  <monnier@cs.yale.edu>
8672         * regex.c (re_match_2): Fix string shortening (to fit `stop') to
8673         make sure POINTER_TO_OFFSET gives the same value before and after
8674         PREFETCH.  Use `dfail' to guarantee "atomic" matching.
8675         (PTR_TO_OFFSET): Use POINTER_TO_OFFSET.
8676         (debug): Now only active if > 0 rather than if != 0.
8677         (DEBUG_*): Update for the new meaning of `debug'.
8678         (print_partial_compiled_pattern): Add missing `succeed' case.  Use
8679         CHARSET_* macros in the charset(_not) branch.  Fix off-by-two bugs
8680         in `succeed_n', `jump_n' and `set_number_at'.
8681         (store_op1, store_op2, insert_op1, insert_op2)
8682         (at_begline_loc_p, at_endline_loc_p): Add prototype.
8683         (group_in_compile_stack): Move to after its arg's types are
8684         declared and add a prototype.
8685         (PATFETCH): Define in terms of PATFETCH_RAW.
8686         (GET_UNSIGNED_NUMBER): Add the usual `do { ... } while(0)'
8687         wrapper.
8688         (QUIT): Redefine as a nop except for NTemacs.
8689         (regex_compile): Handle intervals {,M} as if it was {0,M}.  Fix
8690         indentation of the greedy-op and shy-group code.
8691         (at_(beg|end)line_loc_p): Fix argument's types.
8692         (re_compile_fastmap): Ifdef out failure_stack_ptr to shut up gcc.
8693         (re_search_2): Use POS_AS_IN_BUFFER.  Simplify `room' computation.
8694         (MATCHING_IN_FIRST_STRING): Remove.
8695         (re_match_2): Use POS_AS_IN_BUFFER.  Ifdef out failure_stack_ptr
8696         to shut up gcc.  Use FIRST_STRING_P and POINTER_TO_OFFSET.  Use
8697         QUIT unconditionally.
8699 2000-03-15  Gerd Moellmann  <gerd@gnu.org>
8701         * minibuf.c (Fminibuffer_complete): Set point to ZV if finding
8702         a sole completion.
8704         * process.c (send_process): Add a hint that the function
8705         can call Lisp code to its comment.
8707         * lread.c (load_dangerous_libraries): New variable.
8708         (Vbytecomp_version_regexp): New variable.
8709         (safe_to_load_p): New function.
8710         (Fload): Handle files not compiled with Emacs specially.
8711         (syms_of_lread): New Lisp variable load-dangerous-libraries.
8713 2000-03-14  Gerd Moellmann  <gerd@gnu.org>
8715         * lisp.h (free_frame_xic) [HAVE_X_I18N]: Add missing semicolon.
8717         * xterm.c (xim_close_dpy, xim_initialize): Use X11R6-style XIM
8718         support functions only if HAVE_X11R6_XIM is defined.
8719         (xim_instantiate_callback): Define only if HAVE_X11R6_XIM.
8721         * s/sol2.h (INHIBIT_X11R6_XIM): Define.
8723         * xfns.c (X_I18N_INHIBITED): Don't define.
8724         (create_frame_xic): Remove conditional compilation on
8725         X_I18N_INHIBITED.
8726         (x_kill_gs_process, x_window): Use FRAME_X_VISUAL.
8728         * config.in (HAVE_X_I18N): Moved here from xterm.h.
8729         (HAVE_X11R6_XIM): Define.
8731         * xterm.h (HAVE_X_I18N) [HAVE_X11R6]: Moved to config.in.
8733         * xterm.c (x_term_init): Add support for X resource `synchronous'.
8734         If set, call XSynchronize.
8736 2000-03-13  Stefan Monnier  <monnier@cs.yale.edu>
8738         * regex.c: Declare a new type `re_char' used throughout the code
8739         for the string char type.  It's `const unsigned char' to match the
8740         rest of Emacs.  Consistently make sure all pointers to strings use
8741         it and make sure all pointers into the pattern use `unsigned
8742         char'.
8743         (re_match_2_internal): Use `PREFETCH+STRING_CHAR' instead of
8744         GET_CHAR_AFTER_2.  Also merge wordbound and notwordbound to reduce
8745         code duplication.
8747         * charset.h (GET_CHAR_AFTER_2): Remove.
8748         (GET_CHAR_BEFORE_2): Use unsigned chars, like everywhere else.
8750 2000-03-12  Ken Raeburn  <raeburn@gnu.org>
8752         * Makefile.in (temacs): Evaluate ALL_LDFLAGS into a temporary
8753         variable before the invocation of YMF_PASS_LDFLAGS, in case both
8754         of them try to use backquotes.
8756 2000-03-12  Dave Love  <fx@gnu.org>
8758         * unexelf.c: Restore changes of 1999-10-19.
8759         (unexec): Don't adjust bss for sbss type SHT_PROGBITS; otherwise
8760         fix its type and alignment; copy it from current process.
8762 2000-03-12  Gerd Moellmann  <gerd@gnu.org>
8764         * atimer.c (cancel_atimer): Break out of the loop as soon as timer
8765         has been found.  Fix bug not computing timer's predecessor.
8767         * fileio.c (Fread_file_name): Handle case that DIR contains a
8768         file name.
8770         * window.c (Fsave_window_excursion): Doc fix.
8772         * xfns.c (x_defined_color): Rewritten to use
8773         x_allocate_nearest_color.
8775 2000-03-12  Eli Zaretskii  <eliz@is.elta.co.il>
8777         * msdos.c (vga_installed): New function, code moved from
8778         dos_set_window_size.
8779         (Qbar, Qcursor_type, outside_cursor): New variables.
8780         (syms_of_msdos): Intern and staticpro them.
8781         (dos_ttraw) [__DJGPP__ >= 2, !HAVE_X_WINDOWS]: Save the cursor
8782         shape used outside Emacs when called for the first time.
8783         (dos_ttcooked) [__DJGPP__ >= 2, !HAVE_X_WINDOWS]: Restore the
8784         cursor shape used outside Emacs.
8785         (msdos_set_cursor_shape, IT_set_cursor_type): New functions.
8786         (IT_frame_up_to_date): Call IT_set_cursor_type, in case the cursor
8787         type has changed.
8788         (IT_set_frame_parameters): Call IT_set_cursor_type if the frame
8789         parameters specify the cursor.  Make qreverse a global
8790         variable (renamed to Qreverse).
8792 2000-03-09  Gerd Moellmann  <gerd@gnu.org>
8794         * fns.c (Fy_or_n_p): Cancel busy-cursor.
8796 2000-03-08  Stefan Monnier  <monnier@cs.yale.edu>
8798         This is a big redesign of failure-stack and register handling, prompted
8799         by bugs revealed when trying to add shy-groups.  Overall, what happened
8800         is that loops are now structured a little differently, groups can be
8801         shy and the code is a little simpler.
8803         * regex.h: Update the copyright.
8804         (RE_SHY_GROUPS): New value.
8805         (RE_UNMATCHED_RIGHT_PAREN_ORD): Renumber.
8806         (RE_SYNTAX_EMACS): Add RE_SHY_GROUPS.
8808         * regex.c (enum re_opcode_t): Remove jump_past_alt,
8809         maybe_pop_jump, push_dummy_failure and dumy_failure_jump.  Add
8810         on_failure_jump_(exclusive, loop and smart).  Also fix the comment
8811         for (start|stop)_memory since they now only take one argument (the
8812         second has becomes unnecessary).
8813         (print_partial_compiled_pattern): Adjust for changes in
8814         re_opcode_t.
8815         (print_compiled_pattern): Use %ld to printf long ints and flush to
8816         make debugging a little easier.
8817         (union fail_stack_elt): Make the integer unsigned.
8818         (struct fail_stack_type): Add a `frame' element.
8819         (INIT_FAIL_STACK): Init `frame' as well.
8820         (POP_PATTERN_OP): New macro for re_compile_fastmap.
8821         (DEBUG_PUSH, DEBUG_POP): Remove.
8822         (NUM_REG_ITEMS): Remove.
8823         (NUM_NONREG_ITEMS): Adjust.
8824         (FAILURE_PAT, FAILURE_STR, NEXT_FAILURE_HANDLE)
8825         (TOP_FAILURE_HANDLE): New macros for the cycle detection.
8826         (ENSURE_FAIL_STACK): New macro for PUSH_FAILURE_(REG|POINT).
8827         (PUSH_FAILURE_REG, POP_FAILURE_REG, CHECK_INFINITE_LOOP): New
8828         macros.
8829         (PUSH_FAILURE_POINT): Don't push registers any more.  The pattern
8830         address pushed is not the destination of the jump but the source
8831         of it instead.
8832         (NUM_FAILURE_ITEMS): Remove.
8833         (POP_FAILURE_POINT): Adapt to the new stack structure (i.e. pop
8834         registers before the actual failure point).  Don't hardcode any
8835         meaning for str==NULL anymore.
8836         (union register_info_type, REG_MATCH_NULL_STRING_P, IS_ACTIVE)
8837         (MATCHED_SOMETHING, EVER_MATCHED_SOMETHING, SET_REGS_MATCHED):
8838         Remove.
8839         (REG_UNSET_VALUE): Use NULL (why not?).
8840         (compile_range): Remove declaration since it doesn't exist.
8841         (struct compile_stack_elt_t): Remove inner_group_offset.
8842         (old_reg(start|end), reg_info, reg_dummy, reg_info_dummy): Remove.
8843         (regex_grow_registers): Remove dead code.
8844         (FIXUP_ALT_JUMP): New macro.
8845         (regex_compile): Add shy-groups Change loops to use
8846         on_failure_jump_smart&jump instead of
8847         on_failure_jump&maybe_pop_jump.  Change + loops to eliminate the
8848         initial (dummy_failure_)jump.  Remove c1_base (looks like unused
8849         variable to me).  Use `jump' instead of `jump_past_alt' and don't
8850         bother with push_dummy_failure in alternatives since it is now
8851         unnecessary.  Use FIXUP_ALT_JUMP.  Eliminate a useless `#ifdef
8852         emacs' for (re)allocating the stack.
8853         (re_compile_fastmap): Remove dead variables i and num_regs.  Exit
8854         from loop when bufp->can_be_null rather than jumping to `done'.
8855         Avoid jumping backwards so as to ensure termination.  Use
8856         PATTERN_STACK_EMPTY and POP_PATTERN_OP.  Improved handling of
8857         backreferences.  Remove dead code in handling of `anychar'.
8858         (skip_noops, mutually_exclusive_p): New functions taken from the
8859         handling of `maybe_pop_jump' in re_match_2_internal.  Slightly
8860         improve mutually_exclusive_p to handle ".+\n".
8861         (lowest_active_reg, highest_active_reg,
8862         NO_(LOWEST|HIGHEST)_ACTIVE_REG) Remove.
8863         (re_match_2_internal): Use %p instead of 0x%x when printf'ing
8864         ptrs.  Don't SET_REGS_MATCHED anymore.  Remove many dead
8865         variables.  Push register (in `start_memory') on the stack rather
8866         than storing it in old_reg(start|end).  Remove the cycle detection
8867         from `stop_memory', replaced by the use of on_failure_jump_loop
8868         for greedy loops.  Add code for the new on_failure_jump_<foo>.
8869         Remove ad-hoc code in `on_failure_jump' to push more registers in
8870         the case of a loop.  Take out code from `maybe_pop_jump' into
8871         separate functions and adapt it to the semantics of
8872         `on_failure_jump_smart'.  Remove jump_past_alt, dummy_failure_jump
8873         and push_dummy_failure.  Remove dummy_failure handling and
8874         handling of `failures to jump to on_failure_jump' (this last one
8875         was already dead code, it seems).
8876         (group_match_null_string_p, alt_match_null_string_p)
8877         (common_op_match_null_string_p): Remove.
8879 2000-03-08  Dave Love  <fx@gnu.org>
8881         * config.in: Don't depend on __STDC__ for volatile.
8882         Add POINTER_TYPE, PTR, PROTOTYPES.
8884         * hftctl.c, strftime.c: Use PROTOTYPES.
8885         * eval.c (find_handler_clause): Likewise.
8887         * mem-limits.h: Use POINTER_TYPE.
8889         * lisp.h (P_): Define based on PROTOTYPES, not __STDC__.
8890         (memory_warnings): Declare using POINTER_TYPE.
8892 2000-03-08  Gerd Moellmann  <gerd@gnu.org>
8894         * xfns.c (x_set_cursor_type): If ARG is nil, give frame no cursor.
8896         * xdisp.c (display_echo_area): Temporarily inhibit garbage
8897         collection.
8899         * xfns.c: Remove obsolete code in #if 0.
8900         (Fx_focus_frame): New function.
8902 2000-03-07  Miyashita Hisashi  <himi@bird.scphys.kyoto-u.ac.jp>
8904         * coding.c (coding_category_name): Add coding-category-utf-8,
8905         coding-category-utf-16-be, coding-category-utf-16-le.
8906         (UTF_8_1_OCTET_P, UTF_8_EXTRA_OCTET_P, UTF_8_2_OCTET_LEADING_P,
8907         UTF_8_3_OCTET_LEADING_P, UTF_8_4_OCTET_LEADING_P,
8908         UTF_8_5_OCTET_LEADING_P, UTF_8_6_OCTET_LEADING_P): New macros.
8909         (detect_coding_utf_8): New function.
8910         (UTF_16_INVALID_P, UTF_16_HIGH_SURROGATE_P
8911         UTF_16_LOW_SURROGATE_P): New macros.
8912         (detect_coding_utf_16): New function
8913         (detect_coding_mask): When priorities are specified, skip any
8914         categories that have `nil' coding-system.  Fix bug of returning
8915         wrong mask when PRIORITIES is specified and detect_coding_XXX()
8916         returns a mask not set in PRIORITIES.
8917         (detect_eol_type_in_2_octet_form): New function.
8918         (detect_eol): selects detect_eol_type_XXX to call according to
8919         cooding->category_idx.
8920         (detect_coding_system): Remove `nil' coding-system in the result.
8921         (Fupdate_coding_systems_internal): Update all coding-categories.
8923         * coding.h (CODING_CATEGORY_IDX_UTF_8,
8924         CODING_CATEGORY_IDX_UTF_16_BE, CODING_CATEGORY_IDX_UTF_16_LE): New
8925         macros.
8926         (CODING_CATEGORY_IDX_RAW_TEXT, CODING_CATEGORY_IDX_BINARY,
8927         CODING_CATEGORY_IDX_MAX): Adjusted for the above macros.
8928         CODING_CATEGORY_IDX_UTF_16_LE.
8929         (CODING_CATEGORY_MASK_UTF_8, CODING_CATEGORY_MASK_UTF_16_BE,
8930         CODING_CATEGORY_MASK_UTF_16_LE): New macros.
8931         (CODING_CATEGORY_MASK_ANY): Include the above macros.
8932         (CODING_CATEGORY_MASK_UTF_16_BE_LE): New macro.
8934 2000-03-07  Gerd Moellmann  <gerd@gnu.org>
8936         * doc.c (Fdocumentation_property): If value is not a string,
8937         and doesn't refer to etc/DOC, evaluate it to obtain a string.
8939         * xterm.c (x_connection_closed) [USE_X_TOOLKIT]: Don't try to
8940         close the display with XtCloseDisplay.  This caused a bus error
8941         on OpenWindows.
8943         * minibuf.c (Fminibuffer_complete): Move point to ZV when input is
8944         complete but not unique.
8946 2000-03-06  Gerd Moellmann  <gerd@gnu.org>
8948         * process.c (send_process): Remove local variable `procname' that
8949         might become invalid when a GC happens.  Instead, access the
8950         process name slot directly.
8952         * xfns.c (x_set_menu_bar_lines_1): Adjust window's orig_top and
8953         orig_height if set.
8955         * frame.c (set_menu_bar_lines_1): Adjust window's orig_top and
8956         orig_height if set.
8958 2000-03-06  Eli Zaretskii  <eliz@is.elta.co.il>
8960         * msdos.c (IT_note_mouse_highlight): Return immediately if frame's
8961         glyph matrices have been freed.
8963 2000-03-05  Gerd Moellmann  <gerd@gnu.org>
8965         * Makefile.in (tags): Include ../lwlib/TAGS in TAGS.
8966         (bootstrap-temacs): Set LC_ALL to C like for temacs.
8968         * xfns.c (QCdata): Moved to xdisp.c.
8970         * xdisp.c (QCdata): Moved here from xfns.c.
8971         (syms_of_xdisp): Initialize QCdata.
8973         * frame.h (FRAME_INTERNAL_BORDER_WIDTH) [!HAVE_X_WINDOWS]: Define.
8975         * window.c (coordinates_in_window): Use
8976         FRAME_INTERNAL_BORDER_WIDTH_SAFE instead of
8977         FRAME_INTERNAL_BORDER_WIDTH.
8979         * xdisp.c (try_window_id): Recompute unchanged information if
8980         it is obviously invalid.
8982         * xterm.c (x_term_init): Create a colormap if not using the
8983         default visual.
8985         * xterm.h (select_visual): Change prototype.
8987         * xfns.c (select_visual): Rewritten.  Recognize user-specified
8988         visual classes.
8989         (visual_classes): New variable.
8991 2000-03-04  Gerd Moellmann  <gerd@gnu.org>
8993         * xfns.c (x_defined_color, x_set_mouse_color, lookup_rgb_color)
8994         (lookup_pixel_color, x_laplace, x_build_heuristic_mask)
8995         (png_load): Access colormap of frame using FRAME_X_COLORMAP.
8996         (x_decode_color): Don't handle allocation of white and black
8997         specially.
8998         (x_window) [USE_X_TOOLKIT]: Set XtNvisual, XtNdepth, and
8999         XtNcolormap resources.
9000         (x_window) [!USE_X_TOOLKIT]: Pass colormap to XCreateWindow.
9001         (Fx_create_frame): Initialize color members of x_output structure.
9002         (xpm_load): Pass colormap to XPM lib.
9004         * xfaces.c (x_free_colors): Access colormap of frame using
9005         FRAME_X_COLORMAP.  Be paranoid about freeing black and white
9006         when default colormap is used.
9008         * xterm.c (x_term_init): Set Colormap member of x_display_info
9009         structure.  Copy colormap if resource `privateColormap' is
9010         specified (PseudoColor only).
9011         (x_setup_relief_color): Access colormap of frame using
9012         FRAME_X_COLORMAP.
9014         * xterm.h (struct x_display_info): Add Colormap member `cmap'.
9015         (FRAME_X_COLORMAP, FRAME_X_VISUAL): New macros.
9017 2000-03-04  Jason Rumney  <jasonr@gnu.org>
9019         * xfaces.c Change many FRAME_X... macros to FRAME_WINDOW... or
9020         other non-platform-specific equivalents.
9021         [WINDOWSNT]: Include w32term.h, fontset.h and define X
9022         specific functions and macros as their w32 equivalents where
9023         non-platform-specifics are not available.
9024         [HAVE_X_WINDOWS]: Change most of these to HAVE_WINDOW_SYSTEM.
9025         (x_create_gc, x_free_gc) [WINDOWSNT]: Add W32 versions.
9026         (clear_font_table) [WINDOWSNT]: Call w32_unload_font.
9027         (frame_update_line_height): Use macros to access f->output_data.
9028         (defined_color): Remove FIXME comments; fixed.
9029         (x_face_list_fonts, prepare_face_for_display): Put X specifics
9030         into #ifdef blocks. Add WINDOWSNT blocks.
9031         (Fx_list_fonts): Use macros for accessing font data.
9032         (set_lface_from_font_name): Different default fonts for X and
9033         WINDOWSNT.
9034         (font_scalable_p) [WINDOWSNT]: Treat wildcard XLFD_AVGWIDTH as
9035         scalable for backward compatibility.
9036         (realize_tty_face) [MSDOS]: Do the same for WINDOWSNT.
9037         (syms_of_xfaces) [WINDOWSNT]: Allow scalable fonts by default.
9039         * emacs.c (main) [HAVE_NTGUI]: Call syms_of_xfaces instead of
9040         syms_of_w32faces.
9042         * makefile.nt (w32faces.obj): Remove.
9043         (xfaces.obj): Add.
9045 2000-03-03  Jason Rumney  <jasonr@gnu.org>
9047         * keyboard.c (make_lispy_event): Call buffer_posn_from_coords with
9048         correct parameters.
9050 2000-03-03  Ken Raeburn  <raeburn@gnu.org>
9052         * unexelf.c (PT_LOAD, SHT_*, SHN_*) [__NetBSD__]: Only provide
9053         standard ELF definitions here if the system header does not.
9055 2000-03-03  Gerd Moellmann  <gerd@gnu.org>
9057         * xterm.c (PER_CHAR_METRIC): Removed.
9058         (x_per_char_metric_1, x_default_char): New functions.
9059         (x_per_char_metric): If font's default char is invalid, return
9060         metrics of a suitably chosen usable default char.
9061         (x_draw_glyph_string_foreground): If font has an invalid default
9062         char, replace occurrences of unprintable chars with a suitably
9063         chosen usable default char.
9065 2000-03-02  Gerd Moellmann  <gerd@gnu.org>
9067         * xterm.c (note_mouse_highlight): Return quickly if frame's
9068         glyph matrices have been freed.
9070         * dispnew.c (free_glyphs): Block input while freeing matrices.
9072         * xfns.c (x_clear_image, x_kill_gs_process): Use x_free_colors.
9074         * xterm.c (x_alloc_lighter_color, x_setup_relief_color): Use
9075         x_free_colors.
9077         * dispextern.h (x_free_colors): Add prototype.
9079         * xfaces.c (x_free_colors): New function.
9080         (unload_color, free_face_colors): Use it.
9082 2000-03-02  Eli Zaretskii  <eliz@is.elta.co.il>
9084         * msdos.h (FRAME_INTERNAL_BORDER_WIDTH): Define to zero.
9086         * window.c [MSDOS]: Include msdos.h.
9088 2000-03-02  Dave Love  <fx@gnu.org>
9090         * m/powerpcle.h, m/sparc.h: Don't set C_OPTIMIZE_SWITCH.
9092         * m/mips-siemens.h, m/news-r6.h, m/news-risc.h, m/tekxd88.h: Don't
9093         set C_OPTIMIZE_SWITCH for gcc.
9095 2000-03-02  Kenichi Handa  <handa@etl.go.jp>
9097         * coding.c (coding_save_composition): Be sure to allocate
9098         composition data area in coding even if there's no composition in
9099         the current run.
9101 2000-03-01  Jason Rumney  <jasonr@gnu.org>
9103         * w32term.c: Equivalent changes to those made to xterm.c on
9104         2000-02-25 and 2000-02-24.
9106         * w32fns.c: Equivalent changes to those made to xfns.c on
9107         2000-02-25 and 2000-02-21.
9109         * sysdep.c: [WINDOWSNT]: Use sys_read and sys_write to ensure
9110         correct line-end convention is followed.
9112         * w32menu.c [HAVE_BOXES]: Remove #undef.
9113         (single_keymap_panes): Remove code for simulating checkmarks.
9114         (single_menu_item): Remove notbuttons_ptr argument. Callers changed.
9115         Remove code for drawing simulated checkmarks.
9116         (w32_menu_show): make unibyte help string correctly.
9117         (add_menu_item): draw standard Windows checkmarks. Draw radio
9118         buttons as radio buttons if possible.
9120 2000-03-01  Gerd Moellmann  <gerd@gnu.org>
9122         * sysdep.c (start_of_text): Don't define this function for NetBSD
9123         with ELF.
9125         * m/pmax.h (START_FILES, CANNOT_DUMP) [__NetBSD__ || __OpenBSD__]:
9126         Don't define.
9127         (UNEXEC) [__NetBSD__ || __OpenBSD__]: Define to unexelf.o.
9128         (LINKER): Don't undef if __NetBSD__ is defined.
9130         * m/mips.h (LINKER) [__NetBSD__ || __OpenBSD__]: Don't define.
9132         * fileio.c [__NetBSD__]: Define `unix'.
9134         * xfns.c (start_busy_cursor): Allow floats for busy-cursor-delay.
9136 2000-02-29  Gerd Moellmann  <gerd@gnu.org>
9138         * atimer.c (start_atimer): Don't abort when timers are stopped.
9139         (append_atimer_lists): New function.
9140         (cancel_atimer, stop_other_atimers, run_all_atimers): Handle
9141         arbitrary lists of stopped and running atimers.
9143         * atimer.c (cancel_atimer): Handle canceling an atimer when
9144         some timers are stopped.
9146         * xfns.c (cancel_busy_cursor): Set busy_cursor_atimer to null
9147         after canceling it.
9149         * fns.c (maybe_resize_hash_table): Handle case of new size
9150         coming out as being the same as old size.
9152 2000-02-27  Jason Rumney  <jasonr@gnu.org>
9154         * makefile.nt: Add atimer.h to dependencies.
9155         * w32.c (init_environment): Set Vw32_num_mouse_buttons here.
9156         * w32console.c: Only disable window system features for dispextern.h
9157         (initialize_w32_display): Build a display info for the console.
9158         * w32faces.c (tty_defined_color): Apply xfaces.c change from 02-17.
9159         * w32fns.c (w32_wnd_proc) [WM_LBUTTON_DOWN, WM_RBUTTON_DOWN,
9160         WM_LBUTTON_UP, WM_RBUTTON_UP]: Do not treat 4 or more button mice
9161         as 2 button mice.
9162         * w32gui.h (struct W32FontStruct): Revert last change after change
9163         to xdisp.c.
9164         * w32menu.c (single_submenu): Set up help string.
9165         [!HAVE_MULTILINGUAL_MENU]: Don't overwrite item_name with descrip.
9166         (w32_dialog_show): Set up help string.
9167         * w32term.c (w32_display_info_for_display): Remove unused function.
9168         (w32_draw_bitmap): Use pre-built bitmaps.
9169         (w32_initialize_display_info): New function to initialize parts of
9170         display info that are common to both GUI and console frames.
9171         (w32_term_init): Use w32_initialize_display_info. Do not set
9172         Vw32_num_mouse_buttons here, as it is not called for console
9173         frames.  Build bitmaps for indicating truncated lines etc.
9174         (x_delete_display): Destroy pre-built bitmaps.
9175         * xdisp.c (handle_single_display_prop): Use FONT_HEIGHT macro.
9176         (echo_area_display): Change HAVE_X_WINDOWS to HAVE_WINDOW_SYSTEM.
9178 2000-02-27  Dave Love  <fx@gnu.org>
9180         * lisp.h: Add a bunch of prototypes.
9182 2000-02-26  Kenichi Handa  <handa@etl.go.jp>
9184         * keyboard.c (read_char): Set `usec' correctly.
9186 2000-02-25  Miyashita Hisashi  <himi@bird.scphys.kyoto-u.ac.jp>
9188         * ccl.c (ccl_driver) [CCL_MapMultiple]: When the mapped value is
9189         `lambda', set reg[RRR] to the map index.
9190         (ccl_driver) [CCL_MapSingle]: When the mapped value is found, set
9191         reg[RRR] to 0.  Otherwise, set it to -1.
9193 2000-02-25  Gerd Moellmann  <gerd@gnu.org>
9195         * emacs.c (main): Remove code snippet commented out with `//'.
9197 2000-02-25  Richard M. Stallman  <rms@gnu.org>
9199         * fileio.c (Ffile_symlink_p): If result starts with a `/'
9200         and contains a `:', prepend `/:'.
9202         * window.c (select_window_1): If selected_window is nil,
9203         don't "swap out" the buffer's point.
9204         (Fset_window_configuration): Set selected_window to nil
9205         before calling Fselect_window.
9206         (unshow_buffer): Don't set point in buffer from window's point
9207         if another more recently selected window also shows the buffer.
9209 2000-02-25  Gerd Moellmann  <gerd@gnu.org>
9211         * keyboard.c (recursive_edit_1): Cancel busy-cursor.
9213         * xfns.c (inhibit_busy_cursor, busy_count): Removed.
9214         (Fx_show_busy_cursor, Fx_hide_busy_cursor): Removed.
9215         (busy_cursor_atimer, busy_cursor_shown_p, Vbusy_cursor_delay): New
9216         variables.
9217         (DEFAULT_BUSY_CURSOR_DELAY): New define.
9218         (start_busy_cursor, cancel_busy_cursor, show_busy_cursor)
9219         (hide_busy_cursor): New functions.
9220         (syms_of_xfns): DEFVAR_LISP Vbusy_cursor_delay.
9222         * minibuf.c (read_minibuf): Cancel busy-cursor.
9224         * keyboard.c (command_loop_1): Call start_busy_cursor before
9225         Fcommand_execute and cancel_busy_cursor after it.
9226         (timer_check): Remove busy-cursor code.
9227         (Fread_key_sequence, Fread_key_sequence_vector): Start/cancel busy
9228         cursor timer.
9230         * process.c (wait_reading_process_input): Remove busy-cursor code.
9232         * eval.c (Fsignal): Call cancel_busy_cursor instead of
9233         Fx_hide_busy_cursor.
9235         * dispextern.h (Fx_show_busy_cursor, Fx_hide_busy_cursor):
9236         Remove prototyoes.
9237         (start_busy_cursor, cancel_busy_cursor): Add prototypes.
9239         * lisp.h (Fx_hide_busy_cursor): Remove prototype.
9241         * xterm.c (XTread_socket): Remove busy-cursor code.
9243         * dispnew.c (flush_stdout) [GLYPH_DEBUG]: New function.
9244         (build_frame_matrix_from_leaf_window): Put code handling
9245         glyph row's not being a slice of a frame row in #if 0.
9246         (sync_window_with_frame_matrix_rows): New function.
9247         (frame_row_to_window): New function.
9248         (mirror_line_dance): Handle copies between windows.
9250         * lread.c (Fload): Use `xfree' instead of `free'.
9251         (init_obarray): Use `xmalloc' instead of `malloc'.
9253         * window.c (Fset_window_buffer): Set WINDOW to the window
9254         after decoding.
9255         (coordinates_in_window): Take frame's internal border width
9256         into account.
9258 2000-02-24  Gerd Moellmann  <gerd@gnu.org>
9260         * xterm.c (x_display_and_set_cursor): Display cursor of
9261         non-selected windows depending on the setting of
9262         cursor_in_non_selected_windows.
9264         * xdisp.c (cursor_in_non_selected_windows): New variable.
9265         (syms_of_xdisp): DEFVAR_BOOL it.
9267 2000-02-23  Gerd Moellmann  <gerd@gnu.org>
9269         * data.c (Fstring_to_number): If number is greater than what
9270         fits into an integer, return a float.
9272         * eval.c (specbind): Remove references to
9273         keyword_symbols_constant_flag.
9275         * data.c (keyword_symbols_constant_flag): Removed.
9276         (Fmakunbound, set_internal, syms_of_data): Remove references to
9277         keyword_symbols_constant_flag.
9279         * bytecode.c (Fbyte_code): Remove keyword_symbols_constant_flag.
9281 2000-02-23  Kenichi Handa  <handa@etl.go.jp>
9283         * syntax.c (multibyte_syntax_as_symbol): New variable.
9284         (syms_of_syntax): Declare it as a Lisp variable.
9285         (SYNTAX_WITH_MULTIBYTE_CHECK): New macro.
9286         (scan_lists): If both sexpflag and multibyte_syntax_as_symbol are
9287         nonzero, treat all multibyte characters as symbol.
9288         (init_syntax_once): Give syntax `word' to all multibyte
9289         characters.
9291 2000-02-22  Eli Zaretskii  <eliz@is.elta.co.il>
9293         * frame.c (Fdelete_frame): Don't let echo_area_window remain on
9294         a deleted frame.
9296 2000-02-21  Gerd Moellmann  <gerd@gnu.org>
9298         * frame.c (Fmouse_position): GCPRO retval instead of x and y.
9300         * xfns.c (x_window_to_frame, x_any_window_to_frame)
9301         (x_non_menubar_window_to_frame): Check the busy-cursor window.
9303 2000-02-21  Dave Love  <fx@gnu.org>
9305         * frame.c (Vmouse_position_function): New variable.
9306         (Fmouse_position): Use it.
9307         (syms_of_frame): Install it.
9309         * charset.c (find_charset_in_str): Fix use of `c' instead of `c1'.
9311 2000-02-20  Gerd Moellmann  <gerd@gnu.org>
9313         * fileio.c (Finsert_file_contents): Unbind the binding of
9314         standard-output done by temp_output_buffer_setup.
9316         * eval.c (funcall_lambda): Don't bind Qmocklisp_arguments unless
9317         Vmocklisp_arguments is nil.  Inline Fcar and Fcdr.
9318         (specbind, unbind_to): Handle most common case of non-constant
9319         symbol with trivial value specially.
9321         * bytecode.c (Fbyte_code) <Bvarset>: Inline most common case.
9323 2000-02-20  Richard M. Stallman  <rms@gnu.org>
9325         * data.c (Fmake_variable_buffer_local): Doc fix.
9326         Init found_for_buffer to 0.
9327         (Fmake_variable_frame_local): If the variable has already
9328         been buffer-local, set the check_frame field.
9330 2000-02-20  Eli Zaretskii  <eliz@is.elta.co.il>
9332         * msdos.c (IT_write_glyphs): Allocate a larger screen_buf as data
9333         produced for CODING_MODE_LAST_BLOCK requires.
9335 2000-02-18  Dave Love  <fx@gnu.org>
9337         * keyboard.c (echo_keystrokes): Remove declaration.
9338         (Vecho_keystrokes) New variable.
9339         (read_char, record_menu_key, read_key_sequence): Use it to allow
9340         use of float value.
9341         (syms_of_keyboard): Change Vecho_keystrokes declaration.
9343         * lread.c: Undef feature selection macros before defining.
9345 2000-02-18  Gerd Moellmann  <gerd@gnu.org>
9347         * data.c (let_shadows_buffer_binding_p): Ignore specbindings
9348         for symbols other than the symbol in question.
9350 2000-02-17  Dave Love  <fx@gnu.org>
9352         * s/sol2.h (C_DEBUG_SWITCH): Define to allow optimization.
9354 2000-02-17  Gerd Moellmann  <gerd@gnu.org>
9356         * emacs.c (main): Use #if GC_MARK_STACK instead of #ifdef.
9358         * alloc.c (enum mem_type): Compile unconditionally.
9360 2000-02-17  Eli Zaretskii  <eliz@is.elta.co.il>
9362         * xfaces.c (tty_defined_color): Don't return faulire indication
9363         for unspecified-fg and unspecified-bg pseudo-colors.
9365 2000-02-17  Gerd Moellmann  <gerd@gnu.org>
9367         * alloc.c (mark_object): Don't mark symbol names in pure space.
9368         (gc_sweep): Don't unmark symbol names in pure space.
9370         * lisp.h (GC_USE_GCPROS_AS_BEFORE, GC_MAKE_GCPROS_NOOPS)
9371         (GC_MARK_STACK_CHECK_GCPROS, GC_USE_GCPROS_CHECK_ZOMBIES)
9372         [GC_MARK_STACK]: New defines.
9373         (GCPRO1, GCPRO2, GCPRO3, GCPRO4, GCPRO5, UNGCPRO)
9374         [GC_MARK_STACK == GC_MAKE_GCPROS_NOOPS]: Define as no-ops.
9376         * emacs.c (main) [GC_MARK_STACK]: Initialize stack_base.
9378         * buffer.c (Fget_buffer_create, Fmake_indirect_buffer): Use
9379         allocate_buffer instead of xmalloc.
9381         * alloc.c (toplevel): Include setjmp.h.
9382         (PURE_POINTER_P): New define.
9383         (enum mem_type) [GC_MARK_STACK]: New enumeration.
9384         (Vdead) [GC_MARK_STACK]: New variable.
9385         (lisp_malloc): Add parameter TYPE, call mem_insert if
9386         GC_MARK_STACK is defined.
9387         (allocate_buffer): New function.
9388         (lisp_free) [GC_MARK_STACK]: Call mem_delete.
9389         (free_float) [GC_MARK_STACK]: Set type to Vdead.
9390         (free_cons) [GC_MARK_STACK]: Set car to Vdead.
9391         (stack_base, mem_root, mem_z) [GC_MARK_STACK]: New variables.
9392         (MEM_NIL) [GC_MARK_STACK]: New define.
9393         (struct mem_node) [GC_MARK_STACK]: New structure.
9394         (mem_init, mem_find, mem_insert, mem_delete, mem_insert_fixup)
9395         (mem_delete_fixup, mem_rotate_left, mem_rotate_right)
9396         (live_string_p, live_cons_p, live_symbol_p, live_float_p)
9397         (live_misc_p, live_vector_p, live_buffer_p, mark_memory)
9398         (mark_stack) [GC_MARK_STACK]: New functions.
9399         (Fgarbage_collect) [GC_MARK_STACK]: Call mark_stack.
9400         (clear_marks): Removed.
9401         (gc_sweep): Set free conses' car, free floats' type, free
9402         symbols' function to Vdead.  Use lisp_free to free buffers.
9403         (init_alloc_once): Initialize Vdead.
9404         (survives_gc_p): Return non-zero for pure objects.
9406         * alloc.c: Add comments throughout the file.
9408         * atimer.c (stop_other_atimers): Don't call cancel_atimer because
9409         that unblocks alarms.
9411         * alloc.c, bytecode.c, data.c, dispnew.c, ecrt0.c, editfns.c,
9412         emacs.c, floatfns.c, fns.c, lread.c, print.c, config.in, lisp.h,
9413         Makefile.in: Remove `LISP_FLOAT_TYPE' and `standalone'.
9415         * frame.c (make_frame): Set frame initiallly to `garbaged'.
9417 2000-02-17  Kenichi Handa  <handa@etl.go.jp>
9419         * xdisp.c (decode_mode_spec_coding): Delete superfluous code to
9420         avoid infinite error signaling.  Allocate sufficient memory for
9421         eol_str in the case that eoltype is Lisp_Int.
9423 2000-02-17  Stefan Monnier  <monnier@cs.yale.edu>
9425         * syntax.c (Fforward_comment): Undo the previous change, since cc-mode
9426         depends on the previous behavior.
9428 2000-02-16  Gerd Moellmann  <gerd@gnu.org>
9430         * sysdep.c (vfork) [!HAVE_VFORK]: Removed.
9432 2000-02-15  Gerd Moellmann  <gerd@gnu.org>
9434         * s/freebsd.h (BROKEN_PTY_READ_AFTER_EAGAIN): Define.
9436         * process.c (send_process) [BROKEN_PTY_READ_AFTER_EAGAIN]:
9437         Workaround for FreeBSD bug.  Clear output queue after EAGAIN in
9438         write(2).
9440 2000-02-15  Richard M. Stallman  <rms@gnu.org>
9442         * data.c (set_internal): Don't make variable buffer-local
9443         if within a let-binding for the same buffer.
9444         (let_shadows_buffer_binding_p): New function.
9446         * eval.c (specbind): For buffer-local value,
9447         record the current buffer also.
9448         (unbind_to): Cope with that change.
9450 2000-02-15  Gerd Moellmann  <gerd@gnu.org>
9452         * window.c (Fsave_window_excursion): Doc fix.
9454 2000-02-15  Stefan Monnier  <monnier@cs.yale.edu>
9456         * syntax.c (back_comment): Make sure we only consider comment-starters
9457         of the relevant style and return -1 in case of a failure to find the
9458         beginning of the comment.
9459         (Fforward_comment): If back_comment fails, go back to the position just
9460         after the comment-end.
9461         (scan_lists): Add comment describing a very minor bug.
9463 2000-02-14  Stefan Monnier  <monnier@cs.yale.edu>
9465         * minibuf.c (Ftry_completion, Fall_completions): Add a reference to
9466         `completion-regexp-list' in the docstring.
9468 2000-02-14  Dave Love  <fx@gnu.org>
9470         * xfaces.c (tty_defined_color): Declare color_idx unsigned long.
9472 2000-02-14  Stefan Monnier  <monnier@cs.yale.edu>
9474         * regex.h (RE_SYNTAX_EMACS): Add RE_CHAR_CLASSES and RE_INTERVALS
9475         to Emacs' syntax.  Also fix the comment about set/not-set meanings
9476         since Emacs syntax is not the value 0 any more.
9477         * search.c (compile_pattern_1): Remove RE_CHAR_CLASSES from the syntax
9478         since it's now part of RE_SYNTAX_EMACS.
9480 2000-02-12  Dave Love  <fx@gnu.org>
9482         * frame.h (SELECTED_FRAME): Use NULL, not 0 to avoid warnings on
9483         Alpha.
9485 2000-02-12  Gerd Moellmann  <gerd@gnu.org>
9487         * xdisp.c (syms_of_xdisp): Doc fix for scroll-conservatively.
9489 2000-02-12  Dave Love  <fx@gnu.org>
9491         * s/aix3-2.h, s/osf-1.h: Define C_DEBUG_SWITCH for non-gcc.
9493         * s/ux4800.h, s/umips.h, s/umax.h, s/sol2.h, s/sco5.h, s/rtu.h:
9494         * s/ptx4.h, s/umax.h, s/dgux.h, s/bsd4-2.h, s/bsd4-3.h:
9495         * s/hpux.h: Don't define HAVE_VFORK.
9497         * s/gnu-linux.h: Don't define HAVE_VFORK or HAVE_SYS_SIGLIST.
9499         * s/nextstep.h: Don't define HAVE_ALLOCA.
9501         * config.in: Add vfork bits.
9503 2000-02-12  Gerd Moellmann  <gerd@gnu.org>
9505         * process.c (Fopen_network_stream) [POLL_FOR_INPUT]: Register
9506         unwind function to undo the effect of stopping atimers.
9508         * keyboard.c (bind_polling_period): Stop all timers except
9509         poll_timer.
9511         * atimer.c (stopped_atimers): New variable.
9512         (stop_other_atimers, run_all_atimers, unwind_stop_other_atimers):
9513         New functions.
9515         * atimer.h (stop_other_atimers, run_all_atimers)
9516         (unwind_stop_other_atimers): Add function prototypes.
9518         * s/hpux10.h (HAVE_XRMSETDATABASE): Define if not already defined.
9520 2000-02-11  Ken Raeburn  <raeburn@gnu.org>
9522         * Makefile.in (LIBX): Link in tiff library before jpeg, since tiff
9523         library may depend on jpeg.
9524         (atimer.o): Depends on atimer.c.
9526 2000-02-11  Kenichi Handa  <handa@etl.go.jp>
9528         * insdel.c (del_range_1): Call update_compositions.
9529         (del_range_both): Call update_compositions just once..
9531 2000-02-10  Dave Love  <fx@gnu.org>
9533         * xfns.c (create_frame_xic): Fix initialization of automatic
9534         aggregates for pcc.
9536 2000-02-09  Kenichi Handa  <handa@etl.go.jp>
9538         * ccl.c (CCL_MAKE_CHAR): New macro.
9539         (ccl_driver) <CCL_TranslateCharacter>: Check the validity of
9540         registers by CCL_MAKE_CHAR before calling translate_char.
9541         <CCL_TranslateCharacterConstTbl> Likewise.
9543 2000-02-08  Dave Love  <fx@gnu.org>
9545         * lread.c (__EXTENSIONS__): Define.
9547 2000-02-08  Gerd Moellmann  <gerd@gnu.org>
9549         * puresize.h (BASE_PURESIZE): Increase to 650000.
9551 2000-02-07  Eli Zaretskii  <eliz@is.elta.co.il>
9553         * msdos.c (XMenuActivate): Turn off the cursor after displaying
9554         the help message.
9556 2000-02-07  Eli Zaretskii <eliz@is.elta.co.il>
9558         * s/msdos.h (INTERNAL_TERMINAL): Add capabilities se, so, us, ue,
9559         md, mh, mb, mr, and me to the fake termcap entry.
9561 2000-02-06  Ken Raeburn  <raeburn@gnu.org>
9563         * sound.c (sound_cleanup): Don't call device close routine if the
9564         function pointer is null.
9566 2000-02-06  Andrew Innes  <andrewi@gnu.org>
9568         * dispextern.h: Change HAVE_X_WINDOWS to HAVE_WINDOW_SYSTEM,
9569         around image definitions and prototypes.
9570         (gamma_correct) [WINDOWSNT]: New prototype.
9572         * w32term.c (x_make_frame_visible): Replace call to
9573         input_poll_signal with poll_for_input.
9575         * window.c [WINDOWSNT]: Include w32term.h.
9577         * xdisp.c [WINDOWSNT]: Include w32term.h.
9579         * makefile.nt: Add dependencies on w32gui.h.
9580         (OBJ1): Include atimer.obj.
9581         ($(BLD)\atimer.obj): New dependency rule.
9583         * w32.c (sigmask): New function (does nothing).
9584         (sigunblock): Ditto.
9586         * frame.c [WINDOWSNT]: Include w32term.h.
9588         * w32gui.h (struct W32FontStruct): Add ascent and descent slots.
9590         * lread.c (syms_of_lread): Fix literal newlines.
9592         * emacs.c (USAGE): Split into USAGE1 and USAGE2, to work-around
9593         the string constant limit (2048 bytes) in MSVC.
9594         (main): Ditto.
9596 2000-02-05  INOUE Seiichiro <inoue@ainet.or.jp>
9598         * xterm.c (x_display_and_set_cursor) [HAVE_X_I18N]: Set pre-edit
9599         area.
9600         (x_display_cursor) [HAVE_X_I18N]: Don't set it here.
9601         (XTread_socket) [HAVE_X_I18N]: <KeyPress, KeyRelease>: Don't
9602         dispatch the event.
9604 2000-02-04  Dave Love  <fx@gnu.org>
9606         * fileio.c: Remove some unused vars.
9607         (_GNU_SOURCE): Define (for euidaccess).
9609         * lread.c (_XOPEN_SOURCE): Declare (for ftello).
9611         * minibuf.c (read_minibuf_noninteractive): Remove undeclared
9612         gcpro1, gcpro2.
9613         (read_minibuf): Deal with allow_props correctly.
9615 2000-02-03  Eli Zaretskii  <eliz@is.elta.co.il>
9617         * s/msdos.h (SYSTEM_PURESIZE_EXTRA): Enlarge to 60000.
9619 2000-02-03  Ken Raeburn  <raeburn@gnu.org>
9621         * search.c (compile_pattern): If a cache entry has a nil regexp,
9622         fill in that entry instead of clobbering a previously cached
9623         string regexp.
9625 2000-02-02  Ken Raeburn  <raeburn@gnu.org>
9627         * puresize.h (BASE_PURESIZE): Increase to 610000.
9629 2000-02-02  Gerd Moellmann  <gerd@gnu.org>
9631         * frame.c (Fframe_parameters): Add GCPRO because tty_color_name
9632         can GC.
9634 2000-02-02  Kenichi Handa  <handa@etl.go.jp>
9636         * ccl.c (ccl_driver) <CCL_WriteExprRegister>: Set jump_address
9637         instead of incrementing ic directly.
9638         <CCL_WriteExprConst> Likewise.
9639         <ccl_set_expr>: Set ic to jump_address.
9641         * fileio.c (e_write): Fix the handling of
9642         CODING_FINISH_INSUFFICIENT_SRC.
9644 2000-02-01  Dave Love  <fx@gnu.org>
9646         * editfns.c (Fpropertize): Doc fix.
9648         * process.c (Fstart_process): Doc fix.
9650         * eval.c: Fix various doc strings not to duplicate information
9651         from help-manyarg-func-alist.
9653         * window.c (Fset_window_margins): Don't make interactive.  Doc
9654         fix.
9656         * doc.c (Vhelp_manyarg_func_alist): New variable.
9657         (Fdocumentation): Use it.
9658         (syms_of_doc): Define it.
9660 2000-01-31  Gerd Moellmann  <gerd@gnu.org>
9662         * xterm.c (xim_open_dpy): Remove unused local variable.
9664         * emacs.c (USAGE): Use term `display options' instead of `X
9665         options'.
9667         * xdisp.c (Ftrace_to_stderr) [GLYPH_DEBUG]: New function.
9668         (syms_of_xdisp) [GLYPH_DEBUG]: Defsubr it.
9670         * fns.c (sweep_weak_table): New function.
9671         (sweep_weak_hash_tables): Use it.  Keep on marking until there
9672         is no more change.
9674 2000-01-30  Gerd Moellmann  <gerd@gnu.org>
9676         * xterm.c (x_delete_display): Update next_noop_dpyinfo to ensure
9677         that XTread_socket does not crash by trying to call XNoOp on a
9678         closed display.
9680 2000-01-30  Jason Rumney  <jasonr@gnu.org>
9682         * w32inevt.c (get_frame, w32_console_mouse_position, mouse_moved_to):
9683         Change selected_frame to SELECTED_FRAME ().
9684         (w32_console_mouse_position): Remove #ifndef MULE from around
9685         `insist' parameter.
9687         * makefile.nt: Remove dosfns.obj.
9689         * term.c (term_init) [WINDOWSNT]: Initialize TN_max_colors.
9691         * w32fns.c (w32_defined_color): Check for valid frame before
9692         applying gamma correction. Eliminate dependency on frame elsewhere.
9693         (w32_load_system_font): Switch FIXED_PITCH and VARIABLE_PITCH.
9694         (w32_to_x_font): Use resx and resy not height_in and width_in.
9695         (x_to_w32_font): Doc fix.
9696         (xlfd_strip_height): New function to strip and return font height.
9697         (w32_font_match): Compare height separately from rest of xlfd
9698         spec, using xlfd_strip_height.
9700         * w32term.c (w32_term_init): Swap resx and height_in, resy and
9701         width_in. Use w32_defined_color in place of defined_color.
9703         * w32faces.c: Merge more of DOS and X specifics in preparation for
9704         merge with xfaces.c.
9705         (defined_color): Remove FIXME comment.
9706         (tty_color_name): Provide w32-specific function.
9707         (realize_tty_face): Handle FACE_TTY_DEFAULT*_COLOR specially.
9709         * w32console.c (turn_on_face, turn_off_face): Removed.
9710         (w32_face_attributes): New function.
9711         (Global_variables): Reduce scope where possible.
9712         (clear_frame, ins_del_lines, scroll_line): Use char_attr_normal as
9713         fill attribute.
9714         (hl_mode): Don't modify text attributes.
9715         (write_glyphs): Don't do anything if len <= 0. Use
9716         w32_face_attributes to get attributes for drawing. Write
9717         terminating codes using char_attr_normal.
9718         (reset_terminal_modes, set_terminal_modes): Turn off highlight.
9719         (update_begin, update_end): Likewise.
9720         (vga_stdcolor_name): New function.
9721         (initialize_w32_display): Remove char_attr_reverse and char_attr.
9722         (Fset_screen_color): Remove char_attr_reverse.
9724 2000-01-29  Gerd Moellmann  <gerd@gnu.org>
9726         * xfns.c (xic_set_preeditarea): Take window parameter and
9727         window-relative pixel-positions.
9729         * xterm.c (x_display_cursor): Set XIC pre-edit area only if window
9730         is its frame's selected window.
9731         (xim_instantiate_callback): Likewise.
9733         * xfns.c (x_create_im): Removed.
9734         (DEFAULT_STYLE, DEFAULT_FONT): Removed.
9735         (supported_xim_styles): Renamed from supported_styles.
9736         (best_xim_style): Renamed from best_style.
9737         (create_frame_xic): Renamed from xic_create_frame.
9738         (free_frame_xic): Renamed from xic_destroy_frame.
9740 2000-01-29  INOUE Seiichiro <inoue@ainet.or.jp>
9742         * xterm.c (XTread_socket) [HAVE_X_I18N]: If event is for none of
9743         our frames, call XFilterEvent with 2nd parameter `None'.
9744         (XTread_socket) <KeyPress> [HAVE_X_I18N]: Handle XmbLookupString
9745         returning XBufferOverflow.
9746         (XTread_socket) <ConfigureNotify> [HAVE_X_I18N]: Set XIC status
9747         area.
9748         (x_display_cursor) [HAVE_X_I18N]: Set XIC pre-edit area.
9749         (x_new_fontset) [HAVE_X_I18N]: Create XIC status area fontset.
9750         (xim_destroy_callback, xim_open_dpy, xim_instantiate_callback)
9751         (xim_initialize, xim_close)
9752         [HAVE_X_I18N && HAVE_X11R6]: New functions.
9753         (x_destroy_window) [HAVE_X_I18N]:  Call xic_destroy_frame.
9754         (x_term_init) [HAVE_X_I18N]: Call xim_initialize.
9755         (x_delete_display) [HAVE_X_I18N]: Call xim_close.
9757         * xterm.h (struct x_display_info) [HAVE_X_I18N]: Add members `xim'
9758         and `xim_styles'.
9759         (struct x_output) [HAVE_X_I18N]: Remove member `xim', add
9760         `xic_style' and `xic_xfs'.
9761         (FRAME_MENUBAR_HEIGHT, FRAME_X_XIM, FRAME_X_XIM_STYLES)
9762         (FRAME_XIC_STYLE, FRAME_XIC_FONTSET): New macros.
9763         (FRAME_XIM): Removed.
9765         * xfns.c (supported_styles): New variable.
9766         (DEFAULT_STYLE, DEFAULT_FONT): New macros
9767         (xic_create_xfontset, best_style, xic_create_frame)
9768         (xic_destroy_frame, xic_set_preeditarea, xic_set_statusarea)
9769         (xic_set_xfontset): New functions.
9771 2000-01-28  Dave Love  <fx@gnu.org>
9773         * s/irix6-5.h: Revert last change after change to irix5-0.h.
9775         * m/iris4d.h (C_SWITCH_MACHINE): Don't use -G0.
9777 2000-01-28  Gerd Moellmann  <gerd@gnu.org>
9779         * buffer.c (Fother_buffer): Don't call Fset_buffer_major_mode
9780         for *scratch* if it already existed.
9782         * emacs.c (USAGE): New macro.
9783         (main): Use it to display usage information.
9785 2000-01-27  Eli Zaretskii  <eliz@is.elta.co.il>
9787         Support for the menu-help feature:
9789         * msdos.h: Change prototypes of XMenuAddSelection and
9790         XMenuActivate.
9792         * msdos.c (IT_clear_end_of_line): Print the extent of the cleared
9793         part of the line to the termscript file.
9794         (IT_clear_to_end): Clear the entire line, not just its beginning.
9795         (menu_help_message, prev_menu_help_message): New variables.
9796         (IT_menu_make_room): Make room for the help_text member.
9797         (IT_menu_display): New argument disp_help; all callers changed.
9798         If disp_help is non-zero, store the help text of the active menu
9799         item in menu_help_message.
9800         (XMenuAddPane): Initialize the help_text member to NULL.
9801         (XMenuAddSelection): New argument help_text.  Store it in the
9802         XMenu structure.
9803         (XMenuActivate): New argument help_callback.  If the value of
9804         menu_help_message has changed since the last time, display the
9805         menu help message text while waiting for the mouse to move.  Clear
9806         the echo area before exiting.
9807         (XMenuDestroy): Free the help_text member.
9809 2000-01-27  Gerd Moellmann  <gerd@gnu.org>
9811         * xmenu.c (xmenu_show) [!USE_X_TOOLKIT]: Pass help to
9812         XMenuAddSelection.  Pass help callback to XMenuActivate.
9813         (menu_help_callback) [!USE_X_TOOLKIT]: New function.
9815 2000-01-27  Eli Zaretskii  <eliz@is.elta.co.il>
9817         * atimer.c (start_atimer) [!HAVE_SETITIMER]: Use EMACS_SET_SECS
9818         and EMACS_SET_USECS.
9820 2000-01-26  Dave Love  <fx@gnu.org>
9822         * editfns.c (Fchar_after, Fchar_before): Doc fix.
9824         * bytecode.c (Fbyte_code): Use {BEFORE,AFTER}_POTENTIAL_GC where
9825         an error may be signalled.
9827 2000-01-26  Gerd Moellmann  <gerd@gnu.org>
9829         * s/irix6-5.h [__GNUC__ && __GNUC_MINOR__ >= 95]: Undef
9830         LD_SWITCH_SYSTEM inherited from irix5-0.h.
9832         * bytecode.c (Fbyte_code) [BYTE_CODE_SAFE]: Fix typo.
9834 2000-01-25  Gerd Moellmann  <gerd@gnu.org>
9836         * charset.c (Fstring): If there is a multibyte char among
9837         the args, always return a multibyte string.
9839 2000-01-25  Gerd Moellmann  <gerd@gnu.org>
9841         * sysdep.c (sys_select): Turn atimers off and on instead of
9842         recording and restoring old alarm handler
9844         * process.c (toplevel): Include atimer.h.
9845         (create_process_1): Rewritten.
9846         (create_process): Use atimers instead of alarm.
9847         (wait_reading_process_input) [hpux]: Turn atimers off instead
9848         of turning off SIGALRM.
9849         (wait_reading_process_input): Turn off atimers instead off
9850         calling stop_polling.
9852         * emacs.c (main): Call init_atimer.
9854         * keyboard.c (toplevel): Include systime.h and atimer.h.
9855         (polling_for_input): Removed because unused.
9856         (input_poll_signal) [POLL_FOR_INPUT]: Removed.
9857         (poll_timer): New variable.
9858         (poll_for_input, poll_for_input_1): New functions.
9859         (start_polling, stop_polling): Rewritten.
9861         * keyboard.h (polling_for_input): Removed.
9863         * atimer.h, atimer.c: New files.
9865         * Makefile.in (obj): Add atimer.o.
9866         (atimer.o): New target.
9868         * blockinput.h (pending_atimers): Add extern declaration.
9869         (UNBLOCK_INPUT): Rewritten.  Handle pending atimers.
9871         * lisp.h (popup_activated_flag): Add extern declaration.
9873         * xmenu.c (popup_activated_flag): Make externally visible.
9874         (popup_activate_callback) [USE_MOTIF]: Increment
9875         popup_activated_flag.
9876         (popup_deactivate_callback) [USE_MOTIF]: Decrement it.
9878         * xterm.c (toplevel): Include atimer.h.
9879         (toolkit_scroll_bar_interaction): New variable.
9880         (Fxt_process_timeouts): Removed.
9881         (x_process_timeouts): New function.
9882         (xt_action_hook): Clear toolkit_scroll_bar_interaction.
9883         (x_send_scroll_bar_event): Set toolkit_scroll_bar_interaction.
9884         (x_make_frame_visible): Call poll_for_input_1 instead of
9885         input_poll_signal.  Don't call alarm.
9886         (x_initialize): Install timer calling x_process_timeouts.
9888 2000-01-24  Dave Love  <fx@gnu.org>
9890         * s/irix5-0.h: Don't set LD_SWITCH_SYSTEM -- we use unexelf now.
9891         Don't use -cckr -- apparently not now necessary.
9893 2000-01-24  Eli Zaretskii  <eliz@is.elta.co.il>
9895         * msdos.c (IT_menu_display): Truncate long menu lines at the right
9896         screen boundary.
9898 2000-01-23  Jason Rumney  <jasonr@gnu.org>
9900         * w32fns.c (w32_defined_color): Apply gamma correction before
9901         trying to map to the palette.
9902         (w32_wnd_proc) [WM_ERASE_BACKGROUND]: Pass device context of frame
9903         to w32_clear_rect.
9905         * w32term.c (w32_fill_rect): Do not try to deal with NULL hdc
9906         here. Callers changed to always pass real device context.
9907         (w32_draw_bitmap): Likewise.
9908         (w32_get_glyph_overhangs): Likewise.
9909         (w32_draw_box_rect): Make use of s->hdc rather than getting a new
9910         one.
9911         (w32_set_vertical_scroll_bar): Pass correct HWND parameters to
9912         pfnSetScrollInfo and SetScrollRange.
9913         (x_get_char_face_and_encoding): Don't turn iso8859-1 characters
9914         back into MULE characters after decoding them.
9915         (x_get_glyph_face_and_encoding): Likewise.
9916         (w32_per_char_metric): Use GetCharExtentPoint32W as fallback when
9917         GetCharABCWidthsW fails, since this is defined on Windows 9x.
9918         (x_produce_glyphs): Calculate per char metrics for a character
9919         that we know exists in default font when font_not_found_p is true.
9921 2000-01-22  Jason Rumney <jasonr@gnu.org>
9923         * makefile.nt (intervals.obj, composite.obj): New modules.
9924         (composite.h): Added as dependency where appropriate.
9926         * w32gui.h (XGCValue): New struct for emulating X GCs.
9928         * w32term.h (XCharStruct): New struct for emulating X.
9930         * w32console.c (turn_on_face, turn_off_face): New functions.
9931         (change_line_highlight): New prototype for new redisplay.
9932         (write_glyphs): Support multibyte text. Support faces.
9934         * w32faces.c: Complete rewrite for new redisplay based on new
9935         xfaces.c.
9937         * w32fns.c: Use SELECTED_FRAME macro in place of selected_frame
9938         throughout. struct frame * in place of FRAME_PTR.
9939         Skeleton support for images, toolbars, tooltips from xfns.c.
9940         (Fx_create_frame): Use system default for default scroll bar
9941         width.
9942         (w32_get_arg): Renamed from x_get_arg.
9943         (Fx_file_dialog): New function.
9944         (w32_list_fonts): Check cache before asking system.
9945         (Vw32_enable_synthesized_fonts): New variable.
9946         (Vw32_enable_italics): Obsolete, removed.
9948         * w32inevt.c (get_frame, w32_console_mouse_position, mouse_moved_to):
9949         Use SELECTED_FRAME macro.
9951         * w32menu.c: Add skeleton support for help strings on menus.
9952         (add_menu_item): Native checkbox and radio support added, but not
9953         yet enabled due to bugs.
9954         (push_menu_item): Add parameters type, selection and help.
9955         Callers updated.
9956         Formatting changes to reduce unnecessary diffs with xmenu.c.
9958         * w32select.c (Fw32_set_clipboard_data): Update call to
9959         find_charset_in_str.
9961         * w32term.c: Complete rewrite for new redisplay based on new
9962         xterm.c with necessary sections merged back in from old w32term.c.
9964 2000-01-21  Richard M. Stallman  <rms@gnu.org>
9966         * data.c (set_internal): Further fix in same criterion.
9968 2000-01-20  Richard M. Stallman  <rms@gnu.org>
9970         * data.c (set_internal): Fix the criteria for whether
9971         to swap out the old cached binding.
9973 2000-01-19  Dave Love  <fx@gnu.org>
9975         * lread.c: (syms_of_lread) [user-init-file]: Doc change.
9977 2000-01-18  Kenichi Handa  <handa@etl.go.jp>
9979         * regex.c (re_compile_fastmap): While checking a range table for
9980         `charset', skip flag bits for a character class correctly.
9982 2000-01-17  Gerd Moellmann  <gerd@gnu.org>
9984         * m/news-risc.h (LD_SWITCH_MACHINE): Define differently for GCC.
9986         * xfns.c (x_window): Call lw_create_widget with new parameter
9987         list.
9989         * widget.c (EmacsFrameSetCharSize): Change size of children first
9990         because of problems with main window geometry management under
9991         Lesstif.
9993         * xmenu.c (enum menu_item_idx): New enumeration replacing defines
9994         MENU_ITEMS_ITEM_.*.
9995         (MENU_ITEMS_ITEM_HELP): New enumerator.
9996         (push_menu_item): Add parameter HELP.  Record help in menu_items.
9997         (single_menu_item, single_submenu, list_of_items): Call
9998         push_menu_item with new parameter.
9999         (single_submenu): Set help string in widget value.
10000         (menu_highlight_callback): New function.
10001         (set_frame_menubar): Call lw_create_widget with new
10002         parameter list.
10003         (xmenu_show, xdialog_show): Ditto.
10005 2000-01-13  Gerd Moellmann  <gerd@gnu.org>
10007         * sound.c (Fplay_sound): Improve doc string.
10009 2000-01-11  Richard M. Stallman  <rms@gnu.org>
10011         * lisp.h (set_internal): Enter the new arg.
10013         * eval.c (specbind): Record buffer-local variables specially,
10014         indicating which buffer's binding was saved.
10015         (unbind_to): Restore buffer-local variables specially
10016         in the proper buffer.
10018         * data.c (set_internal): New arg BUF.
10020         * eval.c (specbind, unbind_to): Pass new arg to set_internal.
10021         * data.c (Fset): Pass new arg to set_internal.
10022         * bytecode.c (Fbyte_code): Pass new arg to set_internal.
10024 2000-01-11  Gerd Moellmann  <gerd@gnu.org>
10026         * .gdbinit: Adapt to new strings.  Add xbacktrace, xreload,
10027         xprintsym.
10029 2000-01-11  Richard M. Stallman  <rms@gnu.org>
10031         * minibuf.c (Ftry_completion): Doc fix.
10033 2000-01-11  Gerd Moellmann  <gerd@gnu.org>
10035         * keyboard.c (Fclear_this_command_keys): Clear recent_keys
10036         vector, too.
10038 2000-01-11  Andreas Schwab  <schwab@suse.de>
10040         * coding.c (code_convert_region): Initialize total_skip.
10042 2000-01-08  Dave Love  <fx@gnu.org>
10044         * eval.c (Fuser_variable_p): Check customizability too.
10046 2000-01-07  Gerd Moellmann  <gerd@gnu.org>
10048         * minibuf.c (Fcompleting_read): Doc fix.
10050 2000-01-05  Gerd Moellmann  <gerd@gnu.org>
10052         * s/freebsd.h (C_SWITCH_SYSTEM): Add -I /usr/local/include and
10053         -L /usr/local/lib.
10055         * xfns.c (x_create_im): New function to set IM and IC of a frame.
10056         Check that input style is supported before trying to create an
10057         IC for it.
10058         (x_window): Call x_create_im.
10060 2000-01-04  Gerd Moellmann  <gerd@gnu.org>
10062         * xfns.c (current_gif_memory_src): New variable.
10063         (gif_load): Record the address of the current memory source
10064         in current_gif_memory_src.
10065         (gif_read_from_memory): Use current_gif_memory_src.
10067         * systime.h (EMACS_GET_TIME, EMACS_ADD_TIME, EMACS_SUB_TIME): Give
10068         macros statement form.
10070         * sound.c (struct sound): Renamed from struct sound_file.
10071         (struct sound): Add members `data' and `header_size'.
10072         (enum sound_attr): Add SOUND_DATA.
10073         (current_sound, current_sound_device): Variables renamed from
10074         sound_file and sound_device.
10075         (parse_sound): Parse :data.
10076         (parse_sound): Handle sound data in strings.
10077         (find_sound_type): Function renamed from find_sound_file_type.
10078         (wav_init, au_init): Fail if sound's header_size is smaller than
10079         needed header size.
10080         (wav_play, au_play): Play sounds from string data.
10082         * puresize.h (BASE_PURE_SIZE): Increase to 600000.
10084         * lisp.h: Add prototype for allocate_string_data.
10086         * alloc.c (Fgarbage_collect): Return number of live and free
10087         strings.
10089         * alloc.c (mark_buffer): Remove code in #if 0.
10090         (gc_sweep): Ditto.
10091         (UNMARK_BALANCE_INTERVALS): Give the macro statement form.
10092         (strings_consed): New variable.
10093         (allocate_string): Set it.
10094         (syms_of_alloc): Add DEFVAR_INT for strings_consed.
10095         (Fmemory_use_counts): Return strings_consed.  Use Flist.
10097         * alloc.c: General cleanup in comments etc.  Remove conditional
10098         compilation for `standalone'.
10100         * lisp.h (struct Lisp_String): Make DATA member `unsigned char *'.
10102         * alloc.c (MARK_STRING, UNMARK_STRING, STRING_MARKED_P):
10103         (GC_STRING_BYTES, GC_STRING_CHARS): New macros.
10104         (DONT_COPY_FLAG): Removed.
10105         (SBLOCK_SIZE, LARGE_STRING_BYTES): New macros.
10106         (struct sdata, struct sblock): New
10107         (struct string_block): Rewritten.
10108         (STRINGS_IN_STRING_BLOCK): New macro.
10109         (oldest_sblock, current_sblock, total_strings, total_free_strings)
10110         (large_sblocks, string_blocks, string_free_list): New variables.
10111         (NEXT_FREE_LISP_STRING, SDATA_OF_STRING, SDATA_SIZE): New macros.
10112         (init_strings): Rewritten.
10113         (allocate_string, allocate_string_data, compact_small_strings)
10114         (free_large_strings, sweep_strings): New functions.
10115         (STRING_BLOCK_SIZE, STRING_BLOCK_OUTSIZE)
10116         (struct string_block_head, current_string_block)
10117         (first_string_block, large_string_blocks, STRING_FULLSIZE)
10118         (STRING_PAD): Removed.
10119         (make_uninit_multibyte_string, make_pure_string): Rewritten.
10120         (Fgarbage_collect): Don't set mark bit in large strings.
10121         (mark_object): Mark strings differently.  Mark symbol names
10122         differently.
10123         (survives_gc_p): Test marked strings differently.
10124         (gc_sweep): Sweep strings differently, unmark strings in
10125         symbol names.
10126         (compact_strings): Removed.
10128 2000-01-04  Eli Zaretskii  <eliz@is.elta.co.il>
10130         * xfaces.c (syms_of_xfaces): defsubr Scolor_gray_p and
10131         Scolor_supported_p even if HAVE_X_WINDOWS is not defined.
10133 2000-01-04  Kenichi Handa  <handa@etl.go.jp>
10135         * fileio.c (Finsert_file_contents): Signal error if visiting file
10136         in a non-empty buffer.
10138         * term.c (encode_terminal_code): Fix the previous change.
10140 2000-01-03  Gerd Moellmann  <gerd@gnu.org>
10142         * xfaces.c (syms_of_xfaces): Change Sface_color_gray_p to
10143         Scolor_gray_p, Sface_color_supported_p to Scolor_supported_p.
10145         * s/hpux9.h (NO_EDITRES): Define even if HAVE_LIBXMU.
10147 2000-01-03  Eli Zaretskii  <eliz@is.elta.co.il>
10149         * xdisp.c (handle_single_display_prop) [HAVE_WINDOW_SYSTEM]: No
10150         need to test for MSDOS frames.
10152 2000-01-03  Eli Zaretskii  <eliz@is.elta.co.il>
10154         * dosfns.c (unspecified_colors): Remove.
10155         (msdos_stdcolor_idx): Use global variables unspecified_fg and
10156         unspecified_bg.
10157         (msdos_stdcolor_name): Return strings for unspecified fore- and
10158         back-ground colors.
10160         * xfaces.c (Qunspecified_fg, Qunspecified_bg): Remove.
10161         (syms_of_xfaces): Remove their staticpro's.
10162         (tty_color_name): Return Lisp strings for unspecified fore- and
10163         back-ground colors.
10164         (Finternal_set_lisp_face_attribute): Remove the special treatment
10165         for Qunspecified_{f,b}g.
10166         (realize_default_face): Replace Qunspecified_{f,b}g with a Lisp
10167         string.
10169 2000-01-03  Gerd Moellmann  <gerd@gnu.org>
10171         * xdisp.c (reseat_at_next_visible_line_start): Position before
10172         newline only if ending up on a newline.
10173         (next_element_from_ellipsis): Return success.  Handle case of
10174         displaying no ellipsis.  Fix case of ellipsis defined in display
10175         table.
10176         (next_element_from_buffer): Return 0 if next_element_from_ellipsis
10177         returns 0.
10179 2000-01-03  Eli Zaretskii  <eliz@is.elta.co.il>
10181         * xfaces.c (Fcolor_gray_p): Renamed from face-color-gray-p.
10182         (Fcolor_supported_p): Renamed from face-color-supported-p.
10184 2000-01-02  Eli Zaretskii  <eliz@is.elta.co.il>
10186         * xfaces.c (tty_defined_color): Pass frame to tty-color-desc.  The
10187         list of colors renamed to tty-defined-color-alist.
10188         (tty_color_name): Pass the frame to tty-color-by-index.
10189         (realize_tty_face): tty-color-alist is now a function which
10190         accepts the frame as argument.
10192         * term.c (Ftty_display_color_p): Accept an optional argument
10193         FRAME.
10195 2000-01-02  Eli Zaretskii  <eliz@is.elta.co.il>
10197         * term.c (insert_glyphs): Pass glyph, not &glyph, to
10198         encode_terminal_code.
10200 2000-01-02  Eli Zaretskii  <eliz@is.elta.co.il>
10202         * dispnew.c (mode_line_string): Support termcap frames as well.
10204 2000-01-01  Gerd Moellmann  <gerd@gnu.org>
10206         * syntax.c (Fforward_word): Undo previous change.
10208         * editfns.c (Fconstrain_to_field): Don't constrain if
10209         inhibit-field-text-motion is non-nil.
10210         (Fline_beginning_position): Undo previous change.
10211         (Fline_end_position): Ditto.
10213         * syntax.c (Fforward_word): Notice field boundaries only if
10214         inhibit-field-text-motion is nil.
10216         * lisp.h: Add extern declaration for Vinhibit_field_text_motion.
10218         * editfns.c (Vinhibit_field_text_motion): New variable.
10219         (inhibit-field-text-motion): New DEFVAR_LISP.
10220         (Fline_beginning_position, Fline_end_position): Notice field
10221         boundaries only if inhibit-field-text-motion is nil.
10223         * xfns.c (x_create_x_image_and_pixmap): Remove parameter FILE.
10224         All calls adjusted.
10225         (x_build_heuristic_mask): Likewise.
10226         (xbm_load_image_from_file): Change error output.
10227         (xbm_load, xpm_load, pbm_load, png_load, jpeg_load, tiff_load)
10228         (gif_load, gs_load, x_kill_gs_process): Ditto.
10230         * xfns.c (gif_load): Avoid sign extension and thus out of bounds
10231         color indices when accessing raster pixels.
10232         (gif_image_p, png_image_p, jpeg_image_p, tiff_image_p): Allow only
10233         one of :file or :data.
10234         (enum pbm_keyword_index): Add PBM_DATA.
10235         (pbm_format): Add :data.
10236         (pbm_image_p): Allow either :file or :data.
10237         (pbm_read_file): New function.
10238         (pbm_scan_number): Rewritten to read from string.
10239         (pbm_load): Support :data.
10241 See ChangeLog.8 for earlier changes.
10243 ;; Local Variables:
10244 ;; coding: iso-2022-7bit
10245 ;; End: