Commit graph

9508 commits

Author SHA1 Message Date
Karl Heuer
8c21764540 (Fbase64_decode_region, Fbase64_decode_string):
Do free malloc'd memory even in case of failure.
Use xfree, not free.
(Fbase64_encode_region, Fbase64_encode_string):
Use xfree, not free.
(base64_decode_1): Don't fail for short lines.
1998-12-16 06:32:39 +00:00
Kenichi Handa
d366d2e41b (printchar): Outputting multibyte characters
to echo area always makes it multibyte.
1998-12-15 10:41:44 +00:00
Kenichi Handa
c7e3eb8b1b (printchar): Cancel previous change. 1998-12-15 10:38:40 +00:00
Kenichi Handa
edf496dd13 Include "ccl.h".
(Fcall_process): Doc-string modified.  Set CODING_MODE_LAST_BLOCK
bit in argument_coding.mode to tell encoding procedure to flush
data.  While encoding arguments, if argument_coding uses CCL
program, initialize it again after encoding.
(Fcall_process_region): Doc-string modified.  Handle the case that
NARGS is 3.
1998-12-15 04:35:38 +00:00
Kenichi Handa
ad3d1b1d67 (CCL_SUCCESS): Don't set ccl->ic.
(ccl_driver) <CCL_End>: Pretend that all source text is consumed.
Set `ic' to the head of this command.
(ccl_driver) <CCL_ReadMultibyteChar2>: Return a single byte 8-bit
code for an invalid code.
(setup_ccl_program): If the arg VEC is nil, skip setting ups
based on VEC.
1998-12-15 04:35:38 +00:00
Kenichi Handa
0282eb6915 (Qunknown): New variable.
(init_charset_once): Intern and staticpro Qunknown.  Initialize
all elements of Vcharset_symbol_table to Qunknown.
(find_charset_in_str): New arg MULTIBYTE.  If it is zero, check
unibyte characters only.  For an invalid composition sequence, set
CHARSETS[1] to 1.
(Ffind_charset_region): Call find_charset_in_str with an
appropriate MULTIBYTE arg.  If undefined charsets are found,
include `unknown' is the return value.
(Ffind_charset_string): Likewise.
(Fsplit_char): If CHAR is invalid, return `(unknown CHAR)'.
(str_cmpchar_id): Max composite character code should be less than
GENERIC_COMPOSITION_CHAR.
1998-12-15 04:35:38 +00:00
Kenichi Handa
8c5b01cc4b (find_charset_in_str): Update declaration. 1998-12-15 04:35:38 +00:00
Kenichi Handa
944bd42004 (DECODE_DESIGNATION): Jump to label_invalid_code if
final_char is invalid.
(decode_coding): If coding->type is coding_type_ccl, call
ccl_coding_driver even if SRC_BYTES is zero.
(code_convert_region): Update `inserted' correctly after calling
coding->post_read_conversion.  Even after the code converter
consumed all source text, call it once more if it is
coding_type_ccl to flush out data.
1998-12-15 04:35:38 +00:00
Kenichi Handa
02a08df0ab (printchar): When outputting a multibyte character to
echo area, always set message_enable_multibyte to 1.
1998-12-15 04:35:38 +00:00
Kenichi Handa
de7fbd0989 (read_process_output): If NBYTES is zero and
CODING_MODE_LAST_BLOCK bit is not yet set in coding->mode, set it
and try decoding again.
(Fprocess_send_eof): If the coding system of PROCESS
requires flushing, call send_process with null-string at first.
1998-12-15 04:35:38 +00:00
Kenichi Handa
c91beee236 (Finsert_file_contents): Even if INSERTED is zero, if
CODING is handled by CCL program, call code_convert_region.
1998-12-15 04:35:38 +00:00
Kenichi Handa
67bfe42d76 (string_char_to_byte): Handle invalid multibyte sequence
correctly.
(string_byte_to_char): Likesize.
1998-12-15 04:35:38 +00:00
Kenichi Handa
040272ceb2 (search_buffer): Don't use Boyer-Moore
to search for an invalid multibyte code.
In unibyte case, no need to check whether there are translations
in more than one charset; just set charset_base to 0.
1998-12-15 04:35:38 +00:00
Kenichi Handa
42912be360 (Fw16_set_clipboard_data): Call find_charset_in_str
with MULTIBYTE arg 0.
1998-12-15 04:35:38 +00:00
Kenichi Handa
2798f18161 (Fw32_set_clipboard_data): Call find_charset_in_str
with MULTIBYTE arg 0.
1998-12-15 04:35:38 +00:00
Kenichi Handa
666273c2f0 (lisp_data_to_selection_data): Call find_charset_in_str
with MULTIBYTE arg 0.
1998-12-15 04:35:38 +00:00
Geoff Voelker
dabe36a823 (LOCALTIME_CACHE): Define. 1998-12-10 06:41:00 +00:00
Geoff Voelker
4f8ac0b2d6 (w32_get_long_filename): Handle root dirs correctly. 1998-12-10 05:43:07 +00:00
Karl Heuer
b283f79ec7 Doc fixes. 1998-12-10 04:25:07 +00:00
Karl Heuer
4468c4f1cf (insert_from_buffer_1): Properly count the size
of output from conversion to multibyte even when input
is split across the gap.
1998-12-10 03:19:37 +00:00
Karl Heuer
d18b62f211 (re_compile_fastmap): For anychar, set all fastmap
elements for all possible unibyte chars (except newline).
1998-12-10 03:09:12 +00:00
Karl Heuer
620e6ddb8c (C_SWITCH_SYSTEM) [!__GNUC__]: Increase space. 1998-12-10 02:52:20 +00:00
Geoff Voelker
c0ca703bd4 (Fw32_get_clipboard_data): Do not delete isolated CR
characters, only convert CRLF to LF.
1998-12-09 00:03:09 +00:00
Geoff Voelker
9c148db6a3 Do string comparision of _NMAKE_VER. 1998-12-08 23:56:14 +00:00
Eli Zaretskii
aa9ce93672 (Vdos_unsupported_char_glyph): New variable.
(syms_of_msdos): DEFVAR_LISP it.
(IT_insert_glyphs, IT_delete_glyphs): New functions which abort
Emacs.
(internal_terminal_init): Set up insert_glyphs_hook and
delete_glyphs_hook to call them.  Explicitly set char_ins_del_ok
to 0.
(unibyte_display_via_language_environment): New variable.
(syms_of_msdos): Devfar it.
(IT_write_glyphs): Honor glyph aliasing via Vglyph_table.
Encode the character codes of the glyphs according to the
terminal_coding in effect.
1998-12-06 15:57:48 +00:00
Eli Zaretskii
d24422702f (msdos.o): Depend on termchar.h, charset.h, coding.h, and disptab.h 1998-12-06 15:55:59 +00:00
Andreas Schwab
c3161ec382 (Fstring_as_unibyte): Doc fix. 1998-12-04 09:50:31 +00:00
Eli Zaretskii
06b1ea1321 (init_environment): Record the time we started up.
(IT_reset_terminal_modes): Don't restore the screen if we exit too
fast after startup (aka crash).
1998-12-03 09:41:48 +00:00
Eli Zaretskii
6f855d6452 (dos_cleanup): Flush and fsync the termscript stream. 1998-12-03 09:41:09 +00:00
Andreas Schwab
c2d1e590cf Declare char_valid_p. 1998-12-03 09:22:52 +00:00
Geoff Voelker
a0b9c8385f (check_windows_init_file): Use decode_env_path when
using EMACSLOADPATH.
1998-12-03 03:14:46 +00:00
Geoff Voelker
19589637fa (FONT_MAX_WIDTH): New macro. 1998-12-03 00:06:26 +00:00
Geoff Voelker
feba565d2a (dumpglyphs): Use unsigned char arrays.
Use FONT_MAX_WIDTH to detect and fudge proportional fonts
for various languages.
Compensate for fonts that have underhangs (e.g., Thai).
1998-12-03 00:06:03 +00:00
Geoff Voelker
93066bc2ab (WM_EMACS_TOGGLE_LOCK_KEY): New define. 1998-12-02 23:54:30 +00:00
Geoff Voelker
9ddef9c4de (key_event): Use Vw32_phantom_key_code. Undo the
mapping of Ctrl-Pause into cancel, and Ctrl-NumLock into pause.
(w32_console_toggle_lock_key): New function.
1998-12-02 23:54:14 +00:00
Geoff Voelker
adcc38092f (Vw32_phantom_key_code): New variable.
(Qhyper, Qsuper, Qmeta, Qalt, Qctrl, Qcontrol, Qshift): New
variables.
(syms_of_w32fns): Init and register them.
(reset_modifiers): Use a more precise test for whether Emacs has
keyboard focus.  Synchronize state of all keys that can be used as
modifiers, to overcome problems arising from hot-keys.
(w32_key_to_modifier): Be careful not to call intern() to avoid
requiring thread synchronization.
(w32_msg_pump): Handle new WM_EMACS_TOGGLE_LOCK_KEY message.
(w32_wnd_proc): Ensure lock key indicator lights are updated
promptly on Windows 9x, by passing key events on to the system.
(w32_wnd_proc): Use Vw32_phantom_key_code to stop system
responding to Windows key events when not wanted.
(w32_wnd_proc): Undo the mapping of Ctrl-Pause into cancel and
Ctrl-NumLock into pause by the system.
(w32_wnd_proc): Don't translate key combinations containing any
modifiers other than shift (and capslock).
(w32_wnd_proc): Reset modifier key states when receiving focus (we
can't determine the key states until we have keyboard focus).
(Fw32_toggle_lock_key): New function.
(syms_of_w32fns): Defsubr it.
1998-12-02 23:52:47 +00:00
Geoff Voelker
83c75055bc (w32_last_error): Fix cut+paste error. 1998-12-02 23:00:29 +00:00
Geoff Voelker
dba46b7c5d termhooks.h (event_kind) [WINDOWSNT]: Define
language_change_event.
1998-12-02 23:00:14 +00:00
Geoff Voelker
501d50943c (parse_modifiers): Declare prototype. 1998-12-02 23:00:02 +00:00
Geoff Voelker
1161d3675c (Qlanguage_change): New variable.
(syms_of_keyboard): Init it.
(kbd_buffer_get_event) [WINDOWSNT]: Generate language-change
events.
(lispy_function_keys) [HAVE_NTGUI]: Remove names for modifier
keys; add name for Escape key; extend to 256 elements.
(parse_modifiers): Make non-static.
1998-12-02 22:59:11 +00:00
Richard M. Stallman
2cbebefb27 (Qouter_window_id): New variable.
(syms_of_xfns): Initialize it.
(x_report_frame_params): Set up outer-window-id parameter.
1998-12-02 18:06:37 +00:00
Richard M. Stallman
9160906f27 (Freplace_match): Set OPOINT clearly for the case
where point is in the middle of the text to be replaced.
1998-12-01 05:17:11 +00:00
Richard M. Stallman
ffa286a2aa (display_text_line): When handling HPOS < 0 after loop,
if compute_motion fails to advance at all, don't back it up.
1998-11-30 06:35:33 +00:00
Richard M. Stallman
f49770515b (Fsingle_key_description): Fix previous change. 1998-11-28 22:16:09 +00:00
Richard M. Stallman
f4e09ae710 (Fstring_as_unibyte, Fstring_as_multibyte):
Clear text properties in the new string.
1998-11-27 22:15:38 +00:00
Kenichi Handa
6f39b7c89b (Frequire): Update declaration. 1998-11-26 08:37:32 +00:00
Kenichi Handa
9b0ca86943 (ccl_driver) <CCL_TranslateCharacter>: Don't suppress MSB
if the charset is ascii.
(ccl_driver) <CCL_TranslateCharacterConstTbl>: Likewise.
1998-11-26 08:12:12 +00:00
Kenichi Handa
8ac5a9ccbe (non_ascii_char_to_string): If C has modifier bits,
make an appropriate one byte string.
(char_bytes): Handle the case that C is a single byte char or has
modifier bits.
1998-11-26 08:12:12 +00:00
Kenichi Handa
43229ac34b (CHAR_BYTES): If C has modifier bits, return 1. 1998-11-26 08:12:12 +00:00
Kenichi Handa
741263c22b (internal_self_insert): If C has modifier bits, insert
appropriate one byte char.
1998-11-26 08:12:12 +00:00