1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-10 01:34:36 -08:00
Commit graph

38348 commits

Author SHA1 Message Date
Eli Zaretskii
fbfd4787fb Avoid aborting due to errors in arguments of 'set-face-attribute'
* src/xfaces.c (Finternal_set_lisp_face_attribute): Check the
FRAME argument before using it.  This avoids gratuitous aborts in
Emacs built with --enable-checking when the luser was unlucky
enough to get the argument list in wrong order.
2016-05-24 19:04:16 +03:00
Eli Zaretskii
5ab083034c Provide workaround for xftfont rendering problem
* src/xftfont.c (syms_of_xftfont) <xft-font-ascent-descent-override>:
New variable.
(xftfont_open): Use it to work around problems with rendering some
fonts.  (Bug#23360)
2016-05-22 19:20:28 +03:00
Alan Third
06cb28ff3f Fix bug#23462: Crash when iconifying frame on OS X.
* src/nsterm.m (x_iconify_frame): Block input while miniaturize is
running.
2016-05-16 20:37:23 +02:00
Paul Eggert
9ca5dbf947 Avoid shrinking windows with Gtk+ 3.20.3
Problem reported by Matthias Clasen (Bug#23144).
This was fixed in a different way in master.
Do not merge to master.
* src/xterm.c (handle_one_xevent) [GTK_CHECK_VERSION (3, 20, 3)]:
Do not call xg_frame_resized in the MapNotify case.
2016-05-16 10:07:02 -07:00
Lars Ingebrigtsen
3b478989df Fix doc string in `insert'
* src/editfns.c (Finsert_and_inherit): The before-insertion
markers do not move.
(Finsert): Ditto.
2016-05-09 17:08:58 +02:00
Eli Zaretskii
4ffec91aa1 Document automatic adjustment of process' logical window dimensions
* doc/lispref/processes.texi (Process Buffers): Document
'set-process-window-size' and
'window-adjust-process-window-size-function'.

* etc/NEWS: Mention the new functionality and variable.

* src/process.c (Fset_process_window_size): Improve the doc string.
2016-05-07 12:16:27 +03:00
Paul Eggert
50650cb688 Doc fixes for fclist and grep
A newline is needed between two fc-list calls.
egrep and fgrep have been withdrawn from POSIX,
so document grep -E and grep -F instead.
2016-05-05 12:50:01 -07:00
Paul Eggert
2ea2a2f1a5 Doc fixes for quoting
* doc/emacs/text.texi, doc/lispintro/emacs-lisp-intro.texi:
* doc/lispref/control.texi, doc/lispref/display.texi:
* doc/lispref/help.texi, doc/lispref/strings.texi, lisp/subr.el:
* src/callint.c, src/doprnt.c, src/editfns.c:
Document quoting a bit more systematically.
Problem reported by Alan Mackenzie (Bug#23425).
2016-05-03 08:03:04 -07:00
Lars Ingebrigtsen
d1ab001b5b Fmarker_position doc string clarification
* src/marker.c (Fmarker_position): Clarify the doc string
(bug#21231).

(cherry picked from commit eeac7c5727)
2016-05-01 19:27:16 +02:00
Lars Ingebrigtsen
ec392ff1a3 cursor-type doc fix
* src/buffer.c (syms_of_buffer): Mention that cursor-type's
WIDHT/HEIGHT can't exceed the frame char size (bug#19215).

(cherry picked from commit 77c5f4554e)
2016-05-01 19:27:13 +02:00
Lars Ingebrigtsen
b04fcc4a38 Fcompare_buffer_substrings doc string clarification
* src/editfns.c (Fcompare_buffer_substrings): Extremely minor
doc string clarification (bug#19255).

(cherry picked from commit aa692acbb5)
2016-05-01 19:27:13 +02:00
Lars Ingebrigtsen
137868051e Have the doc strings of load-path' and require' mention each other
* src/fns.c (Frequire): Mention `load-path' and fill the doc
string (bug#18829).

* src/lread.c (syms_of_lread): Mention that `require' uses
`load-path'.

(cherry picked from commit 3eca9a0381)
2016-05-01 19:27:12 +02:00
Lars Ingebrigtsen
d815ba5348 Tiny doc fix
* src/fileio.c (Ffile_accessible_directory_p): Tiny doc fix
(and fill) (bug#18201).

(cherry picked from commit 2ef0040e23)
2016-05-01 19:27:11 +02:00
Lars Ingebrigtsen
7b85885797 Doc fix
* src/keymap.c (Fdefine_prefix_command): Clarify doc string
slightly (bug#18092).

(cherry picked from commit 6b769c81d0)
2016-05-01 19:27:10 +02:00
Lars Ingebrigtsen
de8349e125 Doc string change to enable-recursive-minibuffers
* src/minibuf.c (syms_of_minibuf): Mention
minibuffer-depth-indicator-mode in the doc string to
enable-recursive-minibuffers (bug#14147).

(cherry picked from commit 23ba488a5e)
2016-05-01 19:27:07 +02:00
Lars Ingebrigtsen
cf33ae0c12 Clarify the `interactive' doc string slightly
* src/callint.c (Finteractive): Clarify the doc string slightly
  (bug#14577).

(cherry picked from commit cd993be60d)
2016-05-01 19:27:07 +02:00
Paul Eggert
d8affa3dc5 Use ‘T *restrict’ proto, not ‘T[restrict]’
* src/fns.c (sort_vector_copy): Use a different way to attempt to
work around GCC 3.0-and-earlier incompatibility with C99, one that
does not have problems with modern non-GCC compilers.
2016-05-01 09:01:06 -07:00
Eli Zaretskii
ccdaf04cfd Fix the MSDOS build
* config.bat:
* msdos/sedlisp.inp:
* msdos/sedlibmk.inp:
* msdos/sedleim.inp:
* msdos/sedadmin.inp:
* msdos/sed6.inp:
* msdos/sed3v2.inp:
* msdos/sed2v2.inp:
* msdos/sed1v2.inp: Adapt to Emacs 25.

* src/process.c (remove_slash_colon): Move out of "#ifdef
subprocesses" block, as it its called unconditionally.  Move
ADD_SUBFEATURE calls into "#ifdef subprocesses" block, as they
reference variables only defined in that block.
* src/msdos.h: Provide prototypes for IT_set_frame_parameters,
faccessat, msdos_fatal_signal, syms_of_msdos, pthread_sigmask,
dos_keysns, dos_keyread, run_msdos_command, and
syms_of_win16select, to avoid compiler warnings.
* src/msdos.c (SYS_ENVIRON): Define to either '_environ' or
'environ', depending on the DJGPP version.
Remove declarations of externally-visible Lisp objects, like
Qbackground_color and Qreverse.
(run_msdos_command): First argument is not signed, not unsigned.
Use SYS_ENVIRON.
(sys_select): Use 'timespec_cmp' instead of 'timespec_sign', as
the latter doesn't work when 'time_t' is an unsigned data type.
This caused idle timers to behave incorrectly: they only fired
after a keyboard input event.
* src/frame.c (adjust_frame_size) [MSDOS]: Account for
FRAME_TOP_MARGIN that isn't counted in the frame's number of
lines, but dos_set_window_size needs it to be added.
* src/lread.c (INFINITY, NAN) [DJGPP < 2.05]: Provide definitions.
* src/fns.c (sort_vector_copy) [__GNUC__ < 4]: Provide a prototype
that works around compilation errors with older GCC versions.
* src/w16select.c: Don't declare QCLIPBOARD and QPRIMARY as Lisp
Objects.
* src/filelock.c [MSDOS]: Ifdef away most of the code.  Provide
no-op implementations for 'lock_file' and 'unlock_file'.
(Ffile_locked_p) [MSDOS]: Always return nil.  This avoids multiple
ifdefs in all users of filelock.c functionality.
* src/conf_post.h (EOVERFLOW, SIZE_MAX) [DJGPP < 2.04]: Define.
* src/emacs.c [MSDOS]: Include dosfns.h, to avoid compiler
warnings.
* src/dosfns.h: Provide prototypes for dos_cleanup,
syms_of_dosfns, and init_dosfns.
* src/deps.mk (atimer.o): Depend on msdos.h.
(emacs.o): Depend on dosfns.h.
* src/atimer.c [MSDOS]: Include msdos.h, to avoid compiler
warnings.

* lisp/window.el (window--adjust-process-windows): Skip the body
if 'process-list' is not available.  This avoids failure to start
up on MS-DOS.
* lisp/vc/diff.el (diff-no-select): Test 'make-process', not
'start-process', as the latter is now available on all platforms.
* lisp/textmodes/ispell.el (ispell-async-processp): Replace
'start-process' with 'make-process' in a comment.
* lisp/term/internal.el (IT-unicode-translations): Modify and add
a few translations to display Info files with Unicode markup.  Fix
an ancient off-by-one mismatch error with Unicode codepoints.
* lisp/progmodes/compile.el (compilation-start): Test
'make-process', not 'start-process', as the latter is now
available on all platforms.
* lisp/man.el (Man-build-man-command, Man-getpage-in-background):
Test 'make-process', not 'start-process', as the latter is now
available on all platforms.
* lisp/international/mule-cmds.el (set-coding-system-map): Test
'make-process', not 'start-process', as the latter is now
available on all platforms.
* lisp/eshell/esh-cmd.el (eshell-do-pipelines-synchronously): Doc
fix.
(eshell-execute-pipeline): Test 'make-process', not
'start-process', as the latter is now available on all platforms.
2016-04-30 13:45:33 +03:00
Paul Eggert
734fb3ac6c Port dumping to NetBSD with PaX
Problem reported by Thomas Klausner (Bug#23371).
* configure.ac (PAXCTL_dumped, PAXCTL_notdumped): New vars.
Set them to setfattr and/or paxctl commands appropriate for
GNU/Linux and/or NetBSD; the latter prefers paxctl +a.  Search
for paxctl only if setfattr is not found.
* src/Makefile.in (PAXCTL_dumped, PAXCTL_notdumped):
New vars, replacing PAXCTL_if_present and SETFATTR_if_present.
All uses changed.
2016-04-27 16:03:50 -07:00
Paul Eggert
c30d1b4a1b Port to Ubuntu 16.04 --enable-gcc-warnings
* src/image.c (gif_load) [HAVE_GIF]: Fix pointer signedness problem.
2016-04-24 13:39:34 -07:00
Martin Rudalics
2b31a0c21e In x_set_window_size restore do_pending_window_change calls
* src/xterm.c (x_set_window_size):
* src/w32term.c (x_set_window_size): Restore
do_pending_window_change calls after their stupid removal on
2015-08-31.
2016-04-22 11:56:03 +02:00
Ilya Zakharevich
401857eda3 Fix Alt-modified keys on some European MS-Windows keyboards
* src/w32fns.c (deliver_wm_chars): If the reported character is
ASCII, AND Meta modifier is a candidate, behave as if Meta is
present, i.e. fall back to the legacy code.  (Bug#23251)
2016-04-21 19:08:16 +03:00
Paul Eggert
ae712666bb Port to GCC 5.3.1 20160406 (Red Hat 5.3.1-6)
* src/indent.c (Fvertical_motion): Pacify --enable-gcc-warnings
when using the April 6 Fedora patch to GCC.
2016-04-16 19:49:31 -07:00
Eli Zaretskii
ab849b7fac Fix w32 memory-management problem when extending buffer text
* src/w32heap.c (mmap_realloc): Only attempt extending a region if
the following region has the same allocation base.  Also, use the
original allocation base and enlarged size to commit reserved
memory, to ensure that the allocation base stays at its original
value.  This fixes several hard-to-debug problems whereby part of
buffer text was overwritten with binary nulls, because
mmap_realloc copied only part of buffer text when extending it.
See
http://lists.gnu.org/archive/html/emacs-devel/2016-04/msg00325.html
and http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23223#55 for two
examples of the related problems.
2016-04-15 17:26:37 +03:00
Paul Eggert
32364bbbaa substitute-command-keys keeps quotes’ text props
Problem reported by Clément Pit--Claudel (Bug#23254).
* src/doc.c: Include intervals.h.
(Fsubstitute_command_keys): If the only substitutions are for
quotes, copy the source string’s text properties too, since no
substring lengths have changed.
2016-04-14 08:23:00 -07:00
YAMAMOTO Mitsuharu
567ab529f3 * src/xwidget.c (x_draw_xwidget_glyph_string): More clipping fixes. 2016-04-14 07:47:55 +09:00
Paul Eggert
ca50981001 Improve time zone documentation
* doc/lispref/os.texi (Time Zone Rules):
New section, mostly with material moved here from other sections.
* doc/emacs/cmdargs.texi (General Variables):
* doc/lispref/os.texi (Time Conversion, Time Parsing):
Xref new section.
* etc/NEWS, etc/PROBLEMS:
* lisp/org/org.el (org-timestamp-format):
* src/editfns.c (Fformat_time_string, Fdecode_time)
(Fencode_time, Fcurrent_time_string, Fcurrent_time_zone)
(Fset_time_zone_rule):
When documenting time zone rule strings, mention the TZ
environment variable in preference to mentioning the
sort-of-internal function set-time-zone-rule.
2016-04-12 08:49:19 -07:00
YAMAMOTO Mitsuharu
9344612d3c Disable multicolor fonts on OS X since they are not supported on free systems
* src/macfont.m (macfont_list): Don't use color bitmap fonts.
2016-04-12 08:27:24 +09:00
Paul Eggert
488a72f8e3 ; Spelling fixes 2016-04-10 23:55:05 -07:00
Philipp Stephani
b57076929f Remove undefined behavior in OS X dumper.
Found by Address Sanitizer.

* src/unexmacosx.c (unexec_write): Use Mach virtual memory API to
avoid undefined behavior when reading arbitrary memory.
2016-04-09 12:54:45 -07:00
Joakim Verona
97211f3630 Fix clipping of xwidgets
* src/xwidget.c (x_draw_xwidget_glyph_string): Use window_box
instead of calculating the clipping borders manually.  Suggested
by YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>.
2016-04-09 15:04:54 +03:00
Paul Eggert
3283271253 * src/xsmfns.c (syms_of_xsmfns): Remove stray "s in doc strings. 2016-04-08 16:30:23 -07:00
Alan Third
f6497c6e76 Set locale encoding to UTF-8 when run from OS X GUI.
* src/nsterm.m (ns_init_locale): Append .UTF-8 when setting LANG.
2016-04-08 15:52:55 +02:00
Eli Zaretskii
787df9dd05 ; * src/keyboard.c (read_char): Fix typos in a comment. 2016-04-03 20:06:51 +03:00
Paul Eggert
13c8f29ce3 make-xwidget unused arg cleanup
* doc/lispref/display.texi (Xwidgets): Remove stray refs.
* src/xwidget.c (syms_of_xwidget): Qwebkit, not Qwebkit_osr.
2016-04-02 18:32:13 -07:00
Joakim Verona
36e05f0bf7 Remove unused arguments from make-xwidget
The arguments BEG and END were unused, and are now removed.

* display.texi (Xwidgets): Document the change
* xwidget.el (make-xwidget, xwidget-insert)
(xwidget-webkit-new-session): Reflect changed arguments
* xwidget.c (Fmake_xwidget, syms_of_xwidget): Reflect changed arguments
2016-04-02 18:32:13 -07:00
Eli Zaretskii
b3b523cdd6 Avoid crashes due to insanely large columns in tabulated-list-format
* src/xdisp.c (append_stretch_glyph, produce_xwidget_glyph)
(produce_image_glyph): Limit the pixel width of the produced glyph
to SHRT_MAX.  (Bug#23178)
(append_composite_glyph, append_glyph, append_glyphless_glyph):
Add assertions to verify that the pixel width of the glyph will
never overflow a 'short'.
* src/term.c (append_composite_glyph): Add assertion to verify
that the pixel width of the glyph will never overflow a 'short'.
2016-04-01 12:47:29 +03:00
Eli Zaretskii
06495c96ae Fix rare problems with echo-area display and multiple frames
* src/xdisp.c (redisplay_window): Bind inhibit-redisplay non-nil
around the call to x_consider_frame_title, to prevent
resize_mini_window from undoing echo-area display.  (Bug#23124)
2016-03-29 20:38:54 +03:00
Paul Eggert
e65c3079c6 * src/font.c (QCuser_spec): Add missing colon to :user-spec. 2016-03-27 15:03:12 -07:00
YAMAMOTO Mitsuharu
278c8a7ef7 * src/xwidget.c (Fxwidget_resize): Fix inappropriate use of XFASTINT. 2016-03-27 18:00:08 +09:00
Eli Zaretskii
cf40f389cf Ignore non-nil. non-cons values of unread-command-events
* src/keyboard.c (requeued_events_pending_p, read_char)
(Finput_pending_p): Use CONSP instead of !NILP to see if there are
unread command events to be processed.  (Bug#22976)
2016-03-26 11:52:12 +03:00
Eli Zaretskii
8ee4c52abc Improve documentatuon of 'truncate-partial-width-windows'
* src/xdisp.c (syms_of_xdisp) <truncate-partial-width-windows>:
Clarify in the doc string how the width of partial-width windows
is computed for the purposes of truncation decision.  (Bug#4338)

* doc/emacs/windows.texi (Split Window): Clarify how the width of
windows is calculated for the purposes of truncation decision.
* doc/emacs/display.texi (Line Truncation): Remove a redundant
index entry.
2016-03-26 10:17:12 +03:00
Paul Eggert
fb9a62c9c4 * src/ftfont.c (ftfont_shape_by_flt): Parenthesize as per GNU style. 2016-03-25 11:00:23 -07:00
Eli Zaretskii
e70ee9d680 Fix scrolling upwards with 'xwidget-webkit-browse-url'
* src/xwidget.c (Fxwidget_set_adjustment): Use CHECK_NUMBER instead
of CHECK_NATNUM.  Suggested by Shayan Pirani <shayanpirani@gmail.com>.
(Bug#22918)
2016-03-25 12:51:57 +03:00
K. Handa
44782dea43 Fix display of Indic scripts
* ftfont.c (ftfont_shape_by_flt): For combining characters out
of the range U+300...U+36F, use the "combining" FLT only with
non-OTF fonts.
2016-03-25 12:40:25 +03:00
Eli Zaretskii
326c64fcc3 Fix splash screen display at startup
* src/frame.c (DEFAULT_ROWS): Enlarge to 36, so that the initial
window displayed by "emacs -q" has enough space to show the whole
text even if it includes 2 lines talking about recovering crashes
sessions.  (Bug#23074)

* lisp/startup.el (use-fancy-splash-screens-p): Fix off-by-one
error when computing the window-height from frame-height.

* etc/NEWS: Mention the change.
2016-03-25 10:45:39 +03:00
Paul Eggert
45577d548d Avoid GTK 3 crash with icons and masks
Problem reported by Mosè Giordano (Bug#18997).
* src/gtkutil.c (xg_get_pixbuf_from_pixmap): Remove.
(xg_get_pixbuf_from_pix_and_mask): Do not use
xg_get_pixbuf_from_pixmap, as it is poorly documented.  Instead,
invoke XGetPixel directly.  This is slow but speed is not
important here.  Also, fail for unusual situations (not TrueColor,
or images that are not 8 bits per sample) instead of displaying
junk or crashing.
2016-03-24 16:53:23 -07:00
Eli Zaretskii
077b78cffc Define make_save_ptr_ptr unconditionally
* src/alloc.c (make_save_ptr_ptr): Remove the !(defined
USE_X_TOOLKIT || defined USE_GTK) conditional.  Reported by
Philipp Stephani <phst@google.com>.  (Bug#23101)
2016-03-24 20:52:45 +02:00
Eli Zaretskii
20a1003f6d Preserve current buffer when popping up TTY menus
* src/term.c (tty_menu_show): Be sure to save and restore the
current buffer around TTY menu pop-ups.  (Bug#23101)
2016-03-24 20:05:49 +02:00
Eli Zaretskii
7eba90c122 Improve font selection by family on MS-Windows
* src/w32font.c (w32font_list_internal): Allow 'ascii-0' charset,
in addition to 'iso10646-1', 'unicode-bmp', and 'unicode-sip'.
This avoids rejecting many font families whose members are shown
by 'font-family-list', in particular 'courier' requested by
info.el.  Without this change, many values of ':family' attribute
of a face have no effect on MS-Windows, because they are rejected
due to bogus mismatch of the charset.
2016-03-24 18:30:41 +02:00