Commit graph

386 commits

Author SHA1 Message Date
Kim F. Storm
7f2646c96c (Fsafe_get): New function.
(syms_of_fns): Defsubr it.
2005-04-19 08:34:19 +00:00
Lute Kamstra
7aed223df9 (Vloads_in_progress): Remove extern.
(load_in_progress): Add extern.
(Frequire): Use load_in_progress instead of Vloads_in_progress.
2005-04-18 10:20:46 +00:00
Stefan Monnier
862779db9d (Fstring_as_multibyte, Fstring_to_multibyte): Docstring fixes. 2005-04-10 19:02:24 +00:00
Richard M. Stallman
9d5c2e7e2c (Vloads_in_progress): Add extern.
(Frequire): Don't do LOADHIST_ATTACH if Vloads_in_progress is nil.
2005-04-10 00:28:00 +00:00
Kim F. Storm
d278cde036 (sweep_weak_table): Advance prev pointer when we keep a pair. 2005-01-19 00:08:30 +00:00
Richard M. Stallman
5ba8f83ded (Frequire): Record in load-history unconditionally. 2005-01-12 05:03:22 +00:00
Steven Tamm
b15325b22a * dispextern.h: Change HAVE_CARBON to MAC_OS.
(struct glyph_string): Likewise.
* emacs.c (main) [MAC_OS8]: Call mac_term_init instead of
	mac_initialize.
* fileio.c (Fnext_read_file_uses_dialog_p, Fread_file_name):
	Change TARGET_API_MAC_CARBON to HAVE_CARBON.
* fns.c (vector): Change MAC_OSX to MAC_OS.
* frame.c (x_set_frame_parameters, x_report_frame_params)
	(x_set_fullscreen): Remove #ifndef HAVE_CARBON.
	(x_set_border_width, Vdefault_frame_scroll_bars): Change
	HAVE_CARBON to MAC_OS.
* image.c [MAC_OS]: Include sys/stat.h.
	[MAC_OS && !MAC_OSX]: Include sys/param.h, ImageCompression.h, and
	QuickTimeComponents.h.
* mac.c [!MAC_OSX] (mac_wait_next_event): Add extern.
	[!MAC_OSX] (select): Use mac_wait_next_event.
	[!MAC_OSX] (run_mac_command): Change EXEC_SUFFIXES to
	Vexec_suffixes.
	[!MAC_OSX] (select, run_mac_command): Change `#ifdef
	TARGET_API_MAC_CARBON' to `#if TARGET_API_MAC_CARBON'.
	(mac_clear_font_name_table): Add extern.
	(Fmac_clear_font_name_table): New defun.
	(syms_of_mac): Defsubr it.
	[MAC_OSX] (SELECT_POLLING_PERIOD_USEC): New define.
	[MAC_OSX] (select_and_poll_event): New function.
	[MAC_OSX] (sys_select): Use it.
	[MAC_OSX && SELECT_USE_CFSOCKET] (socket_callback): New function.
	[MAC_OSX && SELECT_USE_CFSOCKET]
	(SELECT_TIMEOUT_THRESHOLD_RUNLOOP, EVENT_CLASS_SOCK): New defines.
	[MAC_OSX] (sys_select) [SELECT_USE_CFSOCKET]: Use CFSocket and
	RunLoop for simultaneously monitoring two kinds of inputs, window
	events and process outputs, without periodically polling.
* macfns.c (mac_initialized): Remove extern.
	(stricmp): Put in #if 0.  All callers changed to use xstricmp in
	xfaces.c.
	(strnicmp): Decrement `n' at the end of each loop, not the
	beginning.
	(check_mac): Use the term "Mac native windows" instead of "Mac
	OS".
	(check_x_display_info, x_display_info_for_name): Sync with xfns.c.
	(mac_get_rdb_resource): New function (from w32reg.c).
	(x_get_string_resource): Use it.
	(install_window_handler): Add extern.
	(mac_window): New function.
	(Fx_create_frame): Use it instead of make_mac_frame.  Set
	parameter for Qfullscreen.  Call x_wm_set_size_hint.
	(Fx_open_connection, Fx_close_connection): New defuns.
	(syms_of_macfns): Defsubr them.
	(x_create_tip_frame) [TARGET_API_MAC_CARBON]: Add
	kWindowNoUpdatesAttribute to the window attribute.
	(x_create_tip_frame) [!TARGET_API_MAC_CARBON]: Use NewCWindow.
	(x_create_tip_frame): Don't call ShowWindow.
	(Fx_show_tip): Call ShowWindow.
	(Fx_file_dialog): Change `#ifdef TARGET_API_MAC_CARBON' to `#if
	TARGET_API_MAC_CARBON'.
	(mac_frame_parm_handlers): Set handlers for Qfullscreen.
	(syms_of_macfns) [MAC_OSX]: Initialize mac_in_use to 0.
* macgui.h [!MAC_OSX]: Don't include Controls.h.  Include
	Windows.h.
	(Window): Typedef to WindowPtr and move outside `#if
	TARGET_API_MAC_CARBON'.
	(XSizeHints): New struct.
* macterm.c (x_update_begin, x_update_end)
	[TARGET_API_MAC_CARBON]: Disable screen updates during update of a
	frame.
	(x_draw_glyph_string_background, x_draw_glyph_string_foreground)
	[MAC_OS8]: Use XDrawImageString/XDrawImageString16.
	(construct_mouse_click): Put in #if 0.
	(x_check_fullscreen, x_check_fullscreen_move): Remove decls.
	(x_scroll_bar_create, x_scroll_bar_handle_click): Change `#ifdef
	TARGET_API_MAC_CARBON' to `#if TARGET_API_MAC_CARBON'.
	(activate_scroll_bars, deactivate_scroll_bars)
	[!TARGET_API_MAC_CARBON]: Use ActivateControl/DeactivateControl.
	(x_make_frame_visible) [TARGET_API_MAC_CARBON]: Reposition window
	if the position is neither user-specified nor program-specified.
	(x_free_frame_resources): Free size_hints.
	(x_wm_set_size_hint): Allocate size_hints if needed.  Set
	size_hints.
	(mac_clear_font_name_table): New function.
	(mac_do_list_fonts): Initialize font_name_table if needed.
	(x_list_fonts): Don't initialize font_name_table.  Add BLOCK_INPUT
	around mac_do_list_fonts.
	(mac_unload_font): New function.
	(x_load_font): Add BLOCK_INPUT around XLoadQueryFont.
	(init_mac_drag_n_drop, mac_do_receive_drag): Enclose declarations
	and definitions with #if TARGET_API_MAC_CARBON.
	[USE_CARBON_EVENTS] (mac_handle_window_event): Add decl.
	(install_window_handler): Add decl.
	(do_window_update): Add BeginUpdate/EndUpdate for the tooltip
	window.  Use UpdateControls.  Get the rectangle that should be
	updated and restrict the target of expose_frame to it.
	(do_grow_window): Set minimum height/width according to
	size_hints.
	(do_grow_window) [TARGET_API_MAC_CARBON]: Use ResizeWindow.
	(do_zoom_window): Don't use x_set_window_size.
	[USE_CARBON_EVENTS] (mac_handle_window_event): New function.
	(install_window_handler): New function.
	[!USE_CARBON_EVENTS] (mouse_region): New variable.
	[!USE_CARBON_EVENTS] (mac_wait_next_event): New function.
	(XTread_socket) [USE_CARBON_EVENTS]: Move call to
	GetEventDispatcherTarget inside BLOCK_INPUT.
	(XTread_socket) [!USE_CARBON_EVENTS]: Use mac_wait_next_event.
	Update mouse_region when mouse is moved.
	(make_mac_frame): Remove.
	(make_mac_terminal_frame): Put in #ifdef MAC_OS8.  Initialize
	mouse pointer shapes.  Change values of f->left_pos and
	f->top_pos.  Don't use make_mac_frame.  Use NewCWindow.  Don't
	call ShowWindow.
	(mac_initialize_display_info) [MAC_OSX]: Create mac_id_name from
	Vinvocation_name and Vsystem_name.
	(mac_make_rdb): New function (from w32term.c).
	(mac_term_init): Use it.  Add BLOCK_INPUT.  Error if display has
	already been opened.  Don't pass argument to
	mac_initialize_display_info.  Don't set dpyinfo->height/width.
	Add entries to x_display_list and x_display_name_list.
	(x_delete_display): New function.
	(mac_initialize): Don't call mac_initialize_display_info.
	(syms_of_macterm) [!MAC_OSX]: Don't call Fprovide.
* macterm.h (check_mac): Add extern.
	(struct mac_output): New member size_hints.
	(FRAME_SIZE_HINTS): New macro.
	(mac_unload_font): Add extern.
* xdisp.c (expose_window, expose_frame): Remove kludges for Mac.
* xfaces.c (clear_font_table) [MAC_OS]: call mac_unload_font.
2004-12-27 17:27:30 +00:00
Kim F. Storm
2ec7f67a91 (concat): Use SAFE_ALLOCA. 2004-11-29 15:35:15 +00:00
Luc Teirlinck
8181f402ed (Fyes_or_no_p): Call Fread_from_minibuffer with extra argument. 2004-11-21 00:57:49 +00:00
Stefan Monnier
2a1893f46c Avoid side-effects inside XSETFASTINT's arguments. 2004-11-16 15:35:14 +00:00
Kim F. Storm
27f604dddf (Fsafe_plist_get): New defun.
(syms_of_fns): Defsubr it.
2004-11-15 15:21:14 +00:00
Eli Zaretskii
32bfb2d565 (sxhash): As far as possible, merge calculation of
hash code for symbols and strings.
2004-11-06 17:01:27 +00:00
Kim F. Storm
233f3db624 Fix SAFE_FREE calls. Replace SAFE_FREE_LISP calls. 2004-10-26 22:38:50 +00:00
Stefan Monnier
91244343b5 (map_char_table): Add missing gcpros. 2004-10-13 18:40:03 +00:00
Luc Teirlinck
cfd236932d (Fclear_string): Correct previous change. 2004-07-06 19:36:56 +00:00
Luc Teirlinck
a085bf9dd6 (Fclear_string): Put call to CHECK_STRING in correct place. 2004-07-06 17:55:00 +00:00
John Paul Wallington
fa164e6ae7 (Fclear_string): Signal an error if STRING is not a string. 2004-07-06 05:08:57 +00:00
Kim F. Storm
9677e3a9f1 (Fmapconcat, Fmapcar): Remove superfluous GCPROs. 2004-06-24 22:03:10 +00:00
Kim F. Storm
3ef1eeeef5 (Fmapcar, Fmapconcat): GCPRO the args array. 2004-06-22 14:48:10 +00:00
Kim F. Storm
7b4cd44a01 (Fmapconcat, Fmapcar): Use new SAFE_ALLOCA_LISP and
SAFE_FREE_LISP macros.
2004-06-22 13:57:00 +00:00
Kim F. Storm
f4c30cde81 (Fmapconcat, Fmapcar): Use SAFE_ALLOCA_LISP. 2004-06-21 22:36:02 +00:00
Kim F. Storm
799c08aca5 * fns.c (string_make_multibyte, string_to_multibyte)
(string_make_unibyte, Fmapconcat, Fmapcar): Use SAFE_ALLOCA.
(MAX_ALLOCA): Remove define.
(Fbase64_encode_region, Fbase64_encode_string)
(Fbase64_decode_region, Fbase64_decode_string): Use SAFE_ALLOCA.
(Fbase64_encode_region, Fbase64_encode_string): Fix potential
memory leak if encoding fails.
2004-06-21 21:55:15 +00:00
Jan Djärv
a6cb6b787e * fns.c (string_to_multibyte): Use xmalloc/xfree instead of alloca. 2004-06-17 14:37:53 +00:00
Kenichi Handa
a54ad22035 (count_combining): Delete it.
(concat): Don't check combining bytes.
2004-05-10 03:56:43 +00:00
Andreas Schwab
db85986c76 (Fcopy_sequence, concat, internal_equal, Ffillarray, mapcar1): Use
BOOL_VECTOR_BITS_PER_CHAR instead of BITS_PER_CHAR for bool vectors.
2004-04-26 21:44:22 +00:00
John Paul Wallington
474d05350a (Fassoc, Feql): Fix indentation. 2004-04-20 00:17:46 +00:00
John Paul Wallington
95f8c3b95d (Feql): New function.
(syms_of_fns): defsubr it.
2004-04-19 15:17:53 +00:00
Richard M. Stallman
6054c58214 (internal_equal): New arg PROPS controls comparing
text properties.  All callers changed.
(Fequal_including_properties): New function.
(syms_of_fns): defsubr it.
2004-03-12 10:07:36 +00:00
Kenichi Handa
ebaff4af68 (Fset_char_table_range): Fix previous change. 2004-02-05 04:55:21 +00:00
Kenichi Handa
13c5d120fc (Fset_char_table_range): Handle charsets ascii,
eight-bit-control, and eight-bit-graphic correctly.
2004-02-04 01:20:27 +00:00
Kenichi Handa
13f52ed814 (string_char_to_byte): Optimize for ASCII only string.
(string_byte_to_char): Likewise.
2004-01-29 02:54:22 +00:00
Kenichi Handa
fe905025d0 (Fmd5): If OBJECT is a buffer different from the current
one, set buffer to OBJECT temporarily.
2004-01-23 00:14:48 +00:00
Eli Zaretskii
74a47d1fba (internal_equal): Return t for two NaN arguments. 2003-12-29 13:51:54 +00:00
Luc Teirlinck
ac1106fcce (Fset_char_table_range): Doc fix. 2003-12-24 00:17:58 +00:00
Luc Teirlinck
0dc72b11db (Frandom, Fstring_make_multibyte): Doc fixes. 2003-12-23 23:08:08 +00:00
Jan Djärv
03d6484ea4 Add variable use-file-dialog to control use of file dialogs. 2003-11-29 10:44:36 +00:00
Andreas Schwab
00498bfc92 (internal_equal) <case Lisp_Vectorlike>: Declare size as
EMACS_INT to not lose bits.
(Ffillarray): Don't set bits beyond the size of a bool vector.
2003-11-25 12:22:08 +00:00
Luc Teirlinck
c541e2a0b9 (Fset_char_table_parent): Doc fix. 2003-11-23 03:12:45 +00:00
Luc Teirlinck
aa1b3f2e18 (Fassq, Fassoc, Frassq, Frassoc): Doc fixes. 2003-11-22 03:48:24 +00:00
Luc Teirlinck
cb8a2fd881 (Freverse): Doc fix.
(Fnreverse): Doc fix.
2003-11-21 15:58:15 +00:00
Stefan Monnier
854c1a594e (hashfn_eq, hashfn_eql, hashfn_equal, hash_put)
(sxhash_string, sxhash): Use INTMASK instead of VALMASK.
(maybe_resize_hash_table): Use MOST_POSITIVE_FIXNUM.
2003-11-17 23:30:28 +00:00
Luc Teirlinck
51931fe9f2 (Fstring_to_multibyte): Doc fix. 2003-11-12 17:05:37 +00:00
Luc Teirlinck
8d70d57425 (Frequire): Doc fix. 2003-10-05 23:38:15 +00:00
Miles Bader
ab5796a9f9 Add arch taglines 2003-09-01 15:45:59 +00:00
Richard M. Stallman
85cad5793c (Fclear_string): New function.
(syms_of_fns): defsubr it.
2003-07-29 17:36:52 +00:00
Richard M. Stallman
d68beb2f6d (Flocale_info): Renamed from Flanginfo. Doc fixes.
(syms_of_fns): Corresponding change.
2003-07-21 09:52:45 +00:00
Stefan Monnier
9568e3d87e (sweep_weak_table): Update calls to mark_object. 2003-07-06 19:29:48 +00:00
Dave Love
30b1b0cf41 Doc fixes. 2003-06-02 18:31:29 +00:00
Richard M. Stallman
fdf91be032 (map_char_table): Fix previous change. 2003-05-17 15:49:42 +00:00
Richard M. Stallman
44356f63a3 (map_char_table): New arg TABLE gets the master table. All calls changed.
Process default and inheritance, resorting to Faref if necessary.
2003-05-17 12:45:52 +00:00