]> code.delx.au - gnu-emacs/blob - src/ChangeLog.22
*** empty log message ***
[gnu-emacs] / src / ChangeLog.22
1 2004-03-04 Kenichi Handa <handa@m17n.org>
2
3 * xterm.c (x_list_fonts): Fix the detection of an auto-scaled font.
4
5 * coding.c (decode_coding_utf_16): Fix handling of surrogate pair.
6
7 * editfns.c (Ftranslate_region_internal): Renamed from
8 Ftranslate_region. Accept a char-table in TABLE.
9 (syms_of_editfns): Defsubr Stranslate_region_internal.
10
11 * xfaces.c (set_lface_from_font_name): If a font is specified for
12 a frame, generate a fontset from the font.
13 (build_scalable_font_name): If the scalable font is requested for
14 a specific size, don't change that size.
15 (try_font_list): Try a scalable font also in the case that a
16 pattern string is specified,
17
18
19 2004-03-03 Kenichi Handa <handa@m17n.org>
20
21 * xfaces.c (Fface_font): New optional arg CHARACTER.
22
23 2004-02-17 Kenichi Handa <handa@m17n.org>
24
25 * charset.h (CHARSET_OFFSET): New macro.
26
27 2004-02-13 Kenichi Handa <handa@m17n.org>
28
29 * xterm.c (x_get_font_repertory): Fix for non-Unicode-bmp charset.
30
31 * fontset.c (fontset_face): Handle the case that repertory is a
32 char-table.
33 (find_font_encoding): Return nil for unknown encoding.
34 (Fset_fontset_font): Ignore a font of unknown encoding.
35
36 2004-02-09 Kenichi Handa <handa@m17n.org>
37
38 * keymap.c (describe_vector): Handle default value of a char
39 table.
40
41 * fontset.c (fontset_face): Handle fallback fonts correctly.
42 (Ffontset_info): Return infomation about fallback fonts.
43
44 2004-02-06 Kenichi Handa <handa@m17n.org>
45
46 * fontset.c (FONTSET_DEFAULT): New macro.
47 (FONTSET_ADD): Handle the case that range is nil.
48 (fontset_add): Likewise.
49 (Fset_fontset_font): Change the 2nd arg name to TARGET, and handle
50 the case that it is nil.
51 (dump_fontset): Call FONTSET_DEFAULT, not FONTSET_FALLBACK.
52 (syms_of_fontset): Set char-table-extra-slots property of fontset
53 to 9.
54
55 * charset.h (CHAR_CHARSET_P): Fix for the case that the method is
56 subset or superset.
57
58 2004-01-30 Kenichi Handa <handa@m17n.org>
59
60 * emacs.c (main): Call init_charset after syms_of_XXX.
61
62 * charset.c (Vcharset_map_directory): Deleted.
63 (Vcharset_map_path): New variable
64 (load_charset_map_from_file): Use Vcharset_map_path instead.
65 (init_charset): Initialize Vcharset_map_path.
66 (syms_of_charset): Delete declaration of "charset-map-directory",
67 add declaration of "charset-map-path".
68
69 2004-01-29 Kenichi Handa <handa@m17n.org>
70
71 * fns.c (string_char_to_byte): Optimize for ASCII only string.
72 (string_byte_to_char): Likewise.
73
74 * fileio.c (Finsert_file_contents): Avoid detecting a code twice.
75
76 * coding.c (detect_coding_iso_2022): Fix handling of SS2 and SS3.
77 (detect_coding): Treat '\0' as normal ASCII byte..
78 (detect_coding_system): Likewise.
79
80 2004-01-27 Kenichi Handa <handa@m17n.org>
81
82 * coding.h (SJIS_TO_JIS2, JIS_TO_SJIS2): New macros.
83
84 * coding.c (QCmnemonic, QCdefalut_char)
85 (QCdecode_translation_table, QCencode_translation_table)
86 (QCpost_read_conversion, QCpre_write_conversion): New variables.
87 (get_translation_table): Return a list of translation tables if
88 necessary.
89 (decode_coding): Call get_translation_table with ENCODEP 0.
90 (char_encodable_p): If translation_table is non-nil, always call
91 translate_char.
92 (Fdefine_coding_system_internal): Accept list of translation
93 tables as :encode-translation-table and :decode-translation-table.
94 (Fcoding_system_put): New function.
95 (syms_of_coding): Declare new symbols. Defsubr
96 Scoding_system_put.
97 (decode_coding_sjis): Handle 4th charset (typically JISX0212).
98 (encode_coding_sjis): Likewise.
99
100 * charset.c (map_charset_chars): Fix arg to map_charset_chars in
101 when the charset is superset type.
102
103 * character.c (translate_char): Accept list of translation tables.
104
105 2004-01-25 Kenichi Handa <handa@m17n.org>
106
107 * coding.h (enum coding_attr_index): New member
108 coding_attr_trans_tbl.
109 (CODING_ATTR_TRANS_TBL): New macro.
110
111 * coding.c (get_translation_table): New function.
112 (translate_chars): Fix the bug of skipping annotation data.
113 (decode_coding): Utilze get_translation_table.
114 (encode_coding): Likewise.
115 (char_encodable_p): Translate char if necessary.
116 (Funencodable_char_position): Likewise.
117 (Ffind_coding_systems_region_internal): Setup translation table
118 for encode in a coding system attribute vector in advance.
119 (Fcheck_coding_systems_region): Likewise.
120 (Fdefine_coding_system_internal): Allow a symbol as translation
121 table. For shift-jis type coding system, allow 4th charset.
122
123 2004-01-24 Kenichi Handa <handa@m17n.org>
124
125 * coding.c (decode_coding_sjis): Check the first byte rigidly.
126
127 * xdisp.c (get_next_display_element): Pass -1 as POS to
128 FACE_FOR_CHAR if displaying a C-string.
129
130 2004-01-23 Kenichi Handa <handa@m17n.org>
131
132 * composite.c (get_composition_id): Handle xoff and yoff in a
133 composition rule.
134
135 * composite.h (COMPOSITION_DECODE_RULE): New arg xoff and yoff.
136 (struct composition): New member lbearing and rbearing.
137
138 * xdisp.c (move_it_to): Optimize for the case (op & MOVE_TO_Y).
139 (x_get_glyph_overhangs): Handle a composition glyph.
140 (x_produce_glyphs): Setup lbearing and rbreaing for a composition
141 glyph.
142
143 * xterm.c (x_compute_glyph_string_overhangs): Handle also a
144 composition glyph.
145
146 2004-01-18 Kenichi Handa <handa@m17n.org>
147
148 * print.c: Include charset.h.
149 (Vprint_charset_text_property): New variable.
150 (Qdefault): Extern it.
151 (PRINT_STRING_NON_CHARSET_FOUND)
152 (PRINT_STRING_UNSAFE_CHARSET_FOUND): New macros.
153 (print_check_string_result): New variable.
154 (print_check_string_charset_prop): New function.
155 (print_prune_charset_plist): New variable.
156 (print_prune_string_charset): New function.
157 (print_object): Call print_prune_string_charset if
158 Vprint_charset_text_property is not t.
159 (print_interval): Print nothing if itnerval->plist is nil.
160 (syms_of_print): Declare Vprint_charset_text_property as a lisp
161 variable. Init and staticpro print_prune_charset_plist.
162
163 2004-01-15 Kenichi Handa <handa@m17n.org>
164
165 * fontset.c (new_fontset_from_font_name): Use the specified font
166 for all characters in the new fontset.
167
168 * macterm.c (x_set_mouse_face_gc): Call FACE_FOR_CHAR with POS and
169 OBJECT args.
170
171 * xdisp.c (x_produce_glyphs): Call FACE_FOR_CHAR with POS and
172 OBJECT args for composition too.
173
174 * w32term.c (x_set_mouse_face_gc): Call FACE_FOR_CHAR with POS and
175 OBJECT args.
176
177 2004-01-13 Kenichi Handa <handa@m17n.org>
178
179 * dispextern.h (FACE_FOR_CHAR): New args POS and OBJECT.
180
181 * fontset.c (reorder_font_vector): Adjusted for the change of
182 FONT_DEF format.
183 (fontset_face): New arg id. Caller changed.
184 (face_for_char): New args pos and object.
185 (make_fontset_for_ascii_face): Adjusted for the change of FONT_DEF
186 format.n
187 (fs_query_fontset): Check NAME by Fassoc too.
188 (Fset_fontset_font): Allow non-XLFD font name.
189 (Ffontset_info): Adjusted for the change of FONT_DEF format.
190
191 * fontset.h (face_for_char): Prototype adjusted.
192
193 * xdisp.c (face_before_or_after_it_pos): Call FACE_FOR_CHAR with
194 POS and OBJECT args.
195 (get_next_display_element): Likewise.
196 (append_space): Likewise.
197 (extend_face_to_end_of_line): Likewise.
198 (get_char_face_and_encoding): Likewise.
199 (BUILD_COMPOSITE_GLYPH_STRING): Likewise.
200 (x_produce_glyphs): Likewise.
201
202 * xfaces.c (compute_char_face): Call FACE_FOR_CHAR with
203 POS and OBJECT args.
204
205 * xterm.c (x_set_mouse_face_gc): Call FACE_FOR_CHAR with
206 POS and OBJECT args.
207
208 2004-01-03 Jason Rumney <jasonr@gnu.org>
209
210 * w32select.c (Fw32_set_clipboard_data): Avoid potential realloc
211 of GlobalAlloc'ed memory.
212
213 2003-12-29 Kenichi Handa <handa@m17n.org>
214
215 * ccl.c (Fccl_execute_on_string): Fix the condition of loop.
216
217 * charset.h (charset_table_used): Delete extern.
218
219 * charset.c (charset_table_used): Make it static.
220 (map_charset_chars): Fix args to c_function with.
221
222 * chartab.c (map_sub_char_table_for_charset): Fix args to
223 c_function with.
224
225 * coding.h (enum coding_result_code): Delete
226 CODING_RESULT_INSUFFICIENT_CMP, add CODING_RESULT_INVALID_SRC.
227
228 * coding.c (Qinsufficient_source, Qinconsistent_eol)
229 (Qinvalid_source, Qinterrupted, Qinsufficient_memory): New
230 variables.
231 (Vlast_code_conversion_error): New variables.
232 (syms_of_coding): DEFSYM or DEFVAR_LISP them.
233 (ONE_MORE_BYTE): Record error if any instead of signaling an
234 error. If non-ASCII multibyte char is found, return the negative
235 value of the code. All callers changed to check it.
236 (ONE_MORE_BYTE_NO_CHECK): Likewise.
237 (record_conversion_result): New function. All codes setting
238 coding->result are changed to call this function.
239 (detect_coding_utf_8): Don't use the local variable incomplete.
240 (decode_coding_utf_8): Likewise.
241 (emacs_mule_char): Change the second arg to `const'.
242 (detect_coding_emacs_mule): Don't use the local variable
243 incomplete.
244 (detect_coding_sjis): Likewise.
245 (detect_coding_big5): Likewise.
246 (decode_coding): Fix of flushing out unprocessed data.
247 (make_conversion_work_buffer): Fix making of a work buffer.
248 (decode_coding_object): Return coding->dst_object;
249
250 * fontset.c (set_fontset_font): Fix args.
251
252 * lisp.h (CHARACTERBITS): Define as 22.
253
254 * process.c (send_process): Be sure to set coding->src_multibyte.
255
256 * xdisp.c (handle_auto_composed_prop): Fix setting of limit.
257
258 2003-12-02 Kenichi Handa <handa@m17n.org>
259
260 * xdisp.c (handle_auto_composed_prop): Give limit to
261 Fnext_single_char_property_change.
262
263 2003-12-02 Kenichi Handa <handa@m17n.org>
264
265 * coding.c (detect_coding): Fix previous change.
266 (detect_coding_system): Likewise.
267
268 2003-12-02 Kenichi Handa <handa@m17n.org>
269
270 * composite.c (syms_of_composite): Don't make the compostion hash
271 table week.
272
273 * fontset.c (Fset_fontset_font): Fix docstring.
274
275 * lisp.h (detect_coding_system): Adjust prototype.
276
277 * fileio.c (kill_workbuf_unwind): Delete this function.
278 (Finsert_file_contents): Adjust the call of detect_coding_system.
279 Get conversion_buffer by code_conversion_save. Use the macor
280 CODING_MAY_REQUIRE_DECODING. After decoding, update
281 coding_system.
282
283 * coding.h (make_conversion_work_buffer): Delete extern.
284 (code_conversion_save): Extern it.
285
286 * coding.c (enum iso_code_class_type): Delete ISO_carriage_return.
287 (CODING_GET_INFO): Delete argument eol_type. Callers changed.
288 (decode_coding_utf_8): Don't do eol converion.
289 (detect_coding_utf_16): Check coding->src_chars, not
290 coding->src_bytes. Add heuristics for those that have no
291 signature.
292 (decode_coding_emacs_mule): Don't do eol converion.
293 (decode_coding_iso_2022): Likewise.
294 (decode_coding_sjis): Likewise.
295 (decode_coding_big5): Likewise.
296 (decode_coding_charset): Likewise.
297 (adjust_coding_eol_type): Return a new coding system.
298 (detect_coding): Don't detect eol. Fix for utf-16 detection.
299 (decode_eol): In case of CRLF->LF conversion, use del_range_2 on
300 each change.
301 (decode_coding): Pay attention to undo_list. Do eol convesion for
302 all types of coding-systems (if necessary).
303 (Vcode_conversion_work_buf_list): Delete it.
304 (Vcode_conversion_reused_workbuf): Renamed from
305 Vcode_conversion_reused_work_buf.
306 (Vcode_conversion_workbuf_name): New variable.
307 (reused_workbuf_in_use): New variable.
308 (make_conversion_work_buffer): Delete the arg DEPTH.
309 (code_conversion_restore): Argument changed to cons.
310 (code_conversion_save): Delete the argument BUFFER. Callers
311 changed.
312 (detect_coding_system): New argument src_chars. Callers changed.
313 Fix for utf-16 detection.
314 (init_coding_once): Don't use ISO_carriage_return.
315 (syms_of_coding): Initialized Vcode_conversion_workbuf_name and
316 reused_workbuf_in_use.
317
318 2003-11-24 Kenichi Handa <handa@m17n.org>
319
320 * keymap.c (store_in_keymap): Pay attention to the case that idx
321 is a cons specifying a character range.
322
323 * coding.c (Fdefine_coding_system_internal): Fix previous change.
324
325 2003-11-23 Kenichi Handa <handa@m17n.org>
326
327 * xdisp.c (handle_auto_composed_prop): Fix the case of returning
328 HANDLED_RECOMPUTE_PROPS.
329
330 * coding.c (Fdefine_coding_system_internal): Fix checking of
331 ascii compatibility.
332
333 2003-11-22 Kenichi Handa <handa@m17n.org>
334
335 * charset.c (find_charsets_in_text): Delete unused locale
336 variable.
337 (Fset_charset_priority): Update Vemacs_mule_charset_list too.
338
339 * coding.c (encode_coding_emacs_mule): Emit bytes with MSB.
340 Resync charset_list to Vemacs_mule_charset_list.
341
342 * keymap.c (store_in_keymap): Pay attention to the case that idx
343 is a cons specifying a character range.
344
345 2003-11-18 Kenichi Handa <handa@m17n.org>
346
347 * composite.c (update_compositions): Bind inhibit-read-only, etc
348 to t before calling remove-list-of-text-properties.
349
350 * print.c (print_object): Always print ASCII chars as is.
351
352 2003-11-17 Kenichi Handa <handa@m17n.org>
353
354 * keymap.c (Fdefine_key): Fix handling of Lucid style event type
355 list.
356
357 * fns.c (Fmapconcat): Signal an error if SEQUENCE is a char table.
358 (Fmapcar): Likewise.
359 (Fmapc): Likewise.
360
361 2003-11-15 Kenichi Handa <handa@m17n.org>
362
363 * syntax.c (skip_chars): Be sure to alloca char_ranges when
364 necessary.
365
366 2003-11-14 Kenichi Handa <handa@m17n.org>
367
368 * xfaces.c (set_lface_from_font_name): Fix for the case that
369 FONTNAME is not fontset name.
370
371 2003-11-13 Kenichi Handa <handa@m17n.org>
372
373 * fns.c (base64_encode_1): Fix previous change.
374
375 2003-11-08 Kenichi Handa <handa@m17n.org>
376
377 * fontset.c (set_fontset_font): New function.
378 (Fset_fontset_font): If a font is specified for a charset, use
379 map_charset_chars to store the font spec in a fontset.
380
381 2003-10-29 Kenichi Handa <handa@m17n.org>
382
383 * fontset.c (fontset_face): Create a fallback fontset on demand
384 (make_fontset): Don't create a fallback fontset here.
385 (free_face_fontset): Free a fallback fontset (if any) too.
386 (n_auto_fontsets): Delete this variable.
387 (auto_fontset_alist): New variable.
388 (new_fontset_from_font_name): Check auto_fontset_alist.
389 (dump_fontset) [FONTSET_DEBUG]: Fully re-written.
390 (Ffontset_list_all) [FONTSET_DEBUG]: New function.
391 (syms_of_fontset): Initialize and staticpro auto_fontset_alist.
392 Defsubr Sfontset_list_all.
393
394 2003-10-24 Kenichi Handa <handa@m17n.org>
395
396 * xterm.c (x_list_fonts): Fix excluding of auto-scaled fonts.
397
398 2003-10-23 Kenichi Handa <handa@m17n.org>
399
400 * fontset.c (Fnew_fontset): Check NAME more rigidly.
401
402 2003-10-17 Kenichi Handa <handa@m17n.org>
403
404 * editfns.c (Fgoto_char): Fix docstring.
405
406 2003-10-16 Kenichi Handa <handa@m17n.org>
407
408 * insdel.c (insert_from_gap): Adjust intervals correctly.
409
410 2003-10-12 Jason Rumney <jasonr@gnu.org>
411
412 * w32term.c (GLYPHSET, WCRANGE): Define if system headers don't.
413 (pfnGetFontUnicodeRanges): New dynamically loaded function.
414 (w32_initialize): Try to load it.
415 (x_get_font_repertory): Use it if available.
416 (w32_encode_char): Add shortcut for unicode output.
417
418 * w32fns.c (w32_load_system_font): Default charset to -1.
419 (x_to_w32_charset): Match all fonts for unicode.
420 (w32_to_x_charset): New parameter matching. Don't return partial
421 or wildcard charsets.
422 (w32_to_all_x_charsets): Don't return partial or wildcard charsets.
423 (w32_codepage_for_font): Return CP_UNICODE for unicode.
424 (w32_to_x_font): Match charset to real charset.
425 (enum_font_cb2): Always list unicode versions.
426
427 * makefile.w32-in (temacs): Increase EMHEAP.
428
429 2003-10-11 Jason Rumney <jasonr@gnu.org>
430
431 * w32term.c (w32_encode_char): New charset parameter.
432 font_info.encoding becomes encoding_type.
433 (x_get_font_repertory): New function. Warning: stub only!
434 (x_new_font): Return quickly if font already set.
435 (x_new_fontset): fontsetname parameter is Lisp_Object.
436 Use new fs_query_fontset. Try new_fontset_from_font_name. Use
437 fontset_name for return value.
438
439 * w32term.h: Declare x_get_font_repertory.
440
441 * w32select.c (Fw32_set_clipboard_data): Use string_x_string_p in
442 place of find_charset_in_text. Use encode_coding_object in place
443 of encode_coding.
444 (Fw32_get_clipboard_data): Use decode_coding_c_string in place of
445 decode_coding.
446
447 * w32fns.c (Fx_create_frame, x_create_tip_frame): Use new version
448 of x_new_fontset.
449 (w32_load_system_font): Initialize charset as unicode.
450 font_info.encoding becomes encoding_type.
451 (w32_to_x_font): Use decode_coding_c_string in place of
452 decode_coding.
453 (x_to_w32_font): Use encode_coding_object in place of
454 encode_coding.
455 (syms_of_w32fns): Set get_font_repertory_func.
456
457 * w32console.c: Include character.h. Use terminal_encode_buffer
458 from term.c.
459 (write_glyphs): Use new version of encode_terminal_code. Use
460 encode_coding_object in place of encode_coding.
461
462 * w32bdf.c (w32_load_bdf_font): Clear font_info before filling.
463 encoding becomes encoding_type.
464
465 * term.c (terminal_encode_buffer): Make externally visible.
466
467 * makefile.w32-in: Add character.h dependancies.
468 (character.o, chartab.o): New targets.
469
470 2003-10-10 Kenichi Handa <handa@m17n.org>
471
472 * fileio.c (Finsert_file_contents) [DOS_NT]: Use the macro
473 CODING_ID_EOL_TYPE..
474
475 2003-10-07 Andreas Schwab <schwab@suse.de>
476
477 * coding.c (produce_chars): Revert last change.
478
479 2003-10-06 Kenichi Handa <handa@m17n.org>
480
481 * charset.h (charset_unicode): Extern it.
482
483 * charset.c (string_xstring_p): Check by (C >= 0x100).
484 (find_charsets_in_text): Format of the arc CHARSETS changed. New
485 arg MULTIBYTE.
486 (Ffind_charset_region, Ffind_charset_string): Adjusted for the
487 change of find_charsets_in_text.
488 (Fsplit_char): Fix doc. Never return unknown.
489
490 * chartab.c (char_table_translate): Use CHARACTERP, not INETEGERP.
491
492 * coding.c (Fdefine_coding_system_alias): Update
493 Vcoding_system_list.
494
495 * fontset.c (load_font_get_repertory): Pay attention to the case
496 that ENCODING of a font is specified by a char-table.
497
498 * xterm.c (x_get_font_repertory): Handle the case that the
499 encoding of font is other than Unicode.
500
501 2003-10-02 Kenichi Handa <handa@m17n.org>
502
503 * term.c (encode_terminal_code): Don't handle glyph-table. Check
504 if a character is encodable by the terminal coding system. If
505 not, produces proper number of `?'s. Update
506 terminal_encode_buffer and terminal_encode_buf_size if necessary.
507 (produce_glyphs): Check by CHAR_BYTE8_P, not SINGLE_BYTE_CHAR_P.
508
509 2003-10-01 Kenichi Handa <handa@m17n.org>
510
511 * term.c (terminal_encode_buffer, terminal_encode_buf_size): New
512 variables.
513 (encode_terminal_code): Argument changed. Encode multiple
514 characters at once. Store the result of encoding in
515 terminal_encode_buffer.
516 (write_glyphs): Adjusted for the change of encode_terminal_code.
517 (insert_glyphs): Likewise.
518 (term_init): Initialize terminal_encode_buffer and
519 terminal_encode_buf_size.
520
521 * coding.c (consume_chars): If coding->src_object is nil, don't
522 check annotation.
523
524 2003-09-30 Kenichi Handa <handa@m17n.org>
525
526 * character.c (char_string): Use ASCII_CHAR_P instead of
527 SINGLE_BYTE_CHAR_P.
528
529 2003-09-30 Kenichi Handa <handa@m17n.org>
530
531 * xdisp.c (handle_auto_composed_prop): Check if the last
532 characters of auto-composed region is newly composed with the
533 following characters.
534 (handle_composition_prop): Fix checking of point being inside
535 composition.
536
537 2003-09-26 Kenichi Handa <handa@m17n.org>
538
539 * fns.c (concat): Don't change multibyteness of the result by
540 concatenating an 8-bit character.
541
542 * data.c (Faset): Check newelt by CHECK_CHARACTER. Don't change
543 multibyteness of the result when newelt is an 8-bit character.
544
545 2003-09-29 Dave Love <fx@gnu.org>
546
547 * xmenu.c (find_and_call_menu_selection): Make menu_bar_items_used
548 EMACS_INT.
549
550 * xfns.c (DefaultDepthOfScreen, x_encode_text): Remove unused vars.
551
552 * xfaces.c (face_numeric_value): Declare dim size_t.
553 (Finternal_lisp_face_equal_p): Remove unused f.
554
555 * xdisp.c (BUILD_CHAR_GLYPH_STRINGS, display_and_set_cursor)
556 (MATRIX_ROW): Remove unused vars.
557 (draw_glyphs, x_insert_glyphs, fast_find_position)
558 (fast_find_position, fast_find_string_pos): Use EMACS_INT for
559 byte/char counts.
560
561 * regex.c (regex_compile): Remove unused var.
562
563 * minibuf.c (Fminibuffer_complete_word): Remove unused var.
564
565 * keymap.c (Fset_keymap_parent, map_keymap, Fcopy_keymap)
566 (Faccessible_keymaps, where_is_internal): Remove unused vars.
567
568 * keyboard.c (cancel_hourglass_unwind): Return Qnil.
569
570 * frame.c (frame_name_fnn_p): Make len EMACS_INT.
571
572 * fileio.c (Fwrite_region): Remove unused var.
573
574 * dispnew.c (adjust_frame_glyphs_for_frame_redisplay)
575 (adjust_frame_glyphs_for_window_redisplay): Remove unused ch_dim.
576
577 * composite.c (Fremove_list_of_text_properties): Declare.
578
579 * coding.c (inhibit_pre_post_conversion): Removed (unused).
580 (alloc_destination, produce_chars): Use EMACS_INT for byte/char
581 counts.
582 (coding_inherit_eol_type): Remove unused attrs.
583 (detect_coding): Cast arg of detect_eol.
584
585 * charset.c (syms_of_charset): Remove unused var p.
586 (find_charsets_in_text, Ffind_charset_region): Use EMACS_INT for
587 byte/char counts.
588
589 * casetab.c (set_case_table): Remove unused var.
590
591 * window.c (Fdisplay_buffer, Fframe_selected_window): Remove
592 unsued vars.
593
594 >>>>>>> 1.1.2.8
595 2003-09-26 Dave Love <fx@gnu.org>
596
597 * xterm.c (x_bitmap_mask): Declare.
598
599 2003-09-17 Dave Love <fx@gnu.org>
600
601 * xterm.c (x_term_init): Fix type error.
602
603 * lisp.h: Add Funibyte_char_to_multibyte.
604
605 * coding.c (Fread_coding_system): Fix arg of XSETSTRING.
606 (Fset_coding_system_priority): Doc fix.
607
608 * alloc.c: Sync with HEAD version.
609
610 * ccl.c (ccl_driver): Fix arg of CHARACTERP.
611
612 * indent.c (check_composition): Make start and end EMACS_INT.
613
614 * character.c (lisp_string_width): Make ignore and end EMACS_INT.
615
616 * xdisp.c (handle_composition_prop, check_point_in_composition):
617 Make buffer positions EMACS_INT.
618
619 * composite.c (find_composition, run_composition_function)
620 (update_compositions, Ffind_composition_internal): Make buffer
621 positions EMACS_INT.
622
623 * composite.h (find_composition, update_compositions): Make
624 position args EMACS_INT.
625
626 * keyboard.c (adjust_point_for_property): Make beg and end
627 EMACS_INT.
628
629 * intervals.c (get_property_and_range)
630 * intervals.h (get_property_and_range): Make start and end EMACS_INT.
631
632 * unexalpha.c: Don't include varargs.h.
633
634 2003-09-16 Dave Love <fx@gnu.org>
635
636 * coding.h (ENCODE_UTF_8): New.
637
638 * Makefile.in (gtkutil.o): Depend on coding.h.
639
640 * coding.c (Fset_coding_system_priority): Doc fix.
641
642 2003-09-16 Kenichi Handa <handa@m17n.org>
643
644 * fileio.c (Finsert_file_contents): Call setup_coding_system in
645 the case of auto saving.
646
647 2003-09-10 Andreas Schwab <schwab@suse.de>
648
649 * chartab.c (map_char_table): Protect `range' from GC.
650 (map_char_table_for_charset): Likewise.
651
652 2003-07-09 Kenichi Handa <handa@m17n.org>
653
654 * coding.c (decode_coding_sjis): Check bytes more rigidly.
655
656 2003-06-26 Kenichi Handa <handa@m17n.org>
657
658 * fileio.c (choose_write_coding_system): Return a decided coding
659 system.
660 (Fwrite_region): Set Vlast_coding_system_used to the return value
661 of choose_write_coding_system.
662
663 2003-06-06 Kenichi Handa <handa@m17n.org>
664
665 * charset.c (Fset_charset_priority): Pay attention to duplicated
666 arguments.
667
668 * coding.c (QCcategory): New variable.
669 (syms_of_coding): Defsym it. Set all elements of
670 Vcoding_category_table and their symbol values.
671 (Fset_coding_system_priority): Doc fix. Update symbol qvalues of
672 coding-category-XXX, and coding-category-list.
673 (Fdefine_coding_system_internal): Add category in the plist.
674
675 2003-06-05 Kenichi Handa <handa@m17n.org>
676
677 * callproc.c (Fcall_process): Handle carryover correctly.
678
679 * coding.c (decode_coding_iso_2022): Fix handling of invalid
680 bytes.
681 (raw_text_coding_system): Check NILP (coding_system).
682 (coding_inherit_eol_type): Check NILP (coding_system) and
683 NILP (parent).
684 (consume_chars): Fix for the case of raw-text.
685
686 * process.c (read_process_output): Handle carryover correctly.
687
688 2003-06-02 Dave Love <fx@gnu.org>
689
690 * regex.c (re_search_2): Fix last change.
691
692 2003-05-30 Kenichi Handa <handa@m17n.org>
693
694 * regex.c (GET_CHAR_BEFORE_2): Check multibyte, not
695 target_multibyte. Even in a unibyte case, return a converted
696 multibyte char.
697 (GET_CHAR_AFTER): New macro.
698 (PATFETCH): Translate via multibyte char.
699 (HANDLE_UNIBYTE_RANGE): Delete this macro.
700 (SETUP_MULTIBYTE_RANGE): New macro.
701 (regex_compile): Setup compiled code so that its multibyteness
702 matches that of a target. Fix the handling of "[X-YZ]" using
703 SETUP_MULTIBYTE_RANGE.
704 (analyse_first) <charset>: For filling fastmap for all multibyte
705 characters, don't check by BASE_LEADING_CODE_P.
706 (re_search_2): Don't check RE_TARGET_MULTIBYTE_P (bufp). It is
707 the same as RE_MULTIBYTE_P (bufp) now.
708 (mutually_exclusive_p): Check by (! multibyte ||
709 IS_REAL_ASCII (c)).
710 (TARGET_CHAR_AND_LENGTH): Delete this macro.
711 (TRANSLATE_VIA_MULTIBYTE): New macro.
712 (re_match_2_internal): Don't check RE_TARGET_MULTIBYTE_P (bufp).
713 It is the same as RE_MULTIBYTE_P (bufp) now.
714 <exactn>: Translate via multibyte.
715 <anychar>: Fetch a character by RE_STRING_CHAR_AND_LENGTH. Don't
716 translate it.
717 <charset, charset_not>: Fetch a character by
718 RE_STRING_CHAR_AND_LENGTH. Translate via multibyte.
719 <duplicate>: Call bcmp_translate with the last arg `multibyte'.
720 <wordbound, notwordbound, wordbeg, wordend, syntaxspec,
721 notsyntaxspec, categoryspec, notcategoryspec> Fetch a character
722 by GET_CHAR_AFTER.
723 (bcmp_translate): Likewise.
724
725 * search.c (compile_pattern): Check the member target_multibyte,
726 not the member multibyte of buf.
727
728 * lread.c (read1): While reading a string, set force_singlebyte
729 and force_multibyte correctly.
730
731 * charset.c (Fset_unibyte_charset): Fix setting up of
732 unibyte_to_multibyte_table.
733 (init_charset_once): Likewise.
734
735 2003-05-29 Kenichi Handa <handa@m17n.org>
736
737 * coding.c (setup_coding_system): If coding has
738 post-read-conversion or pre-write-conversion, set
739 CODING_REQUIRE_DECODING_MASK and CODING_REQUIRE_ENCODING_MASK
740 respectively.
741 (decode_coding_gap): Run post-read-conversion if any.
742
743 * fileio.c (Finsert_file_contents): Even if we read into a
744 unibyte buffer, check if we must decode the result or not.
745
746 2003-05-29 Kenichi Handa <handa@m17n.org>
747
748 * coding.c (make_conversion_work_buffer): Change the work buffer
749 name to the same one as that of Emacs 21.
750
751 2003-05-28 Kenichi Handa <handa@m17n.org>
752
753 * coding.h (make_conversion_work_buffer): Prototype adjusted.
754 (code_conversion_restore): Don't extern it.
755
756 * coding.c (detected_mask): Delete unused variable.
757 (decode_coding_iso_2022): Pay attention to the byte sequence of
758 CTEXT extended segment, and retain those bytes as is.
759 (decode_coding_ccl): Delete unused variable `valids'.
760 (setup_coding_system): Delete unused variable `category'.
761 (consume_chars): Delete unused variable `category'. Make it work
762 for non-multibyte case.
763 (make_conversion_work_buffer): Argument changed.
764 (saved_coding): Delete unused variable.
765 (code_conversion_restore): Don't check saved_coding->destination.
766 (code_conversion_save): New function.
767 (decode_coding_gap, encode_coding_gap): Call code_conversion_save
768 instead of record_unwind_protect.
769 (decode_coding_object, encode_coding_object): Likewise. Recover
770 PT.
771 (detect_coding_system): Delete unused variable `mask'.
772 (Fdefine_coding_system_internal): Delete unsed vaiable id;
773
774 * fileio.c (kill_workbuf_unwind): New function.
775 (Finsert_file_contents): On replacing, call
776 make_conversion_work_buffer with correct args, and call
777 record_unwind_protect with the first arg kill_workbuf_unwind.
778
779 * lisp.h (Fgenerate_new_buffer_name): EXFUN it.
780
781 2003-05-20 Kenichi Handa <handa@m17n.org>
782
783 * fontset.c (BASE_FONTSET_P): Check FONTSET_BASE, not
784 FONTSET_NAME.
785 (fontset_add): Fix for the case that TO is less than TO1.
786 (Ffontset_info): Don't use fallback fontset on checking the
787 default fontset.
788 (dump_fontset): New function for debugging.
789
790 * coding.c (Fdefine_coding_system_internal): Fix for the case that
791 coding_type is Qcharset.
792
793 2003-05-07 Kenichi Handa <handa@m17n.org>
794
795 * chartab.c (map_sub_char_table): New argument DEFAULT_VAL.
796 (map_char_table): Don't inherit the value from the parent on
797 initializing VAL. Adjusted for the above change.
798
799 2003-05-06 Kenichi Handa <handa@m17n.org>
800
801 * coding.c (Qsignature, Qendian): Delete these variables.
802 (syms_of_coding): Don't initialize them.
803 (CATEGORY_MASK_UTF_16_AUTO): New macro.
804 (detect_coding_utf_16): Add CATEGORY_MASK_UTF_16_AUTO in
805 detect_info->found.
806 (decode_coding_utf_16): Don't detect BOM here.
807 (encode_coding_utf_16): Produce BOM if CODING_UTF_16_BOM (coding)
808 is NOT utf_16_without_bom.
809 (setup_coding_system): For a coding system of type utf-16, check
810 if the attribute :endian is Qbig or not (not nil or not), and set
811 CODING_REQUIRE_DETECTION_MASK if BOM detection is required.
812 (detect_coding): If coding type is utf-16 and BOM detection is
813 required, detect it.
814 (Fdefine_coding_system_internal): For a coding system of type
815 utf-16, check if the attribute :endian is Qbig or not (not nil or
816 not).
817
818 2003-05-06 Kenichi Handa <handa@m17n.org>
819
820 * coding.c (coding_set_source): Fix for the case that the current
821 buffer is different from coding->src_object.
822 (decode_coding_object): Don't use the conversion work buffer if
823 DST_OBJECT is a buffer.
824
825 2003-05-04 Dave Love <fx@gnu.org>
826
827 * lread.c (read_emacs_mule_char) [len==2]: Index
828 emacs_mule_charset correctly.
829
830 2003-02-16 Dave Love <fx@gnu.org>
831
832 * coding.c (Qbig5, Vbig5_coding_system, CATEGORY_MASK_BIG5)
833 (detect_coding_big5, decode_coding_big5, encode_coding_big5)
834 (Fdecode_big5_char, Fencode_big5_char): Deleted. (Big5 no longer
835 treated specially.)
836 (setup_coding_system, coding_category, CATEGORY_MASK_ANY)
837 (detected_mask): Remove Big5 bits.
838
839 2003-04-09 Kenichi Handa <handa@m17n.org>
840
841 The following changes are to make the font rescaling facility
842 compatible with Emacs 21.
843
844 * xfaces.c (Vface_font_rescale_alist): Renamed from
845 Vface_resizing_fonts.
846 (struct font_name): Rename member resizing_ratio to rescale_ratio.
847 (font_rescale_ratio): Renamed from font_resizing_ratio.
848 (split_font_name): Set font->rescale_ratio.
849 (better_font_p): Pay attention to font->rescale_ratio.
850 (build_scalable_font_name): Likewise. Change RESX, and RESY
851 fields.
852 (syms_of_xfaces): Declare Vface_font_rescale_alist as a Lisp
853 variable.
854
855 2003-03-28 Kenichi Handa <handa@m17n.org>
856
857 * coding.c (Qutf_16_be_nosig, Qutf_16_be, Qutf_16_le_nosig)
858 (Qutf_16_le): Remove these variables.
859 (syms_of_coding): Don't DEFSYM them.
860 (decode_coding_utf_16): Fix handling of BOM.
861 (encode_coding_utf_16): Fix handling of BOM.
862
863 2003-03-14 Kenichi Handa <handa@m17n.org>
864
865 * fileio.c (Finsert_file_contents): On replacing, before decoding
866 the file into the work buffer, set point of the work buffer to the
867 end.
868
869 2003-02-13 Dave Love <fx@gnu.org>
870
871 * coding.c (Fcheck_coding_systems_region): Fix type errors.
872
873 2003-02-04 Dave Love <fx@gnu.org>
874
875 * xterm.c (XTread_socket): Check Lisp types for Vx_keysym_table
876 and fix C types.
877
878 2003-01-31 Kenichi Handa <handa@m17n.org>
879
880 * xdisp.c (SKIP_GLYPHS): New macro.
881 (set_cursor_from_row): Pay attention to string display properties.
882
883 * category.c (copy_category_entry): Fix for the case that RANGE
884 is an integer.
885
886 * xterm.c (x_encode_char): Call ccl_driver with the last arg Qnil.
887
888 * w32term.c (w32_encode_char): Call ccl_driver with the last arg
889 Qnil.
890
891 2003-01-30 Kenichi Handa <handa@m17n.org>
892
893 * charset.c (Fcharset_id_internal): New function.
894 (syms_of_charset): Defsubr it.
895
896 * coding.c (decode_coding_ccl, encode_coding_ccl): Call ccl_driver
897 with the last arg charset_list acquired from coding.
898 (Fdefine_coding_system_internal): For ccl-based coding system, fix
899 the attribute coding_attr_ccl_valids.
900
901 * coding.h (enum define_coding_ccl_arg_index): Set the first
902 member coding_arg_ccl_decoder to coding_arg_max.
903
904 * ccl.h (ccl_driver): Prototype adjusted.
905
906 * ccl.c (CCL_DECODE_CHAR, CCL_ENCODE_CHAR): New macros.
907 (ccl_driver): New arg CHARSET_LIST. Use the above macros instead
908 of DECODE_CAHR, ENCODE_CHAR, CHAR_CHARSET.
909 (Fccl_execute): Call ccl_driver with the last arg Qnil.
910 (Fccl_execute_on_string): Likewise.
911
912 2003-01-11 Kenichi Handa <handa@m17n.org>
913
914 * charset.h (ENCODE_CHAR): If the method is SUBSET or SUPERSET,
915 call encode_char.
916
917 * charset.c (encode_char): Fix handling of methods SUBSET and
918 SUPERSET.
919
920 * xterm.c (x_new_fontset): Fix previous change.
921
922 2003-01-10 Dave Love <fx@gnu.org>
923
924 * composite.c (syms_of_composite): Make composition_hash_table
925 weak.
926
927 2003-01-10 Kenichi Handa <handa@m17n.org>
928
929 * dispextern.h (check_face_attributes, generate_ascii_font_name)
930 (font_name_registry): Don't extern them.
931 (split_font_name_into_vector, build_font_name_from_vector): Extern
932 them.
933
934 * fontset.h (Qfontset): Don't extern it.
935 (new_fontset_from_font_name): Extern it.
936
937 * fontset.c: Give 8 extra slots to fontset objects.
938 (Qfontset_info): New variable.
939 (syms_of_fontset): Defsym it.
940 (FONTSET_FALLBACK): New macro.
941 (fontset_face): Try also the default fontset.
942 (make_fontset): Realize a fallback fontset from the default
943 fontset.
944 (generate_ascii_font_name): Moved from xfaces.c. Rewritten by
945 using split_font_name_into_vector and build_font_name_from_vector.
946 (Fset_fontset_font): Access the elements of font_spec by enum
947 FONT_SPEC_INDEX. If font_spec is a string, extract the registry
948 name by using split_font_name_into_vector.
949 (Fnew_fontset): If no ASCII font is specified in FONTLIST,
950 generate a proper font name from the fontset name. Update
951 Vfontset_alias_alist.
952 (n_auto_fontsets): New variable.
953 (new_fontset_from_font_name): New function.
954 (Ffont_info): Store the information about fonts generated from the
955 default fontset in the first extra slot of the returned
956 char-table.
957
958 * xfaces.c (generate_ascii_font_name): Moved to fontset.c.
959 (font_name_registry): Function deleted.
960 (split_font_name_into_vector): New function.
961 (build_font_name_from_vector): New function.
962 (font_list): The argument REGISTRY is now a list of registry
963 names.
964 (choose_face_font): If we are choosing an ASCII font, and ATTRS
965 specifies an explicit font name, return the name as is. Make a
966 list of registy names.
967
968 * xfns.c (x_set_font, x_create_tip_frame): Adjusted to the change
969 of x_new_fontset.
970 (Fx_create_frame): Don't call x_new_fontset here. Just use
971 x_list_fonts to check the existence of fonts.
972
973 * xterm.h (x_new_fontset): Prototype adjusted.
974
975 * xterm.c (x_new_fontset): Change the arg FONTSETNAME to Lisp
976 string. Use new_fontset_from_font_name to create a fontset from a
977 font name.
978
979 2003-01-07 Dave Love <fx@gnu.org>
980
981 * Makefile.in: Fix some dependencies.
982
983 * keymap.c (Fapropos_internal): Don't gcpro apropos_predicate but
984 set it to nil before returning.
985
986 * composite.c (update_compositions): Fix type error.
987
988 * syntax.c (skip_chars, skip_syntaxes): Fix type errors.
989
990 2003-01-07 Kenichi Handa <handa@etl.go.jp>
991
992 * xterm.c (x_new_font): Optimize for the case that the font is
993 already set for the frame.
994
995 2003-01-06 Kenichi Handa <handa@m17n.org>
996
997 * chartab.c (char_table_ascii): Check if the char table contents
998 is sub-char-table or not.
999 (char_table_set): Fix argument to char_table_ascii.
1000 (char_table_set_range): Likewise.
1001
1002 * coding.c (CATEGORY_MASK_RAW_TEXT): New macro.
1003 (detect_coding_utf_8, detect_coding_utf_16)
1004 (detect_coding_emacs_mule, detect_coding_iso_2022)
1005 (detect_coding_sjis, detect_coding_big5)
1006 (detect_coding_ccl, detect_coding_charset): Change argument MASK
1007 to DETECT_INFO. Update DETECT_INFO and return 1 if the byte
1008 sequence is valid in this coding system. Callers changed.
1009 (MAX_ANNOTATION_LENGTH): New macro.
1010 (ADD_ANNOTATION_DATA): New macro.
1011 (ADD_COMPOSITION_DATA): Argument changed. Callers changed. Call
1012 ADD_ANNOTATION_DATA. The format of annotation data changed.
1013 (ADD_CHARSET_DATA): New macro.
1014 (emacs_mule_char): New argument ID. Callers changed.
1015 (decode_coding_emacs_mule, decode_coding_iso_2022)
1016 (decode_coding_sjis, decode_coding_big5, decode_coding_charset):
1017 Produce charset annotation data in coding->charbuf.
1018 (encode_coding_emacs_mule, encode_coding_iso_2022): Pay attention
1019 to charset annotation data in coding->charbuf.
1020 (setup_coding_system): Add CODING_ANNOTATE_CHARSET_MASK
1021 coding->common_flags if the coding system is iso-2022 based and
1022 uses designation.
1023 (produce_composition): Adjusted for the new annotation data
1024 format.
1025 (produce_charset): New function.
1026 (produce_annotation): Handle charset annotation.
1027 (handle_composition_annotation, handle_charset_annotation): New
1028 functions.
1029 (consume_chars): Handle charset annotation. Utilize the above two
1030 functions.
1031 (encode_coding_object): If SRC_OBJECT and DST_OBJECT are the same
1032 buffer, get the deleted text as a string and set
1033 coding->src_object to that string.
1034 (detect_coding, detect_coding_system): Use the new struct
1035 coding_detection_info.
1036
1037 * coding.h (struct coding_detection_info): New structure.
1038 (struct coding_system): Prototype of the member `detector'
1039 adjusted.
1040 (CODING_ANNOTATE_CHARSET_MASK): New macro.
1041
1042 2003-01-06 Kenichi Handa <handa@etl.go.jp>
1043
1044 * insdel.c (insert_from_gap): Fix argument to offset_intervals.
1045
1046 2003-01-03 Dave Love <fx@gnu.org>
1047
1048 * keymap.c (apropos_predicate, apropos_accumulate): Declare
1049 static.
1050 (Fapropos_internal): Don't gcpro apropos_accumulate. Set result
1051 to new local and nullify apropos_accumulate before returning.
1052 (syms_of_keymap): Staticpro and initialize apropos_accumulate.
1053
1054 2002-12-05 Kenichi Handa <handa@m17n.org>
1055
1056 * charset.c (Fdefine_charset_internal): Setup charset.fast_map
1057 correctly.
1058
1059 2002-11-26 Dave Love <fx@gnu.org>
1060
1061 * fns.c (Flanginfo): Call synchronize_system_time_locale.
1062
1063 2002-11-07 Kenichi Handa <handa@m17n.org>
1064
1065 The following changes are to make character composition happen
1066 automatically on displaying.
1067
1068 * Makefile.in (lisp, shortlisp): Add composite.elc
1069
1070 * composite.h (Qauto_composed, Vauto_composition_function,
1071 Qauto_composition_function): Extern them.
1072
1073 * composite.c (Vcomposition_function_table,
1074 Qcomposition_function_table): Delete variables.
1075 (Qauto_composed, Vauto_composition_function,
1076 Qauto_composition_function): New variables.
1077 (run_composition_function): Don't call
1078 compose-chars-after-function.
1079 (update_compositions): Clear `auto-composed' text property.
1080 (compose_chars_in_text): Delete this function.
1081 (syms_of_composite): Staticpro Qauto_composed and
1082 Qauto_composition_function. Declare Vauto_composition_function as
1083 a Lisp variable.
1084
1085 * dispextern.h (enum prop_idx): Add member AUTO_COMPOSED_PROP_IDX.
1086
1087 * xdisp.c (it_props): Add an entry for Qauto_composed.
1088 (handle_auto_composed_prop): New function.
1089
1090 * xselect.c (selection_data_to_lisp_data): Don't call
1091 compose_chars_in_text.
1092
1093 2002-11-06 Dave Love <fx@gnu.org>
1094
1095 * keyboard.c (read_char): Modify checking around use of
1096 Vkeyboard_translate_table.
1097
1098 * xterm.c (XTread_socket): Check Lisp types for Vx_keysym_table
1099 and fix C types.
1100
1101 2002-11-06 Kenichi Handa <handa@m17n.org>
1102
1103 * coding.c (decode_coding_utf_8): When eol_type is Qdos, handle
1104 the case that the last byte is '\r' correctly.
1105 (decode_coding_emacs_mule): Likewise.
1106 (decode_coding_iso_2022): Likewise.
1107 (decode_coding_sjis): Likewise.
1108 (decode_coding_big5): Likewise.
1109 (decode_coding_charset): Likewise.
1110 (produce_chars): Likewise.
1111 (decode_coding): Flushing out the unprocessed data correctly.
1112 (decode_coding_gap): Set CODING_MODE_LAST_BLOCK bit of
1113 coding->mode.
1114
1115 2002-10-31 Dave Love <fx@gnu.org>
1116
1117 * xterm.c (XTread_socket): Fix changes for defined keysyms. Add
1118 XK_ISO... case.
1119 (xaw_scroll_callback): Revert last change.
1120
1121 2002-10-30 Kenichi Handa <handa@m17n.org>
1122
1123 * charset.c (Fset_charset_priority): Update
1124 Viso_2022_charset_list.
1125
1126 2002-10-29 Kenichi Handa <handa@m17n.org>
1127
1128 * xfaces.c (Vface_resizing_fonts): New variable.
1129 (struct font_name): New member `resizing_ratio'.
1130 (font_resizing_ratio): New function.
1131 (split_font_name): Set font->resizing_ratio.
1132 (better_font_p): Pay attention to font->resizing_ratio.
1133 (build_scalable_font_name): Likewise. Don't change POINT_SIZE,
1134 RESX, and RESY fields.
1135 (try_alternative_families): Try scalable fonts if
1136 Vscalable_fonts_allowed is not Qt.
1137 (syms_of_xfaces): Declare Vface_resizing_fonts as a Lisp variable.
1138
1139 2002-10-29 Dave Love <fx@gnu.org>
1140
1141 * xterm.c (xaw_scroll_callback): Cast correctly.
1142
1143 2002-10-28 Dave Love <fx@gnu.org>
1144
1145 * keyboard.c (lispy_accent_codes, lispy_accent_keys): Extend.
1146 (lispy_kana_keys): Comment out.
1147 (make_lispy_event) [XK_kana_A]: Comment out.
1148
1149 * xterm.c (xaw_scroll_callback): Cast call_data.
1150 (XTread_socket): Deal with ASCII keysyms.
1151 (syms_of_xterm) <Vx_keysym_table>: Fix args of make_hash_table.
1152
1153 2002-10-27 Dave Love <fx@gnu.org>
1154
1155 * xterm.c (Vx_keysym_table): New.
1156 (syms_of_xterm): Initialize it.
1157 (XTread_socket): Use it.
1158 From head: Eliminate incorrect optimization that tried to avoid
1159 decoding the output of X*LookupString.
1160 (x_get_font_repertory): Delete charset declaration.
1161
1162 2002-10-16 Kenichi Handa <handa@m17n.org>
1163
1164 * coding.c (detect_coding): Fix previous change.
1165 (detect_coding_charset): If only ASCII bytes are found, return 0.
1166 (detect_coding_system): Fix previous change.
1167 (Fdefine_coding_system_internal): Setup CODING_ATTR_ASCII_COMPAT
1168 (attrs) correctly.
1169
1170 2002-10-15 Dave Love <fx@gnu.org>
1171
1172 * coding.c (Fcheck_coding_system): Doc fix.
1173
1174 * editfns.c (Finsert_byte): Return a proper value.
1175
1176 2002-10-14 Kenichi Handa <handa@etl.go.jp>
1177
1178 * coding.c (decode_coding): Fix args to translate_chars. Pay
1179 attention to Vstandard_translation_table_for_decode.
1180 (encode_coding): Fix args to translate_chars. Pay attention to
1181 Vstandard_translation_table_for_encode.
1182
1183 * data.c (Faset): Check NEWELT by ASCII_CHAR_P, not by
1184 SINGLE_BYTE_CHAR_P.
1185
1186 * editfns.c (general_insert_function): Check VAL by ASCII_CHAR_P,
1187 not by SINGLE_BYTE_CHAR_P.
1188
1189 * fns.c (concat): Check CH by ASCII_CHAR_P, not by
1190 SINGLE_BYTE_CHAR_P.
1191
1192 * insdel.c (copy_text): Check C by ASCII_CHAR_P, not by
1193 SINGLE_BYTE_CHAR_P.
1194
1195 * keymap.c (Ftext_char_description): Check C by ASCII_CHAR_P, not
1196 by SINGLE_BYTE_CHAR_P.
1197
1198 * search.c (Freplace_match): Check C by ASCII_CHAR_P, not by
1199 SINGLE_BYTE_CHAR_P.
1200
1201 2002-10-14 Dave Love <fx@gnu.org>
1202
1203 * fns.c (Fstring_as_multibyte, Fstring_to_multibyte): Doc fix.
1204
1205 2002-10-10 Dave Love <fx@gnu.org>
1206
1207 * fns.c (Flanginfo): Fix typo.
1208
1209 * unexelf.c (unexec): Make last change conditional on Irix 6.5.
1210
1211 2002-10-10 Kenichi Handa <handa@m17n.org>
1212
1213 * coding.c (detect_coding_utf_8): Check incomplete byte sequence.
1214 Don't update *mask when correctly detected.
1215 (detect_coding_utf_16): Likewise.
1216 (detect_coding_emacs_mule): Likewise.
1217 (detect_coding_iso_2022): Likewise.
1218 (detect_coding_sjis): Likewise.
1219 (detect_coding_big5): Likewise.
1220 (detect_coding_ccl): Likewise.
1221 (decode_coding_sjis): Fix decoding of katakana-jisx0201.
1222 (detect_eol): Delete the argument CODING, and add the argument
1223 CATEGORY.
1224 (detect_coding): Adjusted for the changes above.
1225 (detect_coding_system): Likewise.
1226
1227 2002-10-09 Kenichi Handa <handa@m17n.org>
1228
1229 * character.c (char_string): Renamed from
1230 char_string_with_unification. Pay attention to
1231 CHAR_MODIFIER_MASK.
1232 (string_char): Renamed from string_char.
1233
1234 * character.h (CHAR_STRING): Call char_string if C is greater than
1235 MAX_3_BYTE_CHAR.
1236 (CHAR_STRING_ADVANCE): Likewise.
1237 (STRING_CHAR): Call string_char instead of
1238 string_char_with_unification.
1239 (STRING_CHAR_AND_LENGTH): Likewise.
1240 (STRING_CHAR_ADVANCE): Likewise.
1241
1242 2002-10-09 Dave Love <fx@gnu.org>
1243
1244 * coding.c (decode_coding_utf_8): Treat surrogates as invalid.
1245
1246 2002-10-07 Kenichi Handa <handa@m17n.org>
1247
1248 * keymap.c (push_key_description): Pay attention to
1249 force_multibyte.
1250
1251 * regex.c (re_search_2): Fix for the case of unibyte buffer.
1252
1253 2002-10-06 Dave Love <fx@gnu.org>
1254
1255 * charset.c (define_charset_internal): Rename `supprementary'.
1256
1257 * Makefile.in (lisp, shortlisp): Remove latin-N.
1258
1259 2002-10-05 Dave Love <fx@gnu.org>
1260
1261 * xfns.c (x_window, x_window): Use use_xim.
1262
1263 * xterm.c (use_xim): Initialize.
1264 (xim_open_dpy, xim_initialize, xim_close_dpy): Use use_xim.
1265 (x_term_init): Maybe set use_xim.
1266
1267 * xterm.h (use_xim) [HAVE_X_I18N]: Declare.
1268
1269 2002-10-01 Kenichi Handa <handa@m17n.org>
1270
1271 * search.c (search_buffer): Fix case-fold-search of multibyte
1272 characters.
1273 (boyer_moore): Rename the last argument to char_high_bits.
1274
1275 2002-09-27 Kenichi Handa <handa@etl.go.jp>
1276
1277 * xdisp.c (display_string): Fix for the case of zero width glyph.
1278
1279 * xfns.c (x_set_font): Change the error message of the case that
1280 x_new_fontset returns Qt.
1281
1282 * xfaces.c (set_lface_from_font_name): Reject the default fontset.
1283 (Finternal_set_lisp_face_attribute): Use signal_error for the
1284 error of invalid fontset.
1285
1286 * xterm.c (x_new_fontset): If FONTSETNAME specifies the default
1287 fontset, return Qt.
1288
1289 2002-09-19 Kenichi Handa <handa@etl.go.jp>
1290
1291 * regex.c (re_search_2): Fix previous change.
1292
1293 2002-09-18 Kenichi Handa <handa@etl.go.jp>
1294
1295 * syntax.c (skip_syntaxes): Fix previous change.
1296
1297 2002-09-13 Kenichi Handa <handa@etl.go.jp>
1298
1299 * syntax.c (skip_chars): Fix previous change.
1300 (skip_syntaxes): Fix previous change.
1301
1302 2002-09-06 Dave Love <fx@gnu.org>
1303
1304 * config.in: Restore it.
1305
1306 2002-09-05 Dave Love <fx@gnu.org>
1307
1308 * config.in: Removed (now auto-generated).
1309
1310 * s/usg5-4.h: Fix last change.
1311
1312 * unexelf.c (unexec): Make .got handling not SGI-specific.
1313
1314 * syntax.c (syms_of_syntax) <multibyte-syntax-as-symbol>: Doc fix.
1315
1316 * regex.c: Use `ifdef HAVE_ALLOCA_H', not `if HAVE_ALLOCA_H'.
1317
1318 * keyboard.c (read_key_sequence): Fix type error.
1319
1320 * buffer.c (Fset_buffer_multibyte, Fset_buffer_multibyte): Fix
1321 type error.
1322
1323 * fontset.c (fontset_add): Return Lisp_Object.
1324
1325 2002-09-03 Dave Love <fx@gnu.org>
1326
1327 * charset.h (charset_ordered_list_tick): Declare extern.
1328
1329 2002-09-03 Kenichi Handa <handa@etl.go.jp>
1330
1331 The following changes (and some of 2002-08-20 changes of mine) are
1332 for handling syntax, category, and case conversion for unibyte
1333 characters by converting them to multibyte on the fly. With these
1334 changes, we don't have to setup syntax and case tables for unibyte
1335 characters in each language environment.
1336
1337 * abbrev.c (Fexpand_abbrev): Convert a unibyte character to
1338 multibyte if necessary.
1339
1340 * bytecode.c (Fbyte_code): Likewise.
1341
1342 * character.h (LEADING_CODE_LATIN_1_MIN)
1343 (LEADING_CODE_LATIN_1_MAX): New macros.
1344 (unibyte_to_multibyte_table): Extern it.
1345 (unibyte_char_to_multibyte): New macro.
1346 (MAKE_CHAR_MULTIBYTE): Use unibyte_to_multibyte_table.
1347 (CHAR_LEADING_CODE): New macro.
1348 (FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE): New macro.
1349
1350 * character.c (unibyte_to_multibyte_table): New variable.
1351 (unibyte_char_to_multibyte): Move to character.h and defined as
1352 macro.
1353 (multibyte_char_to_unibyte): If C is an eight-bit character,
1354 convert it to the corresponding byte value.
1355
1356 * charset.c (Fset_unibyte_charset): If the dimension of CHARSET is
1357 not 1, singals an error. Update the elements of
1358 unibyte_to_multibyte_table.
1359 (init_charset_once): Initialize unibyte_to_multibyte_table.
1360 (syms_of_charset): Define the charset `iso-8859-1'.
1361
1362 * casefiddle.c (casify_object): Fix previous change.
1363
1364 * cmds.c (internal_self_insert): In a multibyte buffer, insert C
1365 as is without converting it to unibyte. In a unibyte buffer,
1366 convert C to multibyte before checking the syntax.
1367
1368 * lisp.h (unibyte_char_to_multibyte): Extern deleted.
1369
1370 * minibuf.c (Fminibuffer_complete_word): Use the macro
1371 FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE.
1372
1373 * regex.h (struct re_pattern_buffer): New member target_multibyte.
1374
1375 * regex.c (RE_TARGET_MULTIBYTE_P): New macro.
1376 (GET_CHAR_BEFORE_2): Check target_multibyte, not multibyte. If
1377 that is zero, convert an eight-bit char to multibyte.
1378 (MAKE_CHAR_MULTIBYTE, CHAR_LEADING_CODE): New dummy new macros for
1379 non-emacs case.
1380 (PATFETCH): Convert an eight-bit char to multibyte.
1381 (HANDLE_UNIBYTE_RANGE): New macro.
1382 (regex_compile): Setup the compiled pattern for multibyte chars
1383 even if the given regex string is unibyte. Use PATFETCH_RAW
1384 instead of PATFETCH in many places. To handle `charset'
1385 specification of unibyte, call HANDLE_UNIBYTE_RANGE. Use bitmap
1386 only for ASCII chars.
1387 (analyse_first) <exactn>: Simplified because the compiled pattern
1388 is multibyte.
1389 <charset_not>: Setup fastmap from bitmap only for ASCII chars.
1390 <charset>: Use CHAR_LEADING_CODE to get leading codes.
1391 <categoryspec>: If multibyte, setup fastmap only for ASCII chars
1392 here.
1393 (re_compile_fastmap) [emacs]: Call analyse_first with the arg
1394 multibyte always 1.
1395 (re_search_2) In emacs, set the locale variable multibyte to 1,
1396 otherwise to 0. New local variable target_multibyte. Check it
1397 to decide the multibyteness of STR1 and STR2. If
1398 target_multibyte is zero, convert unibyte chars to multibyte
1399 before translating and checking fastmap.
1400 (TARGET_CHAR_AND_LENGTH): New macro.
1401 (re_match_2_internal): In emacs, set the locale variable multibyte
1402 to 1, otherwise to 0. New local variable target_multibyte. Check
1403 it to decide the multibyteness of STR1 and STR2. Use
1404 TARGET_CHAR_AND_LENGTH to fetch a character from D.
1405 <charset, charset_not>: If multibyte is nonzero, check fastmap
1406 only for ASCII chars. Call bcmp_translate with
1407 target_multibyte, not with multibyte.
1408 <begline>: Declare the local variable C as `unsigned'.
1409 (bcmp_translate): Change the last arg name to target_multibyte.
1410
1411 * search.c (compile_pattern_1): Don't adjust the multibyteness of
1412 the regexp pattern and the matching target. Set cp->buf.multibyte
1413 to the multibyteness of the regexp pattern. Set
1414 cp->but.target_multibyte to the multibyteness of the matching
1415 target.
1416 (wordify): Use FETCH_STRING_CHAR_AS_MULTIBYTE_ADVANCE instead of
1417 FETCH_STRING_CHAR_ADVANCE.
1418 (Freplace_match): Convert unibyte chars to multibyte.
1419
1420 * syntax.c (char_quoted): Use FETCH_CHAR_AS_MULTIBYTE to convert
1421 unibyte chars to multibyte.
1422 (back_comment): Likewise.
1423 (scan_words): Likewise.
1424 (skip_chars): The arg syntaxp is deleted, and the code for
1425 handling syntaxes is moved to skip_syntaxes. Callers changed.
1426 Fix the case that the multibyteness of STRING and the current
1427 buffer doesn't match.
1428 (skip_syntaxes): New function.
1429 (SYNTAX_WITH_MULTIBYTE_CHECK): Check C by ASCII_CHAR_P, not by
1430 SINGLE_BYTE_CHAR_P.
1431 (Fforward_comment): Use FETCH_CHAR_AS_MULTIBYTE to convert unibyte
1432 chars to multibyte.
1433 (scan_lists): Likewise.
1434 (Fbackward_prefix_chars): Likewise.
1435 (scan_sexps_forward): Likewise.
1436
1437 2002-08-23 Kenichi Handa <handa@etl.go.jp>
1438
1439 * xfaces.c (QCfontset): New variable.
1440 (LFACE_FONTSET): New macro.
1441 (check_lface_attrs): Check also LFACE_FONTSET_INDEX.
1442 (set_lface_from_font_name): Setup LFACE_FONTSET (lface).
1443 (Finternal_set_lisp_face_attribute): Handle QCfontset.
1444 (Finternal_get_lisp_face_attribute): Likewise.
1445 (lface_same_font_attributes_p): Fix checking of LFACE_FONT_INDEX,
1446 check also LFACE_FONTSET_INDEX.
1447 (face_fontset): Check attrs[LFACE_FONTSET_INDEX], not
1448 attrs[LFACE_FONT_INDEX].
1449 (syms_of_xfaces): Intern and staticpro QCfontset.
1450
1451 * dispextern.h (enum lface_attribute_index): New member
1452 LFACE_FONTSET_INDEX.
1453
1454 * fns.c (base64_encode_1): Handle eight-bit chars correctly.
1455
1456 2002-08-21 Kenichi Handa <handa@etl.go.jp>
1457
1458 * coding.c (coding_set_destination): Fix coding->destination for
1459 the case converting a region.
1460 (encode_coding_utf_8): Encode eight-bit chars as single byte.
1461 (encode_coding_object): Fix coding->dst_pos and
1462 coding->dst_pos_byte for the case converting a region.
1463
1464 * insdel.c (insert_from_gap): Make it work even if PT != GTP.
1465
1466 * character.h (BYTE8_STRING): New macro.
1467
1468 * fns.c (base64_decode_1): Insert eight-bit chars correctly.
1469
1470 2002-08-20 Kenichi Handa <handa@etl.go.jp>
1471
1472 * xdisp.c (get_next_display_element): Don't display unibyte 8-bit
1473 characters by octal form.
1474
1475 * abbrev.c (Fexpand_abbrev): Fix for the multibyte case.
1476
1477 * buffer.h (_fetch_multibyte_char_len): Extern deleted.
1478 (FETCH_MULTIBYTE_CHAR): Don't use _fetch_multibyte_char_len.
1479 (BUF_FETCH_MULTIBYTE_CHAR): Likewise.
1480 (FETCH_CHAR_AS_MULTIBYTE): New macro.
1481
1482 * casetab.c (set_canon, set_identity, shuffle): Simplified.
1483
1484 * casefiddle.c (casify_object): Simplified. Handle the case that
1485 the case conversion change the byte length.
1486 (casify_region): Likewise
1487
1488 * character.h (MAKE_CHAR_UNIBYTE, MAKE_CHAR_MULTIBYTE): New
1489 macros.
1490
1491 * character.c (_fetch_multibyte_char_len): This variable deleted.
1492 (syms_of_character): Setup Vprintable_chars.
1493
1494 * editfns.c (Fchar_equal): Fix for the unibyte case.
1495 (Finsert_byte): New function.
1496 (syms_of_editfns): Defsubr it.
1497
1498 * keyboard.c (read_key_sequence): Use ~CHAR_MODIFIER_MASK instead
1499 of direct code 0x3ffff.
1500
1501 * search.c (Freplace_match): Fix for the unibyte case.
1502
1503 2002-08-19 Kenichi Handa <handa@etl.go.jp>
1504
1505 * lread.c (safe_to_load_p): Fix the logic.
1506
1507 * syntax.c (scan_words): Don't treat characters belonging to
1508 different scripts as constituting a word.
1509
1510 * editfns.c (Fformat): Use ASCII_CHAR_P, not SINGLE_BYTE_CHAR_P.
1511
1512 * fontset.c (Fset_fontset_font): Treat `ascii' as charset, not
1513 script.
1514
1515 * emacs.c (main): In the case of --unibyte, instead of aborting on
1516 finding non-empty buffer, make it unibyte.
1517
1518 2002-08-18 Kenichi Handa <handa@etl.go.jp>
1519
1520 * xterm.c (x_new_fontset): Call `create-fontset-from-ascii-font'
1521 to create a fontset.
1522
1523 2002-08-18 Dave Love <fx@gnu.org>
1524
1525 * character.c (Funibyte_char_to_multibyte): Doc fix.
1526
1527 * xfns.c [HAVE_STDLIB_H]: Fix last change.
1528
1529 2002-08-15 Kenichi Handa <handa@etl.go.jp>
1530
1531 * fontset.c (fontset_add): Make the type `int'.
1532 (fontset_id_valid_p): Define it if FONTSET_DEBUG is defined.
1533
1534 * character.c (unibyte_char_to_multibyte): Refer to
1535 charset_unibyte, not charset_primary.
1536 (multibyte_char_to_unibyte): Likewise.
1537 (Funibyte_char_to_multibyte): Likewise.
1538
1539 * charset.h: (charset_unibyte): Extern it instead of
1540 charset_primary.
1541
1542 * charset.c (charset_unibyte): Renamed from charset_primary.
1543 (Funibyte_charset): Renamed from Fprimary_charset.
1544 (Fset_unibyte_charset): Renamed from Fset_primary_charset.
1545 (syms_of_charset): Adjusted for the above changes.
1546
1547 * w32term.c (x_produce_glyphs): Use ASCII_CHAR_P, not
1548 SINGLE_BYTE_CHAR_P. Fix the logic of handling non-ASCII char when
1549 it->multibyte_p is zero.
1550
1551 * lisp.h (nonascii_insert_offset, Vnonascii_translation_table):
1552 Extern deleted.
1553
1554 2002-08-08 Kenichi Handa <handa@etl.go.jp>
1555
1556 * coding.c (Fdefine_coding_system_internal): Fix category setting
1557 for a coding system of type iso-2022.
1558
1559 2002-08-02 Kenichi Handa <handa@etl.go.jp>
1560
1561 * fontset.h (FS_LOAD_FONT): Call fs_load_font with the arg CHARSET
1562 -1.
1563
1564 2002-08-01 Kenichi Handa <handa@etl.go.jp>
1565
1566 * syntax.c (Vnext_word_boundary_function_table): New variable.
1567 (syms_of_syntax): Declare it as a Lisp variable.
1568 (scan_words): Call functions in Vnext_word_boundary_function_table
1569 if any.
1570
1571 * xterm.c (x_load_font): Initialize fontp->fontset to -1.
1572
1573 * fontset.c (fs_load_font): If fontp->charset is not negative,
1574 return fontp without setting its members.
1575
1576 2002-07-31 Dave Love <fx@gnu.org>
1577
1578 * config.in: Generated with autoheader.
1579
1580 * xfns.c [HAVE_STDLIB_H]: Change logic (instead of fixing typo).
1581
1582 * m/sparc.h (HAVE_ALLOCA): Delete.
1583
1584 * s/irix6-5.h: Don't include strings.h.
1585 (bcopy, bzero, bcmp): Don't undef.
1586
1587 * s/irix6-0.h (bcopy, bzero, bcmp): Don't undef.
1588
1589 * s/usg5-4.h (NO_SIOCTL_H): Don't define.
1590 (TIOCSIGSEND): Don't test IRIX6.
1591 (bcopy, bzero, bcmp): Define conditionally.
1592
1593 2002-07-31 Kenichi Handa <handa@etl.go.jp>
1594
1595 * buffer.c (Qas, Qmake, Qto): New variables.
1596 (Fset_buffer_multibyte): New optional arg METHOD. Caller changed.
1597 (syms_of_buffer): Intern and staticpro Qas, Qmake, and Qto.
1598
1599 * callproc.c (Fcall_process): Don't call insert_1_both directly if
1600 we are inserting a process output into a multibyte buffer.
1601
1602 * character.h (CHAR_TO_BYTE8): If C is not eight-bit char, call
1603 multibyte_char_to_unibyte.
1604
1605 * character.c (Funibyte_char_to_multibyte): If C can't be decoded
1606 by the primary charset, make it eight-bit char.
1607 (Fmultibyte_char_to_unibyte): Call CHAR_TO_BYTE8.
1608
1609 * charset.c: (charset_eight_bit, Qeight_bit_control): New
1610 variables.
1611 (charset_8_bit__control, charset_8_bit_graphic,
1612 Qeight_bit_control, Qeight_bit_graphic): These variables deleted.
1613 (define_charset_internal): New function.
1614 (syms_of_charset): Call define_charset_internal for pre-defined
1615 charsets.
1616
1617 * charset.h (charset_8_bit): Extern it.
1618
1619 * coding.c (make_conversion_work_buffer): Adjusted for the change
1620 of Fset_buffer_multibyte.
1621 (encode_coding_raw_text): Increment p0 in the loop.
1622
1623 * lisp.h (Fset_buffer_multibyte): Prototype adjusted.
1624
1625 * xdisp.c (setup_echo_area_for_printing, set_message_1): Adjusted
1626 for the change of Fset_buffer_multibyte.
1627
1628 * fns.c (Fstring_to_multibyte): New function.
1629 (syms_of_fns): Declare Fstring_to_multibyte as Lisp subroutine.
1630
1631 2002-07-30 Dave Love <fx@gnu.org>
1632
1633 * xfns.c (x_put_x_image): Declare args.
1634
1635 * xfaces.c (font_name_registry, choose_face_font): Delete unused
1636 vars.
1637 (try_font_list): Declare an arg.
1638
1639 * xdisp.c (message2_nolog, set_message): Declare an arg.
1640
1641 * terminfo.c (tparam): Declare an arg. Use P_ to declare tparm.
1642
1643 * syntax.c (scan_sexps_forward): Declare an arg.
1644
1645 * scroll.c (calculate_scrolling, calculate_direct_scrolling):
1646 Declare an arg.
1647
1648 * lisp.h (Fnew_fontset): Declare.
1649
1650 * keymap.c (push_key_description): Call CHARACTERP correctly.
1651
1652 * fontset.c (fontset_add): Declare args. Call make_number
1653 correctly.
1654 (face_for_char): Delete unused vars.
1655 (Fset_fontset_font): Doc fix. Delete unused vars.
1656
1657 * doc.c (Fsubstitute_command_keys): Delete unused vars.
1658
1659 * composite.c (update_compositions): Declare arg.
1660
1661 * cm.c (calccost, cmgoto): Declare args.
1662
1663 * charset.c: Remove `emacs' conditional. Doc fixes.
1664 (map_char_table_for_charset): Declare.
1665
1666 * character.c (syms_of_character) <translation-table-vector>: Doc
1667 fix.
1668
1669 * ccl.c: Remove `emacs' conditional. Include hash table stuff
1670 from trunk.
1671
1672 2002-07-26 Kenichi Handa <handa@etl.go.jp>
1673
1674 The following changes are to allow specifying multiple font
1675 patterns for a character range (specified by script or charset).
1676
1677 * Makefile.in (abbrev.o): Depend on syntax.h.
1678 (xfaces.o): Depend on charset.h.
1679
1680 * alloc.c (Fmake_string): Use ASCII_CHAR_P, not
1681 SINGLE_BYTE_CHAR_P.
1682
1683 * ccl.c (Fccl_execute_on_string): Add `const' to local variables.
1684
1685 * character.h (Vchar_script_table): Extern it.
1686
1687 * character.c (Vscript_alist): This variable deleted.
1688 (Vchar_script_table, Qchar_script_table): New variable.
1689 (syms_of_character): Declare Vchar_script_table as a lisp variable
1690 and initialize it.
1691
1692 * chartab.c (Fmake_char_table): Doc fixed. If PURPOSE doesn't
1693 have property char-table-extra-slots, make no extra slot.
1694
1695 * dispextern.h (struct face): Member `charset' deleted.
1696 (FACE_SUITABLE_FOR_CHAR_P): Use ASCII_CHAR_P, not
1697 SINGLE_BYTE_CHAR_P.
1698 (FACE_FOR_CHAR): Likewise.
1699 (choose_face_font, lookup_non_ascii_face, font_name_registry): Add
1700 prototypes
1701 (lookup_face, lookup_named_face, lookup_derived_face): Prototype
1702 fixed.
1703 (generate_ascii_font_name): Renamed from generate_ascii_font.
1704
1705 * fontset.h (get_font_repertory_func): New prototype.
1706 (make_fontset_for_ascii_face, fs_load_font): Prototypes fixed.
1707 (FS_LOAD_FONT): Call fs_load_font with the 3rd arg charset_ascii.
1708
1709 * fontset.c (Qprepend, Qappend): New variables.
1710 (FONTSET_CHARSET_ALIST, FONTSET_FACE_ALIST): These macros deleted.
1711 (FONTSET_NOFONT_FACE, FONTSET_REPERTORY): New macros.
1712 (FONTSET_REF): Optimize if FONTSET is Vdefault_fontset.
1713 (FONTSET_REF_AND_RANGE, FONTSET_ADD): New macros.
1714 (fontset_ref_and_range, fontset_add, reorder_font_vector)
1715 (load_font_get_repertory): New functions.
1716 (fontset_set): This function deleted.
1717 (fontset_face): New arg FACE. Return face ID, not face.
1718 Completely re-written to handle new fontset structure. Caller
1719 changed.
1720 (free_face_fontset): Use ASET istead of AREF (X) = Y.
1721 (face_for_char): Don't call lookup_face.
1722 (make_fontset_for_ascii_face): New arg FACE.
1723 (fs_load_font): New arg CHARSET_ID. Don't check
1724 Vfont_encoding_alist here.
1725 (find_font_encoding): New function.
1726 (list_fontsets): Use STRINGP, not ! NILP.
1727 (accumulate_script_ranges): New function.
1728 (Fset_fontset_font, Fnew_fontset, Ffontset_info): Completely
1729 re-written to handle new fontset structure.
1730 (Ffontset_font): Return a copy of element.
1731 (syms_of_fontset): Define symbols Qprepend and Qappend. Fix
1732 docstring of font-encoding-alist.
1733
1734 * lisp.h (CHAR_TABLE_REF): Remove unnecessary check (IDX >= 0).
1735 (Fset_fotset_font): Fix arguments to 5.
1736
1737 * msdos.c (XMenuActivate): Adjuted for the change of
1738 lookup_derived_face.
1739
1740 * xdisp.c (message_dolog, set_message_1, extend_face_to_end_of_line):
1741 Use ASCII_CHAR_P, not SINGLE_BYTE_CHAR_P.
1742 (highlight_trailing_whitespace): Adjusted for the change of
1743 lookup_named_face.
1744
1745 * xfaces.c: Include charset.h.
1746 (load_face_font): Argument C deleted. Caller changed.
1747 (generate_ascii_font_name): Renamed from generate_ascii_font.
1748 (font_name_registry): New function.
1749 (cache_face): Store ascii faces before non-ascii faces in buckets.
1750 (lookup_face): Arguments C and BASE_FACE deleted. Caller changed.
1751 Lookup only ascii faces.
1752 (lookup_non_ascii_face): New function.
1753 (lookup_named_face): Argument C deleted. Caller changed.
1754 (lookup_derived_face): Argument C deleted. Caller changed.
1755 (try_font_list): New arg PATTERN. Caller changed. If PATTERN is
1756 a string, just call font_list with it.
1757 (choose_face_font): Arguments FACE and C deleted. New arg
1758 FONT_SPEC. Caller changed.
1759 (realize_face): Arguments C and BASE_FACE deleted. Caller
1760 (realize_x_face): Likewise.
1761 (realize_non_ascii_face): New function.
1762 (realize_x_face): Call load_face_font here.
1763 (realize_tty_face): Argument C deleted. Caller changed.
1764 (compute_char_face): If CH is not ascii, call FACE_FOR_CHAR to
1765 get a face ID.
1766 (dump_realized_face): Don't print charset of FACE.
1767
1768 * xfns.c (x_set_font): Always call x_new_fontset and
1769 store_frame_parameter.
1770 (Fx_create_frame): Call x_new_fontset, not x_new_font.
1771 (syms_of_xfns): Set get_font_repertory_func to
1772 x_get_font_repertory.
1773
1774 * xterm.h (x_get_font_repertory): Extern it.
1775
1776 * xterm.c (x_produce_glyphs): Use ASCII_CHAR_P, not
1777 SINGLE_BYTE_CHAR_P. Fix the logic of handling non-ASCII char when
1778 it->multibyte_p is zero.
1779 (XTread_socket): Use ASCII_CHAR_P, not SINGLE_BYTE_CHAR_P.
1780 (x_new_fontset): If FONTSETNAME doesn't match any existing
1781 fontsets, create a new one.
1782 (x_get_font_repertory): New function.
1783
1784 2002-07-25 Kenichi Handa <handa@etl.go.jp>
1785
1786 * coding.c (Ffind_coding_systems_region_internal): Detect an
1787 ASCII only string correctly.
1788
1789 * lread.c (Fload): Don't load with Qload_force_doc_strings t if
1790 version is 0.
1791
1792 2002-07-24 Kenichi Handa <handa@etl.go.jp>
1793
1794 * lread.c: Include "coding.h".
1795 (Qget_emacs_mule_file_char, Qload_force_doc_strings,
1796 load_each_byte, unread_char): New variables.
1797 (readchar_backlog): This variable deleted.
1798 (readchar): Return a character unless load_each_byte is nonzero.
1799 Handle the case that readcharfun is Qget_emacs_mule_file_char or a
1800 cons. If unread_char is not -1, simply return it.
1801 (unreadchar): Handle the case that readcharfun is
1802 Qget_emacs_mule_file_char or a cons. Set unread_char if
1803 necessary.
1804 (read_multibyte): This function deleted.
1805 (readbyte_for_lambda, readbyte_from_file, readbyte_from_string)
1806 (read_emacs_mule_char): New functions.
1807 (Fload): Even if the file doesn't have the extention ".elc", if
1808 safe_to_load_p returns a positive version number, assume that the
1809 file contains bytecompiled code. If the version is less than 22,
1810 load the file while decoding multibyte sequences by emacs-mule.
1811 (readevalloop): Don't use readchar_backlog.
1812 (Fread): Likewise. Pay attention to the case that STREAM is a
1813 cons.
1814 (Fread_from_string): Pay attention to the case that STREAM is a
1815 cons.
1816 (read_escape): The arg BYTEREP deleted.
1817 (read1): Set load_each_byte to 1 temporarily while handling
1818 #@NUMBER. Don't call read_multibyte.
1819 (read_vector): Call Fread with a cons. If readcharfun is
1820 Qget_emacs_mule_file_char, decode the read string by emacs-mule.
1821 (read_list): If doc_reference is 2, make the cdr part string as
1822 unibyte.
1823 (syms_of_lread): Intern and staticpro Qget_emacs_mule_file_char
1824 and Qload_force_doc_strings.
1825
1826 2002-07-23 Kenichi Handa <handa@etl.go.jp>
1827
1828 * xdisp.c (face_before_or_after_it_pos): Call
1829 FETCH_MULTIBYTE_CHAR with byte postion, not char position.
1830
1831 2002-07-22 Kenichi Handa <handa@etl.go.jp>
1832
1833 * character.h (TRAILING_CODE_P): New macro.
1834 (MAYBE_UNIFY_CHAR): Adjusted for the change of Funify_charset.
1835 (string_char_with_unification): Fix prototype.
1836 (Vscript_alist): Extern it.
1837
1838 * character.c (Vscript_alist): New variable.
1839 (string_char_with_unification): Add `const' to local variables.
1840 (str_as_unibyte): Likewise.
1841 (string_escape_byte8): Likewise.
1842 (syms_of_character): Declare script-alist as a Lisp variable.
1843
1844 * charset.h (Vcharset_ordered_list): Extern it.
1845 (charset_ordered_list_tick): Extern it.
1846 (EMACS_MULE_LEADING_CODE_PRIVATE_11)
1847 (EMACS_MULE_LEADING_CODE_PRIVATE_12)
1848 (EMACS_MULE_LEADING_CODE_PRIVATE_21)
1849 (EMACS_MULE_LEADING_CODE_PRIVATE_22): New macros
1850 (Funify_charset): Adjusted for the change of Funify_charset.
1851
1852 * charset.c (charset_ordered_list_tick): New variable.
1853 (Fdefine_charset_internal): Increment charset_ordered_list_tick.
1854 (Funify_charset): New optional arg DEUNIFY. If it is non-nil,
1855 deunify intead of unify a charset.
1856 (string_xstring_p): Add `const' to local variables.
1857 (find_charsets_in_text): Add `const' to arguemnts and local
1858 variables.
1859 (encode_char): Adjusted for the change of Funify_charset. Fix
1860 detecting of invalid code.
1861 (Fset_charset_priority): Increment charset_ordered_list_tick.
1862 (Fmap_charset_chars): Fix handling of default value for FROM_CODE
1863 and TO_CODE.
1864
1865 * coding.c (LEADING_CODE_PRIVATE_11, LEADING_CODE_PRIVATE_12)
1866 (LEADING_CODE_PRIVATE_21, LEADING_CODE_PRIVATE_22): Macros
1867 deleted. Callers changed to use
1868 EMACS_MULE_LEADING_CODE_PRIVATE_11, etc.
1869 (decode_coding_ccl): Add `const' to local variables.
1870 (consume_chars): Likewise.
1871 (Ffind_coding_systems_region_internal): Likewise.
1872 (Fcheck_coding_systems_region): Likewise.
1873
1874 * print.c (print_object): Use octal form for printing the
1875 contents of a bool vector.
1876
1877 2002-07-18 Dave Love <fx@gnu.org>
1878
1879 * lread.c (Fload) <!load_dangerous_libraries>: Don't leak fd.
1880 <version == 20>: Refuse to load.
1881
1882 2002-07-17 Dave Love <fx@gnu.org>
1883
1884 * fns.c: Move coding.h.
1885 (Qcodeset, Qdays, Qmonths): New.
1886 (concat): Use CHARACTERP instead of INTERGERP.
1887 (Flocale_codeset): Deleted.
1888 (Flanginfo): New function.
1889 (syms_of_fns): Changed accordingly.
1890
1891 * coding.c (adjust_coding_eol_type): Fix eol_type/eol_seen mixup.
1892
1893 2002-07-16 Dave Love <fx@gnu.org>
1894
1895 * casetab.c (init_casetab_once, init_casetab_once): Fix
1896 CHAR_TABLE_SET call.
1897
1898 * category.c (Fmodify_category_entry): Fix CATEGORY_MEMBER call.
1899
1900 * character.c (syms_of_character): Fix CHAR_TABLE_SET call.
1901
1902 * charset.c (Fmap_charset_chars): Check args. Convert Lisp types.
1903 (load_charset_map, Fdeclare_equiv_charset, Fencode_char)
1904 (Fset_charset_priority, syms_of_charset): Convert Lisp types.
1905
1906 * charset.h (CHECK_CHARSET_GET_ID): Use XINT on AREF result.
1907
1908 * coding.c (ENCODE_DESIGNATION, decode_eol)
1909 (make_conversion_work_buffer, code_conversion_restore)
1910 (Fdefine_coding_system_internal): Convert Lisp types.
1911 (code_conversion_restore): Use EQ, not ==.
1912 (Fencode_coding_string): Fix code_convert_string call.
1913
1914 * coding.h (code_convert_region): Fix prototype.
1915
1916 * dispextern.h (redraw_frame, redraw_garbaged_frames): Removed.
1917
1918 * fontset.c (fontset_ref, fontset_set, fs_load_font)
1919 (Ffontset_info): Convert Lisp types.
1920
1921 * syntax.h (SYNTAX_ENTRY_INT): Don't use make_number.
1922
1923 * xterm.c (note_mouse_movement): Fix call of window_from_coordinates.
1924
1925 * xdisp.c (display_mode_element): Fix call of Fset_text_properties.
1926
1927 * chartab.c: Include "...h", not <...h> in some cases.
1928
1929 * callproc.c (Fcall_process): Remove unused variables.
1930
1931 2002-07-12 Dave Love <fx@gnu.org>
1932
1933 * coding.c (Fset_coding_system_priority): Allow null arg list.
1934
1935 2002-07-03 Dave Love <fx@gnu.org>
1936
1937 * minibuf.c (Fminibuffer_complete_word): Remove unused var.
1938 (Fself_insert_and_exit): Use CHARACTERP.
1939
1940 * callproc.c (Fcall_process): Remove unused vars.
1941
1942 * xterm.c (XTread_socket): Add extra dead keysyms.
1943
1944 * xdisp.c (decode_mode_spec_coding): Use CHARACTERP.
1945
1946 * dispextern.h: Remove prototypes for redraw_frame,
1947 redraw_garbaged_frames.
1948
1949 * cmds.c (Fself_insert_command): Use CHARACTERP.
1950
1951 * chartab.c (make_sub_char_table): Remove unused var.
1952 (Fset_char_table_default, Fmap_char_table): Doc fix.
1953
1954 * keymap.c (access_keymap): Remove generic char code.
1955 (push_key_description): Use CHARACTERP.
1956
1957 2002-07-01 Dave Love <fx@gnu.org>
1958
1959 * charset.c: Doc fixes.
1960 (Funify_charset): Extra checking.
1961
1962 2002-06-24 Dave Love <fx@gnu.org>
1963
1964 * lread.c: Remove some unused variables.
1965 (safe_to_load_p): If safe, return the magic number version byte.
1966 (Fload): Maybe use load-with-code-conversion.
1967
1968 2002-06-12 Kenichi Handa <handa@etl.go.jp>
1969
1970 * category.c (Fmodify_category_entry): Don't modify the contents
1971 of category_set for characters out of the range. Avoid
1972 unnecessary modification.
1973
1974 * character.h (MAYBE_UNIFY_CHAR): Adjusted for the change of
1975 Vchar_unify_table. The default value of the table is now nil.
1976
1977 * character.c (syms_of_character): Setup Vchar_width_table for
1978 eight-bit-control and raw-byte chars.
1979
1980 * charset.h (enum define_charset_arg_index): Delete
1981 charset_arg_parents and add charset_arg_subset and
1982 charset_arg_superset.
1983 (enum charset_attr_index): Delete charset_parents and add
1984 charset_subset and charset_superset.
1985 (enum charset_method): Delete CHARSET_METHOD_INHERIT and add
1986 CHARSET_METHOD_SUBSET and CHARSET_METHOD_SUPERSET.
1987 (CHARSET_ATTR_PARENTS, CHARSET_PARENTS): Macros deleted.
1988 (CHARSET_ATTR_SUBSET, CHARSET_ATTR_SUPERSET, CHARSET_SUBSET)
1989 (CHARSET_SUPERSET): New macros.
1990 (charset_work): Extern it.
1991 (ENCODE_CHAR): Use charset_work.
1992 (CHAR_CHARSET_P): Adjusted for the change of encoder format.
1993 (map_charset_chars): Extern it.
1994
1995 * charset.c (load_charset_map): Set the default value of encoder
1996 and deunifier char-tables to nil.
1997 (map_charset_chars): Argument changed. Callers changed. Use
1998 map_char_table_for_charset instead of map_char_table.
1999 (Fmap_charset_chars): New optional args from_code and to_code.
2000 (Fdefine_charset_internal): Adjusted for the change of
2001 `define-charset' (:parents -> :subset or :superset).
2002 (charset_work): New variable.
2003 (encode_char): Adjusted for the change of
2004 Fdefine_charset_internal.
2005 (syms_of_charset): Likewise.
2006 (Ffind_charset_string): Setup the vector `charsets' correctly.
2007
2008 * chartab.c (sub_char_table_ref_and_range): New arg defalt. Fix
2009 the previous change.
2010 (char_table_ref_and_range): Adjusted for the above change.
2011 (map_sub_char_table_for_charset): New function.
2012 (map_char_table_for_charset): New function.
2013
2014 * keymap.c (describe_vector): Handle a char-table directly here.
2015 (describe_char_table): Deleted.
2016
2017 * lisp.h (map_charset_chars): Deleted.
2018
2019 2002-06-11 Dave Love <fx@gnu.org>
2020
2021 * fns.c (count_combining): Comment out (unused).
2022 (Flocale_codeset): New.
2023 (syms_of_fns): Defsubr it.
2024
2025 * config.in (HAVE_PTY_H, HAVE_SIZE_T, HAVE_LANGINFO_CODESET): New.
2026 (size_t): Removed.
2027
2028 2002-06-06 Dave Love <fx@gnu.org>
2029
2030 * Makefile.in (chartab.o): Depend on charset.h
2031
2032 2002-06-03 Kenichi Handa <handa@etl.go.jp>
2033
2034 * character.c (syms_of_character): Set the default value of
2035 Vprintable_chars to Qnil.
2036
2037 2002-05-31 Dave Love <fx@gnu.org>
2038
2039 * Makefile.in (lisp, shortlisp): Change indian.elc to indian.el.
2040
2041 2002-05-31 Kenichi Handa <handa@etl.go.jp>
2042
2043 * charset.c (load_charset_map): Handle the case that from < to
2044 correctly.
2045
2046 * coding.c (encode_coding_emacs_mule): Pay attention to raw-8-bit
2047 chars.
2048 (encode_coding_iso_2022): Likewise.
2049 (encode_coding_sjis): Likewise.
2050 (encode_coding_big5): Likewise.
2051 (encode_coding_charset): Likewise.
2052
2053 2002-05-30 Kenichi Handa <handa@etl.go.jp>
2054
2055 * Makefile.in (lisp): Change chinese.elc to chinese.el. They are
2056 not bytecompiled now.
2057 (shortlisp): Likewise.
2058
2059 * charset.c (charset_jisx0201_roman, charset_jisx0208_1978)
2060 (charset_jisx0208): New variables.
2061 (Fdefine_charset_internal): Setup them if appropriate.
2062 (init_charset_once): Initialize them to -1.
2063
2064 * charset.h (charset_jisx0201_roman, charset_jisx0208_1978,
2065 charset_jisx0208): Extern them.
2066
2067 * coding.c (CODING_ISO_FLAG_USE_ROMAN): New macro
2068 (CODING_ISO_FLAG_USE_OLDJIS): New macro.
2069 (CODING_ISO_FLAG_FULL_SUPPORT): Macro definition changed.
2070 (setup_iso_safe_charsets): Fix arguemtns to Fassq.
2071 (DECODE_DESIGNATION): Pay attention to CODING_ISO_FLAG_USE_ROMAN
2072 and CODING_ISO_FLAG_USE_OLDJIS.
2073 (ENCODE_ISO_CHARACTER_DIMENSION1): Likewise.
2074 (ENCODE_ISO_CHARACTER_DIMENSION2): Likewise.
2075 (encode_coding_iso_2022): Change the 1st arg to
2076 ENCODE_ISO_CHARACTER to a variable.
2077
2078 2002-05-29 Kenichi Handa <handa@etl.go.jp>
2079
2080 * charset.h (enum define_charset_arg_index): New enums
2081 charset_arg_min_code and charset_arg_max_code.
2082 (struct charset): New member char_index_offset.
2083
2084 * charset.c (CODE_POINT_TO_INDEX): Take charset->char_index_offset
2085 into account.
2086 (INDEX_TO_CODE_POINT): Likewise.
2087 (Fdefine_charset_internal): Handle args[charset_arg_min_code] and
2088 args[charset_arg_max_code]. Setup charset.char_index_offset.
2089 (syms_of_charset): Fix args to Fdefine_charset_internal.
2090
2091 2002-05-27 Dave Love <fx@gnu.org>
2092
2093 * coding.c (decode_coding_utf_8): Reject overlong sequences.
2094
2095 2002-05-26 Dave Love <fx@gnu.org>
2096
2097 * coding.c: Doc fixes.
2098 (Fcoding_system_aliases): Fix return value.
2099 (Qmac): Remove (duplicated) definition.
2100
2101 2002-05-25 Dave Love <fx@gnu.org>
2102
2103 * charset.c (Fcharset_priority_list, Fset_charset_priority): New
2104 functions.
2105
2106 * character.c (Fstring): Doc fix.
2107
2108 * charset.c (Fdefine_charset_alias): Update Vcharset_list.
2109
2110 * fontset.c (Ffontset_info): Doc fix. Return charset names, not
2111 ids.
2112 (font-encoding-alist): Doc fix.
2113
2114 2002-05-24 Dave Love <fx@gnu.org>
2115
2116 * term.c (costs_set): Declare static, non-initialized for pcc.
2117 (encode_terminal_code): Remove ensued var.
2118
2119 * keyboard.c (kbd_buffer_store_event): Fix interrupt_signal decl
2120 for K&R.
2121
2122 * xterm.c (xlwmenu_window_p): Fix prototype for K&R.
2123
2124 * coding.c (setup_iso_safe_charsets): Fix arg decl for K&R.
2125 (suffixes): Moved out of make_subsidiaries for K&R.
2126
2127 * charset.c (map_charset_chars): Fix c_function declaration for
2128 K&R.
2129
2130 * lisp.h (DEFUN) [!PROTOTYPES]: Remove spurious `args'.
2131
2132 2002-05-23 Dave Love <fx@gnu.org>
2133
2134 * data.c (Fchar_or_string_p): Doc fix. Use CHARACTERP.
2135
2136 * category.c (Fmodify_category_entry): Doc fix. Remove unused
2137 vars.
2138
2139 2002-05-23 Yong Lu <lyongu@asia-infonet.com>
2140
2141 * charset.c (Fdefine_charset_internal): Fix argument to bzero.
2142
2143 * coding.c (Fdefine_coding_system_internal): Fix previous change.
2144 (decode_coding_charset): Workaround for the bug of GCC 2.96.
2145
2146 2002-05-23 Kenichi Handa <handa@etl.go.jp>
2147
2148 * Makefile.in (lisp): Change cyrillic.elc to cyrillic.el,
2149 vietnamese.elc to vietnamese.el. They are not bytecompiled now.
2150 (shortlisp): Likewise.
2151
2152 2002-05-22 Kenichi Handa <handa@etl.go.jp>
2153
2154 * coding.c (decode_coding_charset): Adjusted for the change of
2155 Fdefine_coding_system_internal.
2156 (Fdefine_coding_system_internal): For a coding system of
2157 `charset' type, store a list of charset IDs in
2158 `charset_attr_charset_valids' element of coding attributes.
2159
2160 * charset.c (Fmake_char): Fix previous change.
2161
2162 2002-05-21 Kenichi Handa <handa@etl.go.jp>
2163
2164 * coding.c (ONE_MORE_BYTE_NO_CHECK): Increment consumed_chars.
2165 (emacs_mule_char): New arg src. Delete arg `composition'. Caller
2166 changed. Handle 2-byte and 3-byte charsets correctly.
2167 (DECODE_EMACS_MULE_COMPOSITION_RULE_20): Renamed from
2168 DECODE_EMACS_MULE_COMPOSITION_RULE. Caller changed.
2169 (DECODE_EMACS_MULE_COMPOSITION_RULE_21): New macro.
2170 (DECODE_EMACS_MULE_21_COMPOSITION): Call
2171 DECODE_EMACS_MULE_COMPOSITION_RULE_21. Produce correct annotation
2172 sequence.
2173 (decode_coding_emacs_mule): Handle composition correctly. Rewind
2174 `src' and `consumed_chars' correctly before calling
2175 emacs_mule_char.
2176 (DECODE_COMPOSITION_START): Correctly handle the case of altchar
2177 and alt&rule composition.
2178 (decode_coding_iso_2022): Handle composition correctly.
2179 (init_coding_once): Setup emacs_mule_bytes for private charsets.
2180
2181 * charset.c (Fdefine_charset_internal): Fix bug for the case of
2182 re-defining a charset. If the charset has :emacs-mule-id, setup
2183 emacs_mule_bytes.
2184 (Fmake_char): If CODE1 is nil, use the minimum code of the
2185 charset.
2186
2187 2002-05-20 Kenichi Handa <handa@etl.go.jp>
2188
2189 * coding.c (encode_coding_iso_2022): If coding requires safe
2190 encoding, produce a character specified by
2191 CODING_INHIBIT_CHARACTER_SUBSTITUTION.
2192 (encode_coding_sjis): Likewise.
2193 (encode_coding_big5): Likewise.
2194 (encode_coding_charset): Likewise.
2195
2196 2002-05-17 Dave Love <fx@gnu.org>
2197
2198 * xterm.c (XSetIMValues): Declare.
2199
2200 * process.c: Conditionally include sys/wait.h, pty.h.
2201
2202 * print.c (print_object): Fix print format for 64-bit
2203 systems.
2204
2205 * keyboard.c (modify_event_symbol): Fix print format for 64-bit
2206 systems.
2207
2208 * buffer.c (emacs_strerror): Declare.
2209 (MMAP_ALLOCATED_P, mmap_enlarge, syms_of_buffer): Import changes
2210 from trunk.
2211
2212 * fontset.c (Fclear_face_cache): Declare.
2213 (accumulate_font_info): Commented-out (unused).
2214 (face_for_char, Fset_fontset_font, Ffontset_info): Remove unused
2215 variables.
2216
2217 * character.h (string_escape_byte8): Declare.
2218
2219 * charset.c (load_charset_map, load_charset_map_from_file): Remove
2220 unused vars.
2221 (Fdefine_charset_internal, Fsplit_char, syms_of_charset)
2222 (Fmap_charset_chars): Doc fix.
2223
2224 * coding.c (Vchar_coding_system_table, Qchar_coding_system):
2225 Removed.
2226 (Fset_coding_system_priority, Fset_coding_system_priority)
2227 (Fdefine_coding_system_internal): Doc fix.
2228
2229 2002-05-16 Dave Love <fx@gnu.org>
2230
2231 * s/osf5-0.h (C_SWITCH_SYSTEM) [!__GNUC__]: Remove -nointrinsics.
2232
2233 2002-05-16 Kenichi Handa <handa@etl.go.jp>
2234
2235 * character.c (string_escape_byte8): Make multibyte string with
2236 correct size.
2237
2238 * charset.c (Fmake_char): Delete unnecessary code.
2239
2240 2002-05-14 Kenichi Handa <handa@etl.go.jp>
2241
2242 * xfns.c (x_encode_text): Allocate coding.destination here, and
2243 call encode_coding_object with dst_object Qnil.
2244
2245 * buffer.c (Fset_buffer_multibyte): Convert 8-bit bytes to
2246 multibyte form correctly.
2247
2248 * fontset.c (fs_load_font): Check fontp->full_name (not fontname)
2249 against Vfont_encoding_alist.
2250
2251 * coding.c (Fdecode_sjis_char): Fix typo (0x7F->0xFF). Fix the
2252 handling of charset list.
2253 (encode_coding_iso_2022): Setup coding->safe_charsets in advance.
2254 (decode_coding_object): Move point to coding->dst_pos before
2255 calling post-read-conversion function.
2256 (encode_coding_object): Give correct arguments to
2257 pre-write-conversion. Ignore the return value of
2258 pre-write-conversion function. Pay attention to the case that
2259 pre-write-conversion changes the current buffer. If dst_object is
2260 Qt, even if coding->src_bytes is zero, allocate at least one byte
2261 to coding->destination.
2262
2263 * coding.h (JIS_TO_SJIS): Fix typo (j1->s1, j2->s2).
2264
2265 * charset.c (Fmake_char): Make it more backward compatible.
2266 (Fmap_charset_chars): Fix docstring.
2267
2268 2002-05-13 Dave Love <fx@gnu.org>
2269
2270 * coding.c: Doc fixes.
2271 (Fdefine_coding_system_alias): Use names, not symbols, in
2272 coding-system-alist.
2273
2274 2002-05-13 Kenichi Handa <handa@etl.go.jp>
2275
2276 * fontset.c (free_realized_fontsets): Call Fclear_face_cache instead
2277 of calling free_realized_face.
2278
2279 2002-05-10 Yong Lu <lyongu@asia-infonet.com>
2280
2281 * charset.c (load_charset_map): Fix previous change.
2282 (read_hex): Don't treat SPC as a comment starter.
2283 (decode_char): If CODE_POINT_TO_INDEX retruns -1, always return
2284 -1.
2285 (Fdecode_char): Fix typo.
2286
2287 2002-05-10 Kenichi Handa <handa@etl.go.jp>
2288
2289 * charset.h (struct charset): New member `code_space_mask'.
2290
2291 * coding.c (coding_set_source): Delete the local variable
2292 beg_byte.
2293 (encode_coding_charset): Delete the local variable charset.
2294 (Fdefine_coding_system_internal): Likewise.
2295 (Fdefine_coding_system_internal): Setup
2296 attrs[coding_attr_charset_valids] correctly.
2297
2298 * charset.c (CODE_POINT_TO_INDEX): Utilize `code_space_mask'
2299 member to check if CODE is valid or not.
2300 (Fdefine_charset_internal): Initialize `code_space_mask' member.
2301 (encode_char): Before calling CODE_POINT_TO_INDEX, check if CODE
2302 is within the range of charset->min_code and carset->max_code.
2303
2304 2002-05-09 Dave Love <fx@gnu.org>
2305
2306 * syntax.h (syntax_temp) [!__GNUC__]: Declare.
2307
2308 * dispextern.h (generate_ascii_font): Fix return type.
2309
2310 * xfaces.c (generate_ascii_font): Fix arg declaration.
2311
2312 * coding.c (coding_inherit_eol_type)
2313 (Fset_terminal_coding_system_internal)
2314 (Fset_safe_terminal_coding_system_internal): Fix arg declarations.
2315
2316 2002-05-08 Kenichi Handa <handa@etl.go.jp>
2317
2318 * coding.c (decode_coding_charset, encode_coding_charset): Handle
2319 multiple charsets correctly.
2320
2321 2002-05-07 Kenichi Handa <handa@etl.go.jp>
2322
2323 * search.c (boyer_moore): Fix handling of mulitbyte character
2324 translation.
2325
2326 * xdisp.c (display_mode_element): When the variable `elt' is
2327 changed, update `this' and `lisp_string'.
2328
2329 2002-05-07 Kenichi Handa <handa@etl.go.jp>
2330
2331 * buffer.c (Fset_buffer_multibyte): Fix 8-bit char handling.
2332
2333 * callproc.c (Fcall_process): Be sure to give the current buffer
2334 to decode_coding_c_string. Update PT and PT_BYTE after the
2335 insertion.
2336
2337 * charset.c (struct charset_map_entries): New struct.
2338 (load_charset_map): Renamed from parse_charset_map. New args
2339 entries and n_entries. Caller changed.
2340 (load_charset_map_from_file): Renamed from load_charset_map.
2341 Caller changed. New arg control_flag. Call load_charset_map at
2342 the tail.
2343 (load_charset_map_from_vector): New function.
2344 (Fdefine_charset_internal): Setup charset.compact_codes_p.
2345 (encode_char): If the charset is compact, change a character index
2346 to a code point.
2347
2348 * coding.c (coding_alloc_by_making_gap): Check the case that the
2349 source and destination are the same correctly.
2350 (decode_coding_raw_text): Set coding->consumed_char and
2351 coding->consumed to 0.
2352 (produce_chars): If coding->chars_at_source is nonzero, update
2353 coding->consumed_char and coding->consumed before calling
2354 alloc_destination.
2355 (Fdefine_coding_system_alias): Register ALIAS in
2356 Vcoding_system_alist.
2357 (syms_of_coding): Define `no-convesion' coding system at the tail.
2358
2359 * fileio.c (Finsert_file_contents): Set coding_system instead of
2360 val. If the current buffer is multibyte, always call
2361 decode_coding_gap.
2362
2363 * xfaces.c (try_font_list): Give higher priority to fontset's
2364 family than face's family.
2365
2366 2002-04-18 Kenichi Handa <handa@etl.go.jp>
2367
2368 * callproc.c (Fcall_process): Be sure to give the current buffer
2369 to decode_coding_c_string.
2370
2371 * xfaces.c (try_font_list): Give a family specified in a fontset
2372 higher priority than a family specified in a face.
2373
2374 2002-04-09 Kenichi Handa <handa@etl.go.jp>
2375
2376 * fileio.c (Finsert_file_contents): Fix calculation of `inserted'.
2377 Fix arguments to insert_from_buffer.
2378
2379 * xdisp.c (display_mode_element): Fix calculation of `bytepos'.
2380
2381 2002-03-11 Kenichi Handa <handa@etl.go.jp>
2382
2383 * coding.c (produce_chars): Set the variable `multibytep' correctly.
2384 (decode_coding_gap): Set coding->dst_multibyte correctly.
2385
2386 2002-03-07 Kenichi Handa <handa@etl.go.jp>
2387
2388 * coding.c (encode_coding_utf_8): Initialize produced_chars to 0.
2389 (decode_coding_utf_16): Fix converting high and low bytes to
2390 code-point.
2391 (encode_coding_utf_16): Substitute coding->default_char for
2392 non-Unicode characters.
2393 (decode_coding): Don't call record_insert here.
2394 (setup_coding_system): Initialize `surrogate' of
2395 coding->spec.utf_16 to 0.
2396 (EMIT_ONE_BYTE): Fix for multibyte case.
2397
2398 * insdel.c (insert_from_gap): Call record_insert.
2399
2400 2002-03-04 Kenichi Handa <handa@etl.go.jp>
2401
2402 * casefiddle.c (casify_region): Fix multibyte case.
2403
2404 * character.c (c_string_width): Add return type `int'.
2405 (char_string_with_unification): Arg ADVANCED deleted.
2406
2407 * character.h (CHAR_VALID_P): Don't call CHARACTERP.
2408 (CHAR_STRING): Adjusted for the change of
2409 char_string_with_unification.
2410 (CHAR_STRING_ADVANCE): Make it do-while statement.
2411
2412 * chartab.c (sub_char_table_set_range): Optimized for the case
2413 DEPTH == 3. Add workaround code for a GCC optimization bug.
2414
2415 * charset.c (parse_charset_map): Remove an unused variable.
2416
2417 * coding.c: Delete unused variables.
2418
2419 * fileio.c (Finsert_file_contents): Set coding_system to Qnil
2420 earlier. If inserted is zero and the coding system doesn't
2421 require flushing, don't call decode_coding_gap.
2422
2423 * syntax.h (SET_RAW_SYNTAX_ENTRY): Don't call make_number.
2424
2425 2002-03-01 Kenichi Handa <handa@etl.go.jp>
2426
2427 The following changes are for using Unicode as an internal
2428 character model, and use UTF-8 format for buffer/string
2429 representation.
2430
2431 * .gdbinit (xchartable): Adjusted for the change of char table
2432 structure.
2433 (xsubchartable, xcoding, xcharset, xcurbuf): New commands.
2434
2435 * Makefile.in (obj): Add character.o and chartab.o.
2436 (lisp, shortlisp): Remove utf-8.elc:
2437 (*.o): For many files, change dependency on charset.h to
2438 character.h, and add dependency on character.h.
2439 (character.o, chartab.o): New targets.
2440
2441 * abbrev.c, bytecode.c, casefiddle.c, cmds.c, dispnew.c, doc.c,
2442 doprnt.c, dosfns.c, frame.c, marker.c, minibuf.c, msdos.c,
2443 w16select.c, w32bdf.c, w32console.c: Include "character.h" instead
2444 of "charset.h".
2445
2446 * dired.c, filelock.c: Include "character.h".
2447
2448 * alloc.c: Include "character.h" instead of "charset.h".
2449 (Fmake_char_table): Moved to chartab.c.
2450 (make_sub_char_table): Likewise.
2451 (syms_of_alloc): Remove defsubr for Smake_char_table.
2452
2453 * buffer.c: Include "character.h" instead of "charset.h", don't
2454 include "coding.h".
2455 (Fset_buffer_multibyte): Adjuted for UTF-8.
2456
2457 * buffer.h: EXFUN Fbuffer_live_p.
2458
2459 * callproc.c: Include "character.h" instead of "charset.h".
2460 (Fcall_process): Big change for the new code-conversion APIs.
2461
2462 * casetab.c: Include "character.h" instead of "charset.h".
2463 (set_canon, set_identity, shuffle): Adjusted for the new
2464 map_char_table spec.
2465 (init_casetab_once): Call CHAR_TABLE_SET instead of directly
2466 accessing the char table structure.
2467
2468 * chartab.c: New file that implements char table.
2469
2470 * category.c: Include "character.h".
2471 (copy_category_entry): New function.
2472 (copy_category_table): Call map_char_table and copy_category_entry.
2473 (Fmake_category_table): Initialize all top-vel slots.
2474 (char_category_set): New function.
2475 (modify_lower_category_set): Deleted.
2476 (Fmodify_category_entry): Call char_table_ref_and_range.
2477
2478 * category.h (CATEGORY_SET): Just call char_category_set.
2479
2480 * ccl.c: Include "character.h".
2481 (Qccl, Qcclp): New variables.
2482 (CCL_WRITE_CHAR): Alway treat the arg CH as a character even if
2483 it's less than 256.
2484 (CCL_WRITE_MULTIBYTE_CHAR): Deleted.
2485 (CCL_WRITE_STRING, CCL_READ_CHAR): Adjusted for the change of SRC
2486 and DST type.
2487 (ccl_driver): Types of arguments changed. Code adjusted for that.
2488 (Fccl_execute, Fccl_execute_on_string): Adjusted for the change of
2489 ccl_driver.
2490 (syms_of_ccl): Intern and staticpro Qccl and Qcclp.
2491
2492 * ccl.h (struct ccl_program): Members eol_type and multibyte
2493 deleted. New members src_multibyte, dst_multibyte, consumed, and
2494 produced.
2495 (struct ccl_spec): Members decoder and encoder deleted. New
2496 memeber ccl.
2497 (CODING_SPEC_CCL_PROGRAM): New macro.
2498 (ccl_driver): Prototype updated.
2499 (Qccl, Qcclp, Fccl_program_p): Extern them.
2500 (CHECK_CCL_PROGRAM): New macro.
2501
2502 * character.c, character.h, chartab.c: New files.
2503
2504 * charset.c: Mostly re-written. Character and multibyte sequence
2505 handling codes are moved to character.c.
2506
2507 * charset.h: Mostly re-written. Character and multibyte sequence
2508 handling codes are moved to character.h.
2509
2510 * coding.c, coding.h: Mostly re-written.
2511
2512 * composite.c: Include "character.h" instead of "charset.h".
2513 (CHAR_WIDTH): Moved to character.h.
2514 (HASH_KEY, HASH_VALUE): Deleted.
2515
2516 * composite.h (enum composition_method): Order of enumeration
2517 symbols changed.
2518
2519 * data.c: Include "character.h" instead of "charset.h".
2520 (Faref): Call CHAR_TABLE_REF for a char table.
2521 (Faset): Call CHAR_TABLE_SET for a char table.
2522
2523 * dispextern.h (free_realized_face, check_face_attribytes,
2524 generate_ascii_font): Extern them.
2525 (free_realized_multibyte_face): Extern deleted.
2526
2527 * disptab.h (DISP_CHAR_VECTOR): Adjusted for the change of char
2528 table structure.
2529
2530 * editfns.c: Include "character.h" instead of "charset.h".
2531 (Fchar_to_string): Always call CHAR_STRING.
2532
2533 * emacs.c (main): Call init_charset_once, init_charset,
2534 syms_of_chartab, and syms_of_character.
2535
2536 * fileio.c: Include "character.h" instead of "charset.h".
2537 (Finsert_file_contents): Big change for the new code-conversion
2538 API.
2539 (choose_write_coding_system): Likewise.
2540 (Fwrite_region): Likewise.
2541 (build_annotations_2): Deleted.
2542 (e_write): Big change for the new code-conversion API.
2543
2544 * fns.c: Include "character.h" instead of "charset.h".
2545 (copy_sub_char_table): Moved to chartab.c.
2546 (Fcopy_sequence): Call copy_char_table for a char table.
2547 (concat): Delete codes calling count_multibyte.
2548 (string_char_to_byte): Adjusted for the new multibyte form.
2549 (string_byte_to_char): Likewise.
2550 (internal_equal): Adjusted for the change of char table structure.
2551 (Fchar_table_subtype, Fchar_table_parent, Fset_char_table_parent,
2552 Fchar_table_extra_slot, Fset_char_table_extra_slot,
2553 Fchar_table_range, Fset_char_table_range, Fset_char_table_default,
2554 char_table_translate, optimize_sub_char_table,
2555 Foptimize_char_table, map_char_table, Fmap_char_table): Moved to
2556 chartab.c.
2557 (char_table_ref_and_index): Deleted.
2558 (HASH_KEY, HASH_VALUE): Moved to lisp.h.
2559 (Fmd5): Call preferred_coding_system instead of accessing
2560 Vcoding_category_list. Adjusted for the new code-conversion API.
2561 (syms_of_fns): Defsubr for char table related functions moved to
2562 chartab.c.
2563
2564 * fontset.c: Mostly re-written.
2565
2566 * fontset.h (struct font_info): Type of the member encoding_type
2567 changed.
2568 (enum FONT_SPEC_INDEX): New enum.
2569 (fontset_font_pattern, fs_load_font): Prototype updated.
2570 (FS_LOAD_FONT): Adjusted for the change of fs_load_font.
2571
2572 * indent.c: Include "character.h" instead of "charset.h".
2573 (MULTIBYTE_BYTES_WIDTH): Call CHAR_WIDTH instead of
2574 WIDTH_BY_CHAR_HEAD.
2575
2576 * insdel.c: Include "character.h" instead of "charset.h".
2577 (copy_text): Don't refer to Vnonascii_translation_table.
2578 (insert_from_gap): New function.
2579
2580 * keyboard.c: Include "character.h" instead of "charset.h".
2581 (command_loop_1): Never call direct_output_forward_char before
2582 a non-ASCII character.
2583 (read_char): If Vkeyboard_translate_table is a char table, always
2584 translated a character.
2585
2586 * keymap.c: Include "character.h".
2587 (store_in_keymap): Handle the case that IDX is a cons.
2588 (Fdefine_key): Handle the case that KEY is a cons and the car part
2589 is also a cons (range).
2590 (push_key_description): Adjusted for the new character code.
2591 (describe_vector): Call describe_char_table for a char table.
2592 (describe_char_table): New function.
2593
2594 * keymap.h (describe_char_table): Extern it.
2595
2596 * lisp.h (enum pvec_type): New member PVEC_SUB_CHAR_TABLE.
2597 (XSUB_CHAR_TABLE, XSETSUB_CHAR_TABLE): New macros.
2598 (CHAR_TABLE_ORDINARY_SLOTS, CHAR_TABLE_SINGLE_BYTE_SLOTS,
2599 SUB_CHAR_TABLE_ORDINARY_SLOTS, SUB_CHAR_TABLE_STANDARD_SLOTS):
2600 Deleted.
2601 (CHAR_TABLE_REF, CHAR_TABLE_SET): Adjusted for the new char table
2602 structure.
2603 (CHAR_TABLE_TRANSLATE): Just call char_table_translate.
2604 (CHARTAB_SIZE_BITS_0, CHARTAB_SIZE_BITS_1, CHARTAB_SIZE_BITS_2,
2605 CHARTAB_SIZE_BITS_3): New macros.
2606 (chartab_size): Extern it.
2607 (struct Lisp_Char_Table): Re-designed.
2608 (struct Lisp_Sub_Char_Table): New structure.
2609 (HASH_KEY, HASH_VALUE): Moved from fns.c.
2610 (CHARACTERBITS): Defined as 22.
2611 (GLYPH_MASK_FACE, GLYPH_MASK_CHAR): Adjusted for the above change.
2612 (SUB_CHAR_TABLE_P): Check PVEC_CHAR_TABLE.
2613 (GC_SUB_CHAR_TABLE_P): New macro.
2614 (Fencode_coding_string, Fdecode_coding_string): EXFUN Updated.
2615 (code_convert_string_norecord): Extern deleted.
2616 (init_character_once, syms_of_character, init_charset,
2617 syms_of_composite, Qeq, Fmakehash, insert_from_gap): Extern them.
2618
2619 * lread.c: Include "character.h".
2620 (read_multibyte): New arg NBYTES.
2621 (read_escape): The meaning of returned *BYTEREP changed.
2622 (to_multibyte): Deleted.
2623 (read1): Adjuted the handling of char table and string.
2624
2625 * print.c: Include "character.h" instead of "charset.h".
2626 (print_string): Convert 8-bit raw bytes to octal form by
2627 string_escape_byte8.
2628 (print_object): Adjusted for the new multibyte form. Print 8-bit
2629 raw bytes always in octal form. Handle sub char table correctly.
2630
2631 * process.c: Include "character.h" instead of "charset.h".
2632 (read_process_output): Adjusted for the new code-conversion API.
2633 (send_process): Likewise.
2634
2635 * puresize.h (BASE_PURESIZE): Increased.
2636
2637 * regex.c: Include "character.h" instead of "charset.h".
2638 (BYTE8_TO_CHAR, CHAR_BYTE8_P) [not emacs]: New dummy macros.
2639 (regex_compile): Accept a range whose starting and ending
2640 character have different leading bytes.
2641 (analyse_first): Adjusted for the above change.
2642
2643 * search.c: Include "character.h" instead of "charset.h".
2644 (search_buffer, boyer_moore): Adjusted for the new multibyte form.
2645 (Freplace_match): Adjusted for the change of
2646 multibyte_char_to_unibyte.
2647
2648 * syntax.c: Include "character.h" instead of "charset.h".
2649 (syntax_parent_lookup): Deleted.
2650 (Fmodify_syntax_entry): Accept a cons as CHAR.
2651 (skip_chars): Adjusted for the new multibyte form.
2652 (init_syntax_once): Call char_table_set_range instead of directly
2653 accessing the structure of a char table.
2654
2655 * syntax.h (SET_RAW_SYNTAX_ENTRY): Call CHAR_TABLE_SET.
2656 (SYNTAX_ENTRY_FOLLOW_PARENT): Macro deleted.
2657 (SET_RAW_SYNTAX_ENTRY_RANGE): New macro.
2658 (SYNTAX_ENTRY_INT): Call CHAR_TABLE_REF.
2659
2660 * term.c: Include "buffer.h" and "character.h".
2661 (encode_terminal_code): Adjusted for the new code-conversion API.
2662 (write_glyphs): Likewise.
2663 (produce_glyphs): Call CHAR_WIDTH instead of CHARSET_WIDTH.
2664
2665 * w32term.c (x_new_font): Adjusted for the change of FS_LOAD_FONT.
2666
2667 * xdisp.c: Include "character.h".
2668 (get_next_display_element): Adjusted for the new multibyte form.
2669 (disp_char_vector): Adjusted for the new char table structure.
2670 (decode_mode_spec_coding): Adjusted for the new structure of
2671 coding system.
2672 (decode_mode_spec): Adjusted for the new code-conversion API.
2673
2674 * xfaces.c: Include "character.h" instead of "charset.h".
2675 (load_face_font): Adjusted for the change of choose_face_font and
2676 FS_LOAD_FONT.
2677 (generate_ascii_font): New function.
2678 (set_lface_from_font_name): Adjusted for the change of
2679 FS_LOAD_FONT.
2680 (set_font_frame_param): Adjusted for the change of
2681 choose_face_font.
2682 (free_realized_face): Make it public.
2683 (free_realized_faces_for_fontset): Renamed from
2684 free_realized_multibyte_face. Free also faces realized for ASCII.
2685 (choose_face_font): Argments changed. Adjusted for the change of
2686 fontset_font_pattern and FS_LOAD_FONT.
2687
2688 * xfns.c: Include "character.h".
2689 (x_encode_text): Adjusted for the new code-conversion API.
2690
2691 * xselect.c: Don't include "charset.h".
2692 (selection_data_to_lisp_data): Adjusted for the new code
2693 covnersion API.
2694
2695 * xterm.c: Include "character.h".
2696 (x_encode_char): New argument CHARSET. Caller changed.
2697 (x_get_char_face_and_encoding): Call ENCODE_CHAR instead of
2698 SPLIT_CHAR.
2699 (x_get_glyph_face_and_encoding): Likewise.
2700 (x_produce_glyphs): Don't check Vnonascii_translation_table Call
2701 CHAR_WIDTH instead of CHARSET_WIDTH.
2702 (XTread_socket): Adjusted for the new code-conversion API.
2703 (x_new_font): Adjusted for the change of FS_LOAD_FONT.
2704 (x_load_font): Adjusted for the change of struct font.
2705
2706 ;; Local Variables:
2707 ;; coding: iso-2022-7bit
2708 ;; End:
2709
2710 Copyright (C) 2002 Free Software Foundation, Inc.
2711 Copying and distribution of this file, with or without modification,
2712 are permitted provided the copyright notice and this notice are preserved.