1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-12 22:40:46 -08:00
Commit graph

35488 commits

Author SHA1 Message Date
Paul Eggert
be316ede5f Fix misdisplay of interlaced GIFs with libgif5.
* image.c (gif_load): libgif5 deinterlaces for us, so don't do
it again.

Fixes: debbugs:16372
2014-01-07 13:14:32 -08:00
Eli Zaretskii
9f4e49e93e Fix bug #16129 with slow and incorrect redisplay in follow-mode.
src/xdisp.c (redisplay_window): Don't skip window redisplay if the
 last value of point is not equal to buffer's point.
2014-01-06 18:28:26 +02:00
Paul Eggert
d5081c1ed8 Spelling fixes.
* calc/calc-yank.el (calc-edit-mode, calc-edit-cancel):
* emacs-lisp/debug.el (cancel-debug-on-entry):
* epg.el (epg-error-to-string):
* files.el (recover-file):
* lpr.el (lpr-buffer, print-buffer, lpr-region, print-region):
* mail/emacsbug.el (report-emacs-bug-hook):
* mail/sendmail.el (mail-recover):
* ses.el (ses-yank-resize):
* term/ns-win.el (ns-print-buffer):
Spelling fixes in diagnostics, mostly for "canceled" with one L.
* epg.el (epg-key-capability-alist): Rename from misspelled version.
All uses changed.
* obsolete/xesam.el (xesam-all-fields): Fix misspelled field name.
2014-01-05 22:25:30 -08:00
Paul Eggert
dc300e285a Spelling fix. 2014-01-04 20:56:23 -08:00
Paul Eggert
da5ecfa9b9 Spelling fixes.
* lib-src/Makefile.in (regex.o): Remove reference to no-longer-used macros
CONFIG_BROKETS and INHIBIT_STRING_HEADER.  "BROKETS" was a
misspelling anyway....
* src/nsterm.h (updateCollectionBehavior): Rename from
updateCollectionBehaviour.  All uses changed.
2014-01-04 18:56:08 -08:00
Paul Eggert
81da295eeb Port to GNU/Linux with recent grsecurity/PaX patches (Bug#16343).
Problem and proposed patch reported by Ulrich Mueller;
this patch uses a somewhat-different approach.
* configure.ac (SETFATTR): New variable.
* src/Makefile.in (SETFATTR): New macro.
(temacs$(EXEEXT)): Use it.
2014-01-04 16:55:29 -08:00
Martin Rudalics
5159d5902f Fix maximization behavior on Windows (Bug#16300).
Fix maximization behavior on Windows (Bug#16300).
* w32fns.c (w32_fullscreen_rect): Don't handle
FULLSCREEN_MAXIMIZED and FULLSCREEN_NONE specially.
* w32term.c (w32fullscreen_hook): Use SetWindowPlacement instead
of SetWindowPos.  Restore last placement also when leaving
FULLSCREEN_HEIGHT and FULLSCREEN_WIDTH.  Call ShowWindow in all
but the FULLSCREEN_BOTH case.
2014-01-04 10:31:30 +01:00
Paul Eggert
56a0e35287 Port to C89.
* data.c (arithcompare_driver):
* fileio.c (Fcar_less_than_car):
* fns.c (internal_equal):
* frame.c (delete_frame):
* lisp.h (enum More_Lisp_Bits):
* lread.c (read1):
Avoid C99 constructs that don't work in C89.
* data.c (ULL_MAX, count_trailing_zeros_ll): New macros,
to port to C89, which doesn't have 'long long'.
(count_trailing_zero_bits): Use them.
2014-01-02 22:47:27 -08:00
Paul Eggert
ed0ca4a51a Whitespace fixes for recently-added code. 2014-01-02 22:42:23 -08:00
Chong Yidong
0d53f628be Remove the dynamic-docstring-function feature.
* emacs-lisp/advice.el (ad--make-advised-docstring): Change args.
Ignore function-documentation property when getting documentation.
(ad-activate-advised-definition): Use function-documentation
generate the docstring.
(ad-make-advised-definition): Don't call
ad-make-advised-definition-docstring.
(ad-make-advised-definition-docstring, ad-advised-definition-p):
Delete functions.

* emacs-lisp/nadvice.el (advice--make-docstring): Change args.
(advice--docstring): Delete variable.
(advice--make-1): Leave the docstring empty.
(advice-add): Use function-documentation for advised docstring.

* progmodes/sql.el (sql-help): Use function-documentation instead
of dynamic-docstring-function property.  No need to autoload now.
(sql--help-docstring): New variable.
(sql--make-help-docstring): Use it.

* doc.c (Fdocumentation): Remove dynamic-docstring-function.
2014-01-03 13:37:58 +08:00
Martin Rudalics
44c5e192be Further adjust frame/window scrollbar width calculations.
* window.c (apply_window_adjustment): Set
windows_or_buffers_changed.
(Fwindow_scroll_bars): Return actual scrollbar width.
* xfns.c (x_set_scroll_bar_default_width): Rename wid to unit.
For non-toolkit builds again use 14 as minimum width and set
FRAME_CONFIG_SCROLL_BAR_WIDTH accordingly.
* xterm.c (XTset_vertical_scroll_bar): Take width from
WINDOW_SCROLL_BAR_AREA_WIDTH.
(x_new_font): Rename wid to unit.  Base calculation of new
scrollbar width on toolkit used and make it analogous to that of
x_set_scroll_bar_default_width.
* w32fns.c (x_set_scroll_bar_default_width): Rename wid to unit.
(Fx_create_frame): Call x_set_scroll_bar_default_width instead
of GetSystemMetrics.
* w32term.c (w32_set_vertical_scroll_bar): Take width from
WINDOW_SCROLL_BAR_AREA_WIDTH.
(x_new_font): Make it correspond to changes in xterm.c.
2014-01-02 16:58:48 +01:00
Paul Eggert
b483c5703d Prefer ASCII in doc and comments when the difference does not matter. 2014-01-01 15:13:59 -08:00
Paul Eggert
b00cdd96e9 * lisp.h (EMACS_INT): Configure based on INTPTR_MAX, not LONG_MAX.
This is a cleaner way to fix the MinGW-w64 porting problem.
Check for INTPTR_MAX misconfiguration.
2014-01-01 11:27:41 -08:00
Eli Zaretskii
c10e9ece08 Fix bug #16265 with buffer caches when modifying text in indirect buffers.
src/search.c (newline_cache_on_off, find_newline): In indirect
 buffers, use the newline cache of the base buffer.
 src/insdel.c (invalidate_buffer_caches): If BUF is an indirect
 buffer, invalidate the caches of its base buffer.
 src/indent.c (width_run_cache_on_off, compute_motion): In indirect
 buffers, use the width-run cache of the base buffer.
 src/xdisp.c (redisplay_window): When the window displays an indirect
 buffer, and the character widths in the display table have
 changed, invalidate the width-run cache of the corresponding base
 buffer.
 src/fileio.c (Finsert_file_contents): When invalidating the newline
 cache, consider the case of inserting into indirect buffer.
 src/bidi.c (bidi_paragraph_cache_on_off, bidi_find_paragraph_start):
 In indirect buffers, use the paragraph cache of the base buffer.
2014-01-01 19:44:48 +02:00
Paul Eggert
ba3189039a Update copyright year to 2014 by running admin/update-copyright. 2014-01-01 07:43:34 +00:00
Martin Rudalics
91415fb1cd Fix last change of grow_mini_window.
* window.c (grow_mini_window): Fix last change.
2013-12-31 20:06:18 +01:00
Jan Djärv
a230100696 * nsterm.m (windowDidResignKey:): Set mouse_moved to 0.
Fixes: debbugs:8421
2013-12-31 19:30:18 +01:00
Fabrice Popineau
bd717ca4f4 Minor fixes for MinGW64 build.
configure.ac (canonical, C_SWITCH_SYSTEM): Support a 64-bit
 MinGW64 build on MS-Windows.

 nt/inc/ms-w32.h (sys_kill): Fix prototype.

 src/w32term.c (w32_initialize): Use LCID and LOWORD.
 src/w32proc.c (create_child): Use pid_t for 5th argument.
 (IsValidLocale): Don't provide prototype for MinGW64.
 (Fw32_get_valid_keyboard_layouts, Fw32_get_keyboard_layout)
 (Fw32_set_keyboard_layout): Use HKL and HIWORD/LOWORD.
 src/w32heap.c (allocate_heap) [_WIN64]: Use "ull", not "i64", which
 MinGW64 doesn't support.
 src/lisp.h (EMACS_INT) [_WIN64]: Define for the MinGW64 build.
2013-12-31 18:01:34 +02:00
Eli Zaretskii
535f0fbd00 Fix typo in a comment in the last commit in w2.c. 2013-12-31 17:12:33 +02:00
Fabrice Popineau
0bbd0e0b1d Fall back on SetNamedSecurityInfo if SetFileSecurity fails in acl_set_file.
src/w32.c (set_named_security_info): New function.
 (acl_set_file): Fall back on set_named_security_info if
 set_file_security fails.  Fixes rare failures in backups.
 (g_b_init_set_named_security_info_w)
 (g_b_init_set_named_security_info_a): New static variables.
 (globals_of_w32): Initialize them to zero.
 (set_named_security_info): Set them to non-zero if the
 corresponding API is available.
 (SetNamedSecurityInfoW_Proc, SetNamedSecurityInfoA_Proc): New
 function typedefs.
2013-12-31 17:00:43 +02:00
Martin Rudalics
9b3c0a162e Some more fixes following pixelwise resize changes including one for Bug#16306.
* gtkutil.c (x_wm_set_size_hint): Have size hints respect value
of frame_resize_pixelwise.
* widget.c (pixel_to_text_size): New function.
(update_wm_hints): Have size hints respect value of
frame_resize_pixelwise.
(EmacsFrameResize): Alway process resize requests pixelwise.
* window.c (grow_mini_window): Make sure mini window is at least
one line tall.
* xdisp.c (display_menu_bar): Make sure menubar extends till
right end of frame.
* xfns.c (x_set_menu_bar_lines): Resize frame windows pixelwise.
(x_set_tool_bar_lines): Calculate pixelwise.
* xterm.c (x_wm_set_size_hint): Have size hints respect value of
frame_resize_pixelwise.
2013-12-31 10:48:54 +01:00
Juanma Barranquero
2db9da01bd src/fileio.c: Silence compiler warnings.
* fileio.c (Fcopy_file) [!WINDOWSNT]: Don't declare on Windows
variables not used there.
2013-12-30 23:36:44 +01:00
Eli Zaretskii
1b7259fce2 Fix bug #16299 with assertion violation in set-default-file-modes on Windows.
src/w32.c (sys_umask): New function.

 nt/inc/ms-w32.h (umask) [emacs]: Redirect to sys_umask.
2013-12-30 19:51:28 +02:00
Martin Rudalics
564eb533f9 Fix Bug#16284.
* dispnew.c (change_frame_size_1): Take old width of root window
from that window's pixel width.  Bug#16284.
2013-12-30 10:14:29 +01:00
Paul Eggert
a560b856b1 Plain copy-file no longer chmods an existing destination.
* doc/lispref/files.texi (Changing Files): Document this.
* etc/NEWS: Document this.
* src/fileio.c (realmask): Now a static var, not a local.
(barf_or_query_if_file_exists): New arg KNOWN_TO_EXIST.
Remove arg STATPTR.  All uses changed.
(Fcopy_file): Do not alter permissions of existing destinations,
unless PRESERVE-PERMISSIONS (renamed from
PRESERVE-EXTENDED-ATTRIBUTES) is non-nil.
Avoid race when testing for existing destinations and for
when input and output files are the same.
If changing the group fails, adjust both default and
preserved permissions so that access is not granted to the
wrong group.
(Fset_default_file_modes, init_fileio): Update realmask.
(Fdefault_file_modes): Use realmask instead of calling umask.

Fixes: debbugs:16133
2013-12-29 10:18:45 -08:00
Paul Eggert
45bd2734b1 * src/emacs.c (main): [DAEMON_MUST_EXEC]: Restore close-on-exec after exec.
Fixes: debbugs:16262
2013-12-28 23:42:46 -08:00
Paul Eggert
411bf4a486 Fix pipe bug with OS X emacs --daemon (Bug#16262).
* emacs.c (main) [DAEMON_MUST_EXEC]: Clear the close-on-exec
flags on the daemon pipe ends before execing.
2013-12-28 14:56:58 -08:00
Eli Zaretskii
8962d4b300 Fix a thinko in last commit. 2013-12-28 19:12:57 +02:00
Eli Zaretskii
bf7bea5de0 Fix bug #14739 with creation of GUI frames from TTY session on Windows.
src/w32fns.c (Fx_create_frame): Error out if called from a TTY
 session.

 lisp/frame.el (window-system-for-display): Don't allow to create a
 GUI frame from a -nw session on MS-Windows.
2013-12-28 13:47:26 +02:00
Glenn Morris
a544fbe1d1 ChangeLog fixes for font-locking 2013-12-27 18:17:54 -08:00
Juanma Barranquero
e9dc713d18 Fix ChangeLog typos. 2013-12-28 01:36:00 +01:00
Jarek Czekalski
fdadeb4997 Shell completion for filenames from current directory, related docs.
* lisp/shell.el  Shell completion now matches executable filenames from
	the current buffer's directory, on systems in which this behaviour
	is the default (windows-nt, ms-dos).
	* src/callproc.c (Vexec_path): Document that exec-directory is in it.
	* doc/emacs/mini.texi (Completion Options): Add a link to Shell Options.
	* doc/emacs/misc.texi (Shell Mode): Move documentation of
	shell-completion-fignore from Shell Mode to Shell Options.

Fixes: debbugs:15461
2013-12-27 21:58:21 +01:00
Julien Danjou
765fe182c4 Enable ns-use-srgb-colorspace by default
See thread
https://lists.gnu.org/archive/html/emacs-devel/2013-12/msg00706.html

* nsterm.m (syms_of_nsterm): Enable ns-use-srgb-colorspace by
default.
2013-12-27 11:43:11 +01:00
Chong Yidong
0f1d29342f More doc updates
* commands.texi (Reading One Event): Mention keyboard coding.

* functions.texi (Function Cells):
* eval.texi (Function Indirection): Update for the fact that
symbol-function no longer signals an error.

* keymaps.texi (Translation Keymaps, Translation Keymaps):
* nonascii.texi (Terminal I/O Encoding): Copyedits.

* data.c (Fsymbol_function): Doc fix.
2013-12-27 11:38:26 +08:00
Martin Rudalics
0cbab19e6e Some more tinkering with Bug#16051.
* window.c (resize_frame_windows): Don't let the size of the
root window drop below the frame's default character size.
Never ever delete any subwindows - let the window manager do the
clipping.

* w32fns.c (x_set_tool_bar_lines): Rewrite calculation of number
of toolbar lines needed when they exceed the height of the root
window.
(unwind_create_frame_1): New function.
(Fx_create_frame): Generally inhibit calling the window
configuration change hook here.  Remove extra call to
change_frame_size - it's not needed when we don't run the
configuration change hook.
2013-12-26 12:31:42 +01:00
Paul Eggert
e76119d754 Fix core dumps with gcc -fsanitize=address and GNU/Linux.
On my Fedora 19 platform the core dumps were so big that
my desktop became nearly catatonic.
* configure.ac: Check whether addresses are sanitized.
(CANNOT_DUMP): Warn if addresses are sanitized and not CANNOT_DUMP.
(DOUG_LEA_MALLOC): Do not define if addresses are sanitized.
(SYSTEM_MALLOC): Define if addresses are sanitized.
* src/alloc.c (no_sanitize_memcpy) [MAX_SAVE_STACK > 0]: New function.
(Fgarbage_collect) [MAX_SAVE_STACK > 0]: Use it.
(USE_ALIGNED_MALLOC): Do not define if addresses are sanitized.
(mark_memory): Use ATTRIBUTE_NO_SANITIZE_ADDRESS rather than
a clang-only syntax.
* src/conf_post.h (__has_feature): New macro, if not already defined.
(ADDRESS_SANITIZER, ADDRESS_SANITIZER_WORKAROUND)
(ATTRIBUTE_NO_SANITIZE_ADDRESS): New macros.
2013-12-26 00:57:28 -08:00
Eli Zaretskii
9ab3ce4d2f Fix bug #16252 with 'mailto:' documents passed to w32-shell-execute.
src/w32fns.c (Fw32_shell_execute): Make DOCUMENT absolute only if it
 is a file name.
2013-12-25 19:30:24 +02:00
Chong Yidong
c93525876d Doc updates for several Emacs 24.4 changes.
* doc/lispref/commands.texi (Event Input Misc): Document new arg to
input-pending-p.

* doc/lispref/display.texi (Font Selection): Tweak example.

* doc/lispref/keymaps.texi (Active Keymaps): Re-organize the text.
(Searching Keymaps): Rewrite the pseudo-code for 24.4 changes.
(Controlling Active Maps): Note that set-transient-map uses
overriding-terminal-local-map.

* doc/lispref/nonascii.texi (Specifying Coding Systems): Don't refer to
emacs-mule-dos.
(Lisp and Coding Systems): Describe emacs-mule return value in
modern terms.

* doc/lispref/tips.texi (Coding Conventions): Tweak the coding system tip;
Emacs now uses utf-8 by default for Emacs Lisp source files.

* doc/emacs/glossary.texi (Glossary): Define MULE in modern terms.

* src/keyboard.c (Voverriding_terminal_local_map):
(Voverriding_local_map): Doc fix.

* src/keymap.c (Vemulation_mode_map_alists): Doc fix.
2013-12-25 18:24:52 +08:00
Eli Zaretskii
a50fa60572 Attempt to catch backtrace of segfault in bug #16234. 2013-12-24 19:55:07 +02:00
Eli Zaretskii
ec6e26b811 Minor fixes in w32-shell-execute.
src/w32fns.c (Fw32_shell_execute): Ensure DOCUMENT is an absolute
 file name when it is submitted to ShellExecute.  Simplify code.
 Don't test DOCUMENT for being a string, as that is enforced by
 CHECK_STRING.  Doc fix.
2013-12-24 19:21:06 +02:00
Eli Zaretskii
cdcec25959 Last portion of fix for bug #16051 with redisplay loops.
src/xdisp.c (redisplay_tool_bar): Modify the tool-bar-lines frame parameter
 only when the new size is different from the old one, and the new
 size can be achieved given the frame height.
2013-12-23 21:24:25 +02:00
Eli Zaretskii
0db7548bea Fix most of bug #16051 with redisplay loops when resizing tool-bar.
src/xdisp.c (tool_bar_height): Use WINDOW_PIXEL_WIDTH to set up the
 iterator X limits, not FRAME_TOTAL_COLS, for consistency with what
 redisplay_tool_bar does.  Improve and fix commentary.
 (hscroll_window_tree): Don't assume w->cursor.vpos is within the
 limits of the glyph matrices.
2013-12-23 18:36:34 +02:00
Jan Djärv
30143e3d9b * src/conf_post.h: Use unsigned it for bool_bf if GNUSTEP.
Fixes: debbugs:16210
2013-12-23 13:07:46 +01:00
Glenn Morris
aec3bf9f49 Some documenting of load-prefer-newer
* doc/lispref/loading.texi (How Programs Do Loading, Load Suffixes):
Mention `load-prefer-newer'.

* src/lread.c (Fload): Mention load-prefer-newer in doc.
2013-12-22 18:54:28 -08:00
Martin Rudalics
a2b89a5195 Handle Bug#16207 by being more restrictive when running hooks.
* window.c (unwind_change_frame): New function.
(Fset_window_configuration): Don't run configuration change hook
while the frame configuration is unsafe.  Call select_window
twice.
2013-12-22 16:19:09 +01:00
Paul Eggert
61d208ade5 Spelling fix. 2013-12-21 23:23:49 -08:00
Xue Fuqiao
2dc383bc06 * src/lread.c (syms_of_lread) <load_prefer_newer>: Doc fix. 2013-12-22 08:52:26 +08:00
Jan Djärv
df8b4c3512 Changelog for previous checkin, missed to mark. 2013-12-21 17:12:52 +01:00
Jan Djärv
41cf3d118e Customize ns-use-srgb-colorspace on OSX >= 10.7 to use sRGB.
* etc/NEWS: Mention ns-use-srgb-colorspace.

* lisp/cus-start.el (all): Add ns-use-srgb-colorspace.

* src/nsfns.m (Fxw_color_values): Use colorUsingDefaultColorSpace.

* src/nsterm.h: Declare EmacsColor category.

* src/nsterm.m (NSColor): Implement EmacsColor category.
(ns_get_color): Use colorUsingDefaultColorSpace.
(ns_get_color, ns_term_init): Use colorForEmacsRed.
2013-12-21 17:11:55 +01:00
Eli Zaretskii
7667eeb9b5 Fix compilation warning on MS-Windows in my_png_error.
src/image.c (fn_png_longjmp) [WINDOWSNT]: Mark the function as
 having the PNG_NORETURN attribute, to avoid compiler warning in
 my_png_error.
2013-12-21 11:09:48 +02:00