bpt/emacs.git
12 years ago* dispextern.h (struct face.stipple):
Paul Eggert [Wed, 22 Jun 2011 06:16:16 +0000 (23:16 -0700)]
* dispextern.h (struct face.stipple):

* image.c (x_bitmap_height, x_bitmap_width, x_bitmap_pixmap)
(x_bitmap_mask, x_allocate_bitmap_record)
(x_create_bitmap_from_data, x_create_bitmap_from_file)
(x_destroy_bitmap, x_destroy_all_bitmaps, x_create_bitmap_mask)
(x_create_bitmap_from_xpm_data):
* nsterm.h (struct ns_display_info.bitmaps_size, .bitmaps_last):
* w32term.h (struct w32_display_info.icon_bitmap_id, .bitmaps_size)
(.bitmaps_last):
* xfaces.c (load_pixmap):
* xterm.c (x_bitmap_icon, x_wm_set_icon_pixmap):
* xterm.h (struct x_display_info.icon_bitmap_id, .bitmaps_size)
(.bitmaps_last, struct x_output.icon_bitmap):
Use ptrdiff_t, not int, for bitmap indexes.
(x_allocate_bitmap_record): Check for size overflow.
* dispextern.h, lisp.h: Adjust to API changes elsewhere.

12 years ago* buffer.c (OVERLAY_COUNT_MAX): New macro.
Paul Eggert [Tue, 21 Jun 2011 23:16:43 +0000 (16:16 -0700)]
* buffer.c (OVERLAY_COUNT_MAX): New macro.

(overlays_in, mouse_face_overlay_overlaps, Foverlays_in):
Use ptrdiff_t, not int, for sizes.
(overlays_in): Check for size-calculation overflow.

12 years agoUse ptrdiff_t, not int, for overlay counts.
Paul Eggert [Tue, 21 Jun 2011 21:32:10 +0000 (14:32 -0700)]
Use ptrdiff_t, not int, for overlay counts.

* buffer.h (overlays_at, sort_overlays, GET_OVERLAYS_AT):
* editfns.c (overlays_around, get_pos_property):
* textprop.c (get_char_property_and_overlay):
* xdisp.c (next_overlay_change, note_mouse_highlight):
* xfaces.c (face_at_buffer_position):
* buffer.c (overlays_at, sort_overlays, Foverlays_at)
(Fnext_overlay_change, Fprevious_overlay_change):
Use ptrdiff_t, not int, for sizes.
(overlays_at): Check for size-calculation overflow.

12 years ago* xterm.c (xim_initialize, same_x_server): Strlen may not fit in int.
Paul Eggert [Tue, 21 Jun 2011 20:43:08 +0000 (13:43 -0700)]
* xterm.c (xim_initialize, same_x_server): Strlen may not fit in int.

12 years ago* xsmfns.c (smc_save_yourself_CB, x_session_initialize): Avoid strlen.
Paul Eggert [Tue, 21 Jun 2011 20:32:19 +0000 (13:32 -0700)]
* xsmfns.c (smc_save_yourself_CB, x_session_initialize): Avoid strlen.

(x_session_initialize): Do not assume string length fits in int.

12 years ago* xsettings.c (Ffont_get_system_normal_font, Ffont_get_system_font): Avoid need for...
Paul Eggert [Tue, 21 Jun 2011 17:52:14 +0000 (10:52 -0700)]
* xsettings.c (Ffont_get_system_normal_font, Ffont_get_system_font): Avoid need for strlen.

12 years ago* xsettings.c (apply_xft_settings): Fix potential buffer overrun.
Paul Eggert [Tue, 21 Jun 2011 17:49:46 +0000 (10:49 -0700)]
* xsettings.c (apply_xft_settings): Fix potential buffer overrun.

This is unlikely, but can occur if DPI is outlandish.

12 years ago* font.c (font_intern_prop): Don't use string_to_number, since the string isn't null...
Paul Eggert [Tue, 21 Jun 2011 06:47:52 +0000 (23:47 -0700)]
* font.c (font_intern_prop): Don't use string_to_number, since the string isn't null-terminated.

12 years ago* xselect.c (Fx_get_atom_name): Avoid need for strlen.
Paul Eggert [Tue, 21 Jun 2011 02:16:54 +0000 (19:16 -0700)]
* xselect.c (Fx_get_atom_name): Avoid need for strlen.

12 years ago* xrdb.c: Don't assume strlen fits in int; avoid some strlens.
Paul Eggert [Tue, 21 Jun 2011 02:15:16 +0000 (19:15 -0700)]
* xrdb.c: Don't assume strlen fits in int; avoid some strlens.

* xrdb.c (magic_file_p, search_magic_path):
Omit last arg SUFFIX; it was always 0.  All callers changed.
(magic_file_p): Use ptrdiff_t, not int.  Check for size overflow.

12 years ago* xfont.c (xfont_match): Avoid need for strlen.
Paul Eggert [Tue, 21 Jun 2011 01:40:45 +0000 (18:40 -0700)]
* xfont.c (xfont_match): Avoid need for strlen.

12 years ago* xfns.c: Don't assume strlen fits in int.
Paul Eggert [Tue, 21 Jun 2011 01:38:04 +0000 (18:38 -0700)]
* xfns.c: Don't assume strlen fits in int.

(xic_create_fontsetname, x_window): Use ptrdiff_t, not int.

12 years ago* xdisp.c (display_mode_element): Don't assume strlen fits in int.
Paul Eggert [Tue, 21 Jun 2011 01:30:32 +0000 (18:30 -0700)]
* xdisp.c (display_mode_element): Don't assume strlen fits in int.

12 years ago* xdisp.c (message_log_check_duplicate): Return intmax_t,
Paul Eggert [Tue, 21 Jun 2011 01:21:44 +0000 (18:21 -0700)]
* xdisp.c (message_log_check_duplicate): Return intmax_t,

not unsigned long, as we prefer signed integers.  All callers changed.
Detect integer overflow in repeat count.
(message_dolog): Don't assume print length fits in 39 bytes.

12 years ago* callproc.c (egetenv): Adjust to getenv_internal API change.
Paul Eggert [Tue, 21 Jun 2011 01:06:45 +0000 (18:06 -0700)]
* callproc.c (egetenv): Adjust to getenv_internal API change.

12 years agoMerge from trunk.
Paul Eggert [Tue, 21 Jun 2011 00:59:02 +0000 (17:59 -0700)]
Merge from trunk.

12 years ago* x-dnd.el (x-dnd-version-from-flags)
Jan Djärv [Mon, 20 Jun 2011 20:49:12 +0000 (22:49 +0200)]
* x-dnd.el (x-dnd-version-from-flags)
(x-dnd-more-than-3-from-flags): New functions that handle long-as-cons
and long as number.
(x-dnd-handle-xdnd): Call functions above.

Fixes: debbugs:8899

12 years ago* lisp/minibuffer.el (completion-metadata): Prepend the alist with `metadata'.
Stefan Monnier [Mon, 20 Jun 2011 20:16:20 +0000 (16:16 -0400)]
* lisp/minibuffer.el (completion-metadata): Prepend the alist with `metadata'.
(completion-try-completion, completion-all-completions): Compute the
metadata argument if it's missing; make it optional.

Fixes: debbugs:8795

12 years ago* doc/misc/eshell.texi (Known problems): Fix typo.
Stefan Monnier [Mon, 20 Jun 2011 16:14:01 +0000 (12:14 -0400)]
* doc/misc/eshell.texi (Known problems): Fix typo.

12 years agoUse completion-at-point rather than completion-in-region.
Stefan Monnier [Mon, 20 Jun 2011 16:02:31 +0000 (12:02 -0400)]
Use completion-at-point rather than completion-in-region.
* lisp/wid-edit.el: Use lexical scoping and move towards completion-at-point.
(widget-complete): Use new :completion-function property.
(widget-completions-at-point): New function.
(default): Use :completion-function instead of :complete.
(widget-default-completions): Rename from widget-default-complete, rewrite.
(widget-string-complete, widget-file-complete, widget-color-complete):
Remove functions.
(file, symbol, function, variable, coding-system, color):
* lisp/international/mule-cmds.el (default-input-method, charset)
(language-info-custom-alist):
* lisp/cus-edit.el (face): Use new property :completions.

* lisp/progmodes/pascal.el (pascal-completions-at-point): New function.
(pascal-mode): Use it.
(pascal-mode-map): Use completion-at-point.
(pascal-toggle-completions): Make obsolete.
(pascal-complete-word, pascal-show-completions):
* lisp/progmodes/octave-mod.el (octave-complete-symbol):
Redefine as obsolete alias.
* lisp/progmodes/octave-inf.el (inferior-octave-completion-at-point):
Signal absence of completion info for old Octave,
(inferior-octave-complete): Redefine as obsolete alias.
* lisp/progmodes/meta-mode.el: Use lexical-binding and completion-at-point.
(meta-completions-at-point): Rename from meta-complete-symbol and
adapt it for use on completion-at-point-functions.
(meta-common-mode): Use it.
(meta-looking-at-backward, meta-match-buffer): Remove.
(meta-complete-symbol): Redefine as obsolete alias.
(meta-common-mode-map): Use completion-at-point.
* lisp/progmodes/make-mode.el: Use lexical-binding and completion-at-point.
(makefile-mode-map): Use completion-at-point.
(makefile-completions-at-point): Rename from makefile-complete and
adapt it for use on completion-at-point-functions.
(makefile-mode): Use it.
(makefile-complete): Redefine as obsolete alias.

12 years ago* lisp/net/rcirc.el: Delete trailing whitespaces once and for all.
Deniz Dogan [Mon, 20 Jun 2011 12:55:24 +0000 (14:55 +0200)]
* lisp/net/rcirc.el: Delete trailing whitespaces once and for all.

12 years ago* src/process.c (Fset_process_buffer): Clarify return value in docstring.
Deniz Dogan [Mon, 20 Jun 2011 12:54:05 +0000 (14:54 +0200)]
* src/process.c (Fset_process_buffer): Clarify return value in docstring.

12 years agoRestore old behavior of get-window-with-predicate and get-buffer-window-list.
Martin Rudalics [Mon, 20 Jun 2011 08:41:57 +0000 (10:41 +0200)]
Restore old behavior of get-window-with-predicate and get-buffer-window-list.

* window.el (get-window-with-predicate): Start scanning with
window following selected window to restore Emacs 23 behavior.
Clarify doc-string.
(get-buffer-window-list): Start scanning with selected window to
restore Emacs 23 behavior.  Clarify doc-string.

12 years ago* termcap.c: Don't assume sizes fit in int and never overflow.
Paul Eggert [Mon, 20 Jun 2011 07:21:06 +0000 (00:21 -0700)]
* termcap.c: Don't assume sizes fit in int and never overflow.

(struct termcap_buffer, tgetent): Use ptrdiff_t, not int, for sizes.
(gobble_line): Check for size-calculation overflow.

12 years ago* minibuf.c (Fread_buffer): Don't assume strlen fits in int.
Paul Eggert [Mon, 20 Jun 2011 06:14:57 +0000 (23:14 -0700)]
* minibuf.c (Fread_buffer): Don't assume strlen fits in int.

12 years ago* lread.c (intern, intern_c_string): Don't assume strlen fits in int.
Paul Eggert [Mon, 20 Jun 2011 06:11:36 +0000 (23:11 -0700)]
* lread.c (intern, intern_c_string): Don't assume strlen fits in int.

12 years ago* keyboard.c (parse_tool_bar_item): Avoid need for strlen.
Paul Eggert [Mon, 20 Jun 2011 06:07:16 +0000 (23:07 -0700)]
* keyboard.c (parse_tool_bar_item): Avoid need for strlen.

12 years ago* image.c (xpm_scan) [HAVE_NS && !HAVE_XPM]:
Paul Eggert [Mon, 20 Jun 2011 06:03:10 +0000 (23:03 -0700)]
* image.c (xpm_scan) [HAVE_NS && !HAVE_XPM]:

Don't assume string length fits in int.

12 years ago* gtkutil.c (style_changed_cb): Avoid need for strlen.
Paul Eggert [Mon, 20 Jun 2011 05:54:33 +0000 (22:54 -0700)]
* gtkutil.c (style_changed_cb): Avoid need for strlen.

12 years ago* font.c (font_intern_prop): Don't assume string length fits in int.
Paul Eggert [Mon, 20 Jun 2011 05:51:47 +0000 (22:51 -0700)]
* font.c (font_intern_prop): Don't assume string length fits in int.

Don't assume integer property fits in fixnum.
* font.h (font_intern_prop): 2nd arg is now ptrdiff_t, not int.

12 years ago* emacs-lisp/syntax.el (syntax-ppss): Further improve docstring.
Daniel Colascione [Mon, 20 Jun 2011 03:36:16 +0000 (20:36 -0700)]
* emacs-lisp/syntax.el (syntax-ppss): Further improve docstring.

12 years ago* font.c: Don't assume string length fits in int.
Paul Eggert [Mon, 20 Jun 2011 03:21:35 +0000 (20:21 -0700)]
* font.c: Don't assume string length fits in int.

(font_parse_xlfd, font_parse_fcname, font_unparse_fcname):
Use ptrdiff_t, not int.

12 years ago* filelock.c: Fix some buffer overrun and integer overflow issues.
Paul Eggert [Mon, 20 Jun 2011 03:11:40 +0000 (20:11 -0700)]
* filelock.c: Fix some buffer overrun and integer overflow issues.

(get_boot_time): Don't assume that gzip command string fits in 100 bytes.
Reformulate so as not to need the command string.
Invoke gzip -cd rather than gunzip, as it's more portable.
(lock_info_type, lock_file_1, lock_file):
Don't assume pid_t and time_t fit in unsigned long.
(LOCK_PID_MAX): Remove; we now use more-reliable bounds.
(current_lock_owner): Prefer signed type for sizes.
Use memcpy, not strncpy, where memcpy is what is really wanted.
Don't assume (via atoi) that time_t and pid_t fit in int.
Check for time_t and/or pid_t out of range, e.g., via a network share.
Don't alloca where an auto var works fine.

12 years ago* fileio.c: Fix some integer overflow issues.
Paul Eggert [Sun, 19 Jun 2011 19:06:16 +0000 (12:06 -0700)]
* fileio.c: Fix some integer overflow issues.

(file_name_as_directory, Fexpand_file_name, Fsubstitute_in_file_name):
Don't assume string length fits in int.
(directory_file_name): Don't assume string length fits in long.
(make_temp_name): Don't assume pid fits in int, or that its print
length is less than 20.

12 years agoFix last change.
Chong Yidong [Sun, 19 Jun 2011 18:59:58 +0000 (14:59 -0400)]
Fix last change.

12 years ago* lisp/files.el (auto-mode-alist): Entry for m2-mode (Bug#8852).
Chong Yidong [Sun, 19 Jun 2011 18:53:49 +0000 (14:53 -0400)]
* lisp/files.el (auto-mode-alist): Entry for m2-mode (Bug#8852).

12 years ago* data.c (Fsubr_name): Rewrite to avoid a strlen call.
Paul Eggert [Sun, 19 Jun 2011 18:44:58 +0000 (11:44 -0700)]
* data.c (Fsubr_name): Rewrite to avoid a strlen call.

12 years ago* coding.c (make_subsidiaries): Don't assume string length fits in int.
Paul Eggert [Sun, 19 Jun 2011 18:44:09 +0000 (11:44 -0700)]
* coding.c (make_subsidiaries): Don't assume string length fits in int.

12 years ago* info.el (Info-apropos-toc-nodes): Minor doc fix (Bug#8833).
Chong Yidong [Sun, 19 Jun 2011 18:42:06 +0000 (14:42 -0400)]
* info.el (Info-apropos-toc-nodes): Minor doc fix (Bug#8833).

12 years ago* callproc.c (child_setup): Rewrite to avoid two strlen calls.
Paul Eggert [Sun, 19 Jun 2011 18:40:02 +0000 (11:40 -0700)]
* callproc.c (child_setup): Rewrite to avoid two strlen calls.

12 years agoAuto-commit of loaddefs files.
Glenn Morris [Sun, 19 Jun 2011 18:39:24 +0000 (14:39 -0400)]
Auto-commit of loaddefs files.

12 years ago* process.c (Fformat_network_address): Use EMACS_INT, not EMACS_UINT.
Paul Eggert [Sun, 19 Jun 2011 18:38:58 +0000 (11:38 -0700)]
* process.c (Fformat_network_address): Use EMACS_INT, not EMACS_UINT.

We prefer signed integers, even for size calculations.

12 years ago* emacs.c: Don't assume string length fits in 'int'.
Paul Eggert [Sun, 19 Jun 2011 18:37:51 +0000 (11:37 -0700)]
* emacs.c: Don't assume string length fits in 'int'.

(DEFINE_DUMMY_FUNCTION, sort_args): Use ptrdiff_t, not int.
(main): Don't invoke strlen when not needed.

12 years agoAuto-commit of generated files.
Glenn Morris [Sun, 19 Jun 2011 18:33:17 +0000 (14:33 -0400)]
Auto-commit of generated files.

12 years ago* dbusbind.c (XD_ERROR): Don't arbitrarily truncate string.
Paul Eggert [Sun, 19 Jun 2011 18:32:55 +0000 (11:32 -0700)]
* dbusbind.c (XD_ERROR): Don't arbitrarily truncate string.

(XD_DEBUG_MESSAGE): Don't waste a byte.

12 years ago* callproc.c: Don't assume string length fits in 'int.'
Paul Eggert [Sun, 19 Jun 2011 18:30:19 +0000 (11:30 -0700)]
* callproc.c: Don't assume string length fits in 'int.'

12 years ago* buffer.c (init_buffer): Don't assume string length fits in 'int'.
Paul Eggert [Sun, 19 Jun 2011 18:27:58 +0000 (11:27 -0700)]
* buffer.c (init_buffer): Don't assume string length fits in 'int'.

12 years ago* lib/unistd.in.h, m4/getloadavg.m4: Merge from gnulib.
Paul Eggert [Sun, 19 Jun 2011 18:22:16 +0000 (11:22 -0700)]
* lib/unistd.in.h, m4/getloadavg.m4: Merge from gnulib.

12 years agoRegroup clauses in display-buffer-normalize-options (Bug#8851) and (Bug#8856).
Martin Rudalics [Sun, 19 Jun 2011 14:32:12 +0000 (16:32 +0200)]
Regroup clauses in display-buffer-normalize-options (Bug#8851) and (Bug#8856).

* window.el (display-buffer-normalize-options): Move special-display-p
group after pop-up-frame group (Bug#8851) and (Bug#8856).

12 years agoProvide functions for saving window configurations as Lisp objects.
Martin Rudalics [Sun, 19 Jun 2011 10:17:56 +0000 (12:17 +0200)]
Provide functions for saving window configurations as Lisp objects.

* window.el (window-list-no-nils, window-state-ignored-parameters)
(window-state-get-1, window-state-get, window-state-put-list)
(window-state-put-1, window-state-put-2, window-state-put): New
functions.

12 years agoSanitize processing of display specifiers; new option frame-auto-delete.
Martin Rudalics [Sun, 19 Jun 2011 09:59:58 +0000 (11:59 +0200)]
Sanitize processing of display specifiers; new option frame-auto-delete.

* window.el (display-buffer-other-window-means-other-frame):
Call display-buffer-normalize-alist.
(display-buffer-normalize-specifiers-1): Rename to
display-buffer-normalize-argument.  New argument other-frame.
Rewrite.
(display-buffer-normalize-specifiers-2): Rename to
display-buffer-normalize-options.
(display-buffer-normalize-alist-1): New function.
(display-buffer-normalize-specifiers-3): Rename to
display-buffer-normalize-alist.  Call
display-buffer-normalize-alist-1.
(display-buffer-normalize-options-inhibit): New variable.
(display-buffer-normalize-specifiers): Rewrite calling
display-buffer-normalize-alist,
display-buffer-normalize-argument, and
display-buffer-normalize-options.  Don't call the latter if
display-buffer-normalize-options-inhibit is non-nil.
(frame-auto-delete): New option.
(window-deletable-p): Use frame-auto-delete.

12 years ago* lread.c (string_to_number): Simplify the 2011-04-26 change by invoking xsignal1.
Paul Eggert [Sun, 19 Jun 2011 01:35:03 +0000 (18:35 -0700)]
* lread.c (string_to_number): Simplify the 2011-04-26 change by invoking xsignal1.

12 years ago* lread.c (invalid_syntax): Omit length argument.
Paul Eggert [Sun, 19 Jun 2011 01:31:41 +0000 (18:31 -0700)]
* lread.c (invalid_syntax): Omit length argument.

All uses changed.  This doesn't fix a bug, but it simplifies the
code away from its former Hollerith-constant appearance, and it's
one less 'int' to worry about when looking at integer-overflow issues.

12 years ago* lisp.h (make_fixnum_or_float): Remove unnecessary cast to EMACS_INT.
Paul Eggert [Sun, 19 Jun 2011 00:11:45 +0000 (17:11 -0700)]
* lisp.h (make_fixnum_or_float): Remove unnecessary cast to EMACS_INT.

12 years ago* lisp.h (LIST_END_P): Remove unused macro and its bogus comment.
Paul Eggert [Sun, 19 Jun 2011 00:09:24 +0000 (17:09 -0700)]
* lisp.h (LIST_END_P): Remove unused macro and its bogus comment.

12 years ago* lisp.h (DEFUN): Remove bogus use of sizeof (struct Lisp_Subr).
Paul Eggert [Sun, 19 Jun 2011 00:06:17 +0000 (17:06 -0700)]
* lisp.h (DEFUN): Remove bogus use of sizeof (struct Lisp_Subr).

This didn't break anything, but it didn't help either.
It's confusing to put a bogus integer in a place where the actual
value does not matter.

12 years agoauth-source.el (auth-source-netrc-use-gpg-tokens): Replace `auth-source-save-secrets...
Teodor Zlatanov [Sat, 18 Jun 2011 22:23:55 +0000 (22:23 +0000)]
auth-source.el (auth-source-netrc-use-gpg-tokens): Replace `auth-source-save-secrets' with a more sensitive alist that can be configured per file.  Experimental, so defaults to 'never.
 (auth-source-netrc-create): Use it.  Still experimental code.
 (with-auth-source-epa-overrides): Use `find-file-hooks' if `find-file-hook' is unbound (XEmacs fix).  Fix backquoting bug.

12 years agoAdd rx.el support for numbered groups (Bug#8776).
Chong Yidong [Sat, 18 Jun 2011 21:12:33 +0000 (17:12 -0400)]
Add rx.el support for numbered groups (Bug#8776).

* lisp/emacs-lisp/rx.el (rx-constituents): Add support for numbered groups.
(rx-submatch-n): New function.
(rx): Document it.

12 years ago* dired-x.el (dired-mark-unmarked-files): Fix interactive spec (Bug#8768).
Chong Yidong [Sat, 18 Jun 2011 20:17:30 +0000 (16:17 -0400)]
* dired-x.el (dired-mark-unmarked-files): Fix interactive spec (Bug#8768).

12 years ago* lisp/textmodes/fill.el (default-justification): Add :safe (Bug#8879).
Chong Yidong [Sat, 18 Jun 2011 19:21:16 +0000 (15:21 -0400)]
* lisp/textmodes/fill.el (default-justification): Add :safe (Bug#8879).

12 years agoFixes for GLYPH_DEBUG.
Chong Yidong [Sat, 18 Jun 2011 19:15:06 +0000 (15:15 -0400)]
Fixes for GLYPH_DEBUG.

* dispnew.c (add_window_display_history): Use BVAR.

* xdisp.c (debug_method_add): Use BVAR.
(check_window_end, dump_glyph_matrix, dump_glyph)
(dump_glyph_row, dump_glyph_string): Convert arglist to ANSI C.

* xfaces.c (check_lface_attrs, check_lface, dump_realized_face):
Likewise.

* xfns.c (Fx_create_frame, x_create_tip_frame): Delay image cache
check till after the cache is created in init_frame_faces.

12 years ago* lisp.h (XSET) [USE_LISP_UNION_TYPE]: Use uintptr_t and intptr_t,
Paul Eggert [Sat, 18 Jun 2011 19:13:46 +0000 (12:13 -0700)]
* lisp.h (XSET) [USE_LISP_UNION_TYPE]: Use uintptr_t and intptr_t,

not EMACS_UINT and EMACS_INT, when converting pointer to integer.
This avoids a GCC warning when WIDE_EMACS_INT.

12 years ago* lisp.h (struct Lisp_Bool_Vector.size): EMACS_INT, not EMACS_UINT.
Paul Eggert [Sat, 18 Jun 2011 19:08:22 +0000 (12:08 -0700)]
* lisp.h (struct Lisp_Bool_Vector.size): EMACS_INT, not EMACS_UINT.

We prefer signed types, and the value cannot exceed the EMACS_INT
range anyway (because otherwise the length would not be representable).

12 years agoFix for disable-theme/defface interaction (Bug#8889).
Chong Yidong [Sat, 18 Jun 2011 18:49:19 +0000 (14:49 -0400)]
Fix for disable-theme/defface interaction (Bug#8889).

* lisp/cus-face.el (custom-declare-face): Call custom-theme-recalc face
anytime existing face settings are present.

12 years ago* lisp.h (union Lisp_Object.i): EMACS_INT, not EMACS_UINT.
Paul Eggert [Sat, 18 Jun 2011 18:32:22 +0000 (11:32 -0700)]
* lisp.h (union Lisp_Object.i): EMACS_INT, not EMACS_UINT.

This is for consistency with the ordinary, non-USE_LISP_UNION_TYPE,
implementation.

12 years ago* indent.c (Fcompute_motion): Don't assume hscroll and tab offset fit in int.
Paul Eggert [Sat, 18 Jun 2011 18:29:19 +0000 (11:29 -0700)]
* indent.c (Fcompute_motion): Don't assume hscroll and tab offset fit in int.

12 years ago* insdel.c: Omit unnecessary forward decls, to simplify future changes.
Paul Eggert [Sat, 18 Jun 2011 18:28:32 +0000 (11:28 -0700)]
* insdel.c: Omit unnecessary forward decls, to simplify future changes.

12 years ago* indent.c (sane_tab_width): New function.
Paul Eggert [Sat, 18 Jun 2011 18:24:12 +0000 (11:24 -0700)]
* indent.c (sane_tab_width): New function.

(current_column, scan_for_column, Findent_to, position_indentation)
(compute_motion): Use it.  This is just for clarity.

12 years ago* image.c (xbm_image_p): Don't assume stated width and height fit in int.
Paul Eggert [Sat, 18 Jun 2011 18:12:25 +0000 (11:12 -0700)]
* image.c (xbm_image_p): Don't assume stated width and height fit in int.

12 years ago* lisp.h (lint_assume): New macro.
Paul Eggert [Sat, 18 Jun 2011 18:09:17 +0000 (11:09 -0700)]
* lisp.h (lint_assume): New macro.

* composite.c (composition_gstring_put_cache):
* ftfont.c (ftfont_shape_by_flt): Use it to pacify GCC 4.6.0.

12 years ago* fns.c (Ffillarray): Don't shadow a local.
Paul Eggert [Sat, 18 Jun 2011 16:45:23 +0000 (09:45 -0700)]
* fns.c (Ffillarray): Don't shadow a local.

12 years agoUse define-derived-mode in delphi-mode.
Chong Yidong [Sat, 18 Jun 2011 16:23:11 +0000 (12:23 -0400)]
Use define-derived-mode in delphi-mode.

* lisp/progmodes/delphi.el (delphi-mode-syntax-table): Use defvar.
(delphi-mode): Use define-derived-mode to inherit from prog-mode.
Remove unused argument.

12 years ago* editfns.c: Omit unnecessary forward decls, to simplify future changes.
Paul Eggert [Sat, 18 Jun 2011 16:20:05 +0000 (09:20 -0700)]
* editfns.c: Omit unnecessary forward decls, to simplify future changes.

12 years ago* ftfont.c (ftfont_shape_by_flt): Use signed integers for lengths.
Paul Eggert [Sat, 18 Jun 2011 16:19:18 +0000 (09:19 -0700)]
* ftfont.c (ftfont_shape_by_flt): Use signed integers for lengths.

12 years ago* font.c (Ffont_shape_gstring): Don't assume glyph len fits in 'int'.
Paul Eggert [Sat, 18 Jun 2011 16:15:19 +0000 (09:15 -0700)]
* font.c (Ffont_shape_gstring): Don't assume glyph len fits in 'int'.

12 years ago* fns.c (mapcar1): Declare byte as byte, for clarity.
Paul Eggert [Sat, 18 Jun 2011 16:10:16 +0000 (09:10 -0700)]
* fns.c (mapcar1): Declare byte as byte, for clarity.

12 years ago* fns.c (Ffillarray): Use same idx as rest of code here.
Paul Eggert [Sat, 18 Jun 2011 16:07:41 +0000 (09:07 -0700)]
* fns.c (Ffillarray): Use same idx as rest of code here.

12 years ago* fns.c: Check that character arg fits in 'int'.
Paul Eggert [Sat, 18 Jun 2011 16:04:07 +0000 (09:04 -0700)]
* fns.c: Check that character arg fits in 'int'.

12 years ago* fns.c: Don't assume string byte-length fits in 'int'.
Paul Eggert [Sat, 18 Jun 2011 16:02:03 +0000 (09:02 -0700)]
* fns.c: Don't assume string byte-length fits in 'int'.

12 years ago* fns.c: Use much-faster test for byte-length change.
Paul Eggert [Sat, 18 Jun 2011 16:01:08 +0000 (09:01 -0700)]
* fns.c: Use much-faster test for byte-length change.

12 years ago* fns.c (Ffillarray): Don't assume bool vector size fits in 'int'.
Paul Eggert [Sat, 18 Jun 2011 15:57:22 +0000 (08:57 -0700)]
* fns.c (Ffillarray): Don't assume bool vector size fits in 'int'.

12 years ago* alloc.c (Fmake_bool_vector): Avoid unnecessary multiplication.
Paul Eggert [Sat, 18 Jun 2011 15:39:24 +0000 (08:39 -0700)]
* alloc.c (Fmake_bool_vector): Avoid unnecessary multiplication.

12 years agoOne more fix for display-buffer-normalize-specifiers-1.
Martin Rudalics [Sat, 18 Jun 2011 15:14:35 +0000 (17:14 +0200)]
One more fix for display-buffer-normalize-specifiers-1.

* window.el (display-buffer-normalize-specifiers-1): Fix thinko.

12 years ago* fns.c (concat): Catch string overflow earlier.
Paul Eggert [Sat, 18 Jun 2011 15:08:31 +0000 (08:08 -0700)]
* fns.c (concat): Catch string overflow earlier.

Do not rely on integer wraparound.

12 years agoAdditional fixes in handling of buffer display specifiers.
Martin Rudalics [Sat, 18 Jun 2011 14:23:14 +0000 (16:23 +0200)]
Additional fixes in handling of buffer display specifiers.

* window.el (display-buffer-default-specifiers): Remove
pop-up-frame.  Add pop-up-window-min-height,
pop-up-window-min-width, and another reuse-window specifier
(Bug#8882).  Reported by Dan Nicolaescu <dann@gnu.org>.
(display-buffer-normalize-specifiers-2): Handle
split-height-threshold and split-width-threshold also when
pop-up-windows is unset.  Add a reuse-window specifier for the
case popping up a new window fails.
(special-display-popup-frame): Remove double quoting.

12 years ago* dispextern.h (struct it.overlay_strings_charpos): EMACS_INT, not int.
Paul Eggert [Sat, 18 Jun 2011 05:51:59 +0000 (22:51 -0700)]
* dispextern.h (struct it.overlay_strings_charpos): EMACS_INT, not int.

12 years ago* dispextern.h (struct it.selective): Now EMACS_INT, not int.
Paul Eggert [Fri, 17 Jun 2011 19:55:19 +0000 (12:55 -0700)]
* dispextern.h (struct it.selective): Now EMACS_INT, not int.

* xdisp.c (forward_to_next_line_start)
(back_to_previous_visible_line_start)
(reseat_at_next_visible_line_start, next_element_from_buffer):
Don't arbitrarily truncate the value of 'selective' to int.

12 years ago* xdisp.c (init_iterator): Use XINT, not XFASTINT; it might be < 0.
Paul Eggert [Fri, 17 Jun 2011 19:49:04 +0000 (12:49 -0700)]
* xdisp.c (init_iterator): Use XINT, not XFASTINT; it might be < 0.

12 years ago* composite.c (get_composition_id, composition_gstring_put_cache): Use EMACS_INT,
Paul Eggert [Fri, 17 Jun 2011 19:45:29 +0000 (12:45 -0700)]
* composite.c (get_composition_id, composition_gstring_put_cache): Use EMACS_INT,

not EMACS_UINT, for indexes.

12 years ago* lisp/pcomplete.el: Convert to lexical binding and fix bug#8819.
Stefan Monnier [Fri, 17 Jun 2011 18:52:46 +0000 (14:52 -0400)]
* lisp/pcomplete.el: Convert to lexical binding and fix bug#8819.
(pcomplete-suffix-list): Mark as obsolete.
(pcomplete-completions-at-point): Capture pcomplete-norm-func and
pcomplete-seen in the closure.
(pcomplete-comint-setup): Setup completion-at-point as well.
(pcomplete--entries): New function.
(pcomplete--env-regexp): New var.
(pcomplete-entries): Rewrite to work with partial-completion and
without relying on pcomplete-suffix-list.
(pcomplete-pare-list): Remove, unused.
* lisp/shell.el (shell-completion-vars): Set pcomplete-termination-string
according to comint-completion-addsuffix.

12 years agoAuto-commit of generated files.
Glenn Morris [Fri, 17 Jun 2011 17:41:21 +0000 (13:41 -0400)]
Auto-commit of generated files.

12 years agoFix previous change.
Glenn Morris [Fri, 17 Jun 2011 17:32:58 +0000 (13:32 -0400)]
Fix previous change.

12 years agoSmall configure.in fix.
Glenn Morris [Fri, 17 Jun 2011 17:29:50 +0000 (13:29 -0400)]
Small configure.in fix.

Ref: http://lists.gnu.org/archive/html/emacs-buildstatus/2011-06/msg00007.html

* configure.in: Restore the behavior of checking crt-dir only
when the user specified it (not all platforms use it).

12 years agoUpdate doc-string of display-buffer-alist.
Martin Rudalics [Fri, 17 Jun 2011 16:07:55 +0000 (18:07 +0200)]
Update doc-string of display-buffer-alist.

12 years ago* src/fns.c (Fsafe_length): Yet another int/Lisp_Object mixup.
Stefan Monnier [Fri, 17 Jun 2011 15:18:54 +0000 (11:18 -0400)]
* src/fns.c (Fsafe_length): Yet another int/Lisp_Object mixup.

12 years agoRewrite display-buffer-alist and display-buffer-normalize-specifiers.
Martin Rudalics [Fri, 17 Jun 2011 14:50:11 +0000 (16:50 +0200)]
Rewrite display-buffer-alist and display-buffer-normalize-specifiers.

* window.el (display-buffer-alist): Set pop-up-window-min-height
and pop-up-window-min-width in default value.  Reported by
Thierry Volpiatto <thierry.volpiatto@gmail.com>.  New specifier
other-window-means-other-frame.
(display-buffer-macro-specifiers): Comment out entry for
other-window specifier.
(display-buffer-other-window-means-other-frame): New function.
(display-buffer-normalize-specifiers-1): New arguments
buffer-name and label.  Treat other-window case specially.
(display-buffer-normalize-specifiers-2): Treat other-window case
specially.
(display-buffer-normalize-specifiers-3): New function.
(display-buffer-normalize-specifiers): Call
display-buffer-normalize-specifiers-3.

12 years agoAuto-commit of generated files.
Glenn Morris [Fri, 17 Jun 2011 10:18:17 +0000 (06:18 -0400)]
Auto-commit of generated files.

12 years agoFix handling of old `display-buffer' options (bug#8851) (bug#8856).
Martin Rudalics [Fri, 17 Jun 2011 08:45:37 +0000 (10:45 +0200)]
Fix handling of old `display-buffer' options (bug#8851) (bug#8856).

* window.el (display-buffer-normalize-specifiers-1): Don't
check pop-up-frames for 'unset initialization.
(display-buffer-normalize-specifiers-2): Major rewrite using
special-display-p and same-window-p (Bug#8851) and (Bug#8856).
(pop-up-frames, display-buffer-reuse-frames)
(display-buffer-mark-dedicated): Don't initialize to 'unset.
Suggested by David Engster <deng@randomsample.de>.
(even-window-heights): Initialize to 'unset.
(display-buffer-alist-set): Handle new 'unset initializations.

12 years ago* composite.c: Don't truncate sizes to 'int'.
Paul Eggert [Fri, 17 Jun 2011 08:27:36 +0000 (01:27 -0700)]
* composite.c: Don't truncate sizes to 'int'.

(composition_gstring_p, composition_reseat_it)
(composition_adjust_point): Use EMACS_INT, not int.

12 years ago* category.h (CATEGORY_SET_P): Remove unnecessary cast to EMACS_INT.
Paul Eggert [Fri, 17 Jun 2011 08:17:29 +0000 (01:17 -0700)]
* category.h (CATEGORY_SET_P): Remove unnecessary cast to EMACS_INT.