Alp Aker [Thu, 28 Jul 2011 18:50:05 +0000 (14:50 -0400)]
Fix for raise display property on NS (Bug#8913).
* src/nsfont.m (nsfont_open): Remove assignment to voffset and
unnecessary vars hshink, expand, hd, full_height, min_height.
(nsfont_draw): Use s->ybase as baseline for glyph drawing.
Alp Aker [Thu, 28 Jul 2011 18:26:29 +0000 (14:26 -0400)]
Implement strike-through and overline on NextStep (Bug#8863).
* src/nsfont.m (nsfont_open): Use underline position provided by font,
instead of hard-coded value of 2.
(nsfont_draw): Call ns_draw_text_decoration instead.
* src/nsterm.h: Add declaration for ns_draw_text_decoration.
* src/nsterm.m (ns_draw_text_decoration): New function for drawing
underline, overline, and strike-through.
(ns_dumpglyphs_image, ns_dumpglyphs_stretch): Add call to
ns_draw_text_decoration. Change treatment of cursor drawing to
accomodate underlining, etc.
Eli Zaretskii [Thu, 28 Jul 2011 17:18:25 +0000 (20:18 +0300)]
Turn on bidi-display-reordering by default.
src/buffer.c (init_buffer_once, syms_of_buffer): Set
bidi-display-reordering to t by default.
doc/emacs/mule.texi (Bidirectional Editing): Document the fact that
bidi-display-reordering is t by default.
lispref/display.texi (Bidirectional Display): Document the fact that
bidi-display-reordering is t by default.
Alan Mackenzie [Tue, 26 Jul 2011 19:18:40 +0000 (19:18 +0000)]
Fontify bitfield declarations properly.
cc-langs.el (c-has-bitfields): New lang variable.
(c-symbol-chars): Now exported as a lang variable.
(c-not-primitive-type-keywords): New lang variable.
cc-fonts.el (c-font-lock-declarations): Jump over the QT keyword "more"
to prevent "more slots: ...." being spuriously parsed as a bitfield
declaraion.
cc-engine.el (c-beginning-of-statement-1): Refactor and enhance to handle
bitfield declarations.
(c-punctuation-in): New function.
(c-forward-decl-or-cast-1): Enhance CASE 3 to handle bitfield
declarations properly.
icalendar: Take care of multiple vcalendars in a single file.
lisp/ChangeLog:
* calendar/icalendar.el (icalendar--all-events): Take care of
multiple vcalendars in a single file.
(icalendar--convert-float-to-ical): checkdoc fixes.
* automated/icalendar-tests.el (icalendar-tests--compare-strings):
Removed, simply use string=.
(icalendar--diarytime-to-isotime)
(icalendar--datetime-to-diary-date)
(icalendar--datestring-to-isodate)
(icalendar--format-ical-event)
(icalendar--parse-summary-and-rest)
(icalendar-tests--do-test-import)
(icalendar-tests--do-test-cycle) : Changed argument order of
string= to EXPECTED ACTUAL.
(icalendar--import-format-sample)
(icalendar--format-ical-event)
(icalendar-import-non-recurring)
(icalendar-import-rrule)
(icalendar-import-duration)
(icalendar-import-bug-6766)
(icalendar-real-world): Adjusted to string= instead of
icalendar-tests--compare-strings.
(icalendar-import-multiple-vcalendars): New.
Eli Zaretskii [Mon, 25 Jul 2011 15:36:47 +0000 (18:36 +0300)]
Fix logic of caching display string positions for bidi display.
src/xdisp.c (compute_display_string_pos): Fix logic of caching
previous display string position. Initialize cached_prev_pos to -1.
Fixes slow-down at the beginning of a buffer.
Paul Eggert [Sun, 24 Jul 2011 22:15:47 +0000 (15:15 -0700)]
Merge from gnulib, using build-aux to remove clutter.
* m4/largefile.m4: New file, so that Emacs does not mess up when
accessing files with large inode numbers in MacOS X 10.5 and later.
* m4/nocrash.m4: New file, to avoid triggering background debugger
and/or create core dumps during 'configure'.
* build-aux/move-if-change: Renamed from move-if-change.
* build-aux/snippet/arg-nonnull.h: Renamed from arg-nonnull.h.
* build-aux/snippet/c++defs.h: Renamed from c++defs.h.
* build-aux/snippet/warn-on-use.h: Renamed from warn-on-use.h.
* build-aux/snippet/_Noreturn.h: New file, for draft C1X _Noreturn.
* .bzrignore: The autogenerated files compile, config.guess,
config.sub, depcomp, install-sh, and missing are now in build-aux.
* Makefile.in (epaths-force, sync-from-gnulib):
move-if-change is now in build-aux.
(GNULIB_TOOL_FLAGS): Avoid threadlib; this is now a prerequisite
of gnulib's pthread_sigmask module, but Emacs doesn't need it.
(mkdir): install-sh is now in build-aux.
* config.bat: c++defs.h is now in build-aux/snippets.
* configure.in: Specify AC_CONFIG_AUX_DIR with build-aux (the
usual parameter).
* lib/gnulib.mk, m4/gl-comp.m4: Regenerate.
* lib/makefile.w32-in (ARG_NONNULL_H): arg-nonnull.h moved
to build-aux/snippet.
* lib/pthread_sigmask.c, lib/stdlib.in.h, m4/extensions.m4:
* m4/getopt.m4, m4/gnulib-common.m4, m4/pthread_sigmask.m4:
Merge from gnuilib. This fixes porting bugs on Cygwin, Irix, and
Solaris, enables MacOS extensions, and enables nocrash during
'configure'.
* make-dist: Adjust to new build-aux and build-aux/snippit dirs.
* admin/notes/copyright: The files compile, config.guess, config.sub,
depcomp, install-sh, missing, and move-if-change are now in the
new build-aux subdirectory. The files arg-nonnull.h, c++defs.h,
and warn-on-use.h are now in build-aux/snippets. New file
build-aux/snippets/_Noreturn.h.
* leim/Makefile.in (install): install-sh is now in build-aux.
* lib-src/Makefile.in ($(DESTDIR)${archlibdir}): install-sh moved
to build-aux.
* msdos/sedlibmk.inp (CONFIG_CLEAN_VPATH_FILES): Adjust to snippet moves
from top level to build-aux/snippet.
* src/Makefile.in (gl-stamp): move-if-change is now in build-aux.
Michael Albinus [Sun, 24 Jul 2011 09:56:26 +0000 (11:56 +0200)]
* net/tramp-sh.el (tramp-barf-unless-okay): Return the value of
`tramp-send-command-and-check' if there is no error.
(tramp-send-command-and-read): Suppress *all* errors if NOERROR.
Andrew Cohen [Sun, 24 Jul 2011 00:19:29 +0000 (00:19 +0000)]
Merge changes made in Gnus trunk.
nnir.el (nnir-search-thread): New function to make an nnir group based on a thread query.
gnus-sum.el (gnus-refer-thread-use-nnir): New variable to control use of nnir in thread referral.
(gnus-summary-refer-thread): Use it.
nnimap.el (nnimap-request-thread): Use it.
Eli Zaretskii [Sat, 23 Jul 2011 10:46:21 +0000 (13:46 +0300)]
Fix pos-visible-in-window-p under bidi redisplay.
src/xdisp.c (move_it_in_display_line_to): Record the best matching
position for TO_CHARPOS while scanning the line, and restore it on
exit if none of the characters scanned was an exact match. Fixes
vertical-motion and pos-visible-in-window-p under bidi redisplay
when exact match is impossible due to invisible text, and the
lines are truncated.
Eli Zaretskii [Sat, 23 Jul 2011 10:42:24 +0000 (13:42 +0300)]
Fix pos-visible-in-window-p under bidi redisplay when lines are truncated.
src/xdisp.c (move_it_in_display_line_to): Record the best matching
position for TO_CHARPOS while scanning the line, and restore it on
exit if none of the characters scanned was an exact match. Fixes
vertical-motion and pos-visible-in-window-p when exact match is
impossible due to invisible text, and the lines are truncated.
Eli Zaretskii [Sat, 23 Jul 2011 07:42:56 +0000 (10:42 +0300)]
Speed up keyboard auto-repeat cursor motion under bidi redisplay.
src/xdisp.c (compute_stop_pos_backwards): New function.
(next_element_from_buffer): Call compute_stop_pos_backwards to
find a suitable prev_stop when we find ourselves before
base_level_stop.
(reseat): Don't look for prev_stop, as that could mean a very long
run.
<cached_disp_pos, cached_disp_buffer, cached_disp_modiff>
<cached_disp_overlay_modiff>: Cache for last found display string
position.
(compute_display_string_pos): Return the cached position if asked
about the same buffer in the same area of character positions, and
the buffer wasn't changed since the time the display string
position was cached.
Eli Zaretskii [Fri, 22 Jul 2011 14:09:51 +0000 (17:09 +0300)]
Fix previous change that broke faces in bidirectional text.
src/xdisp.c (compute_stop_pos_backwards): New function.
(handle_stop_backwards): Revert last change.
(next_element_from_buffer): Call compute_stop_pos_backwards to
find a suitable prev_stop when we find ourselves before
base_level_stop. Remove the funky search for 1000 character
positions back.
Martin Rudalics [Thu, 21 Jul 2011 08:27:44 +0000 (10:27 +0200)]
Fix size adjustment calls in display-buffer subroutines.
* window.el (display-buffer-pop-up-window)
(display-buffer-pop-up-side-window)
(display-buffer-in-side-window): Call display-buffer-set-height
and display-buffer-set-width after setting the new window's
buffer so `fit-window-to-buffer' and friends work on the right
buffer.
Sam Steingold [Wed, 20 Jul 2011 16:45:00 +0000 (12:45 -0400)]
* lisp/progmodes/etags.el (etags-file-of-tag, etags-tags-table-files)
(etags-tags-included-tables): Call `convert-standard-filename' on
the file names contained in TAGS so that windows Emacs can handle
TAGS files created by cygwin ctags.
Andrew Cohen [Wed, 20 Jul 2011 15:24:16 +0000 (15:24 +0000)]
nnir.el (gnus-group-make-nnir-group): Allow optional search query argument.
(gnus-group-make-nnir-group, nnir-request-group, nnir-run-query): Use `nnir-address' to handle server info rather than passing an arg.
Andrew Cohen [Wed, 20 Jul 2011 14:19:52 +0000 (14:19 +0000)]
Merge changes made in Gnus trunk.
nnimap.el (nnimap-make-thread-query): New utility function to format an imap thread search query.
(nnimap-request-thread): Use it.
gnus-sum.el (gnus-handle-ephemeral-exit): Ensure we are setting the right select-method if we are not going back to the group buffer.
gnus-group.el (gnus-group-read-ephemeral-group): Make sure we don't enter invalid buffer configurations into the quit form (bug#9107).
(gnus-group-tool-bar-gnome): Replace connect/disconnect with unplugged/plugged.
gnus-sum.el (gnus-summary-refer-thread): When inserting new headers, keep track of which ones are unread (bug#9061).
gnus.el (gnus-refer-article-method): Allow entering any sexp (bug#9055).
gnus-art.el (gnus-article-show-images): Allow working if using w3m (bug#9041).
gnus-html.el (mm-util): Require (bug#9073).
gnus-sum.el (gnus-delete-duplicate-headers): New function.
(gnus-summary-refer-thread): Use it to remove duplicates in the un-threaded view (bug#9053).
(gnus-summary-insert-subject): Document USE-OLD-HEADER (bug#9070).
nnir.el (nnir-read-server-parm): Use default value from global variable. Without this the default search engine parameters aren't used at all.
message.el (message-unique-id): Don't use the undocumented return value from (random t) (bug#9118).
Eli Zaretskii [Tue, 19 Jul 2011 18:04:56 +0000 (21:04 +0300)]
Speed up cursor motion in large fontified buffers.
src/xdisp.c (reseat): Don't look for prev_stop, as that could mean a
very long run.
(next_element_from_buffer): When iterator oversteps prev_pos
backwards, don't search for a new prev_stop more than 1000
characters back.
(handle_stop_backwards): Don't assume that CHARPOS is necessarily
a stop_pos.
(compute_display_string_pos): Check also BUF_OVERLAY_MODIFF for a
match, when testing the cached display string position for
applicability.
Paul Eggert [Tue, 19 Jul 2011 17:33:06 +0000 (10:33 -0700)]
Port to OpenBSD.
See http://lists.gnu.org/archive/html/emacs-devel/2011-07/msg00688.html
and the surrounding thread.
* minibuf.c (read_minibuf_noninteractive): Rewrite to use getchar
rather than fgets, and retry after EINTR. Otherwise, 'emacs
--batch -f byte-compile-file' fails on OpenBSD if an inactivity
timer goes off.
* s/openbsd.h (BROKEN_SIGIO): Define.
* unexelf.c (unexec) [__OpenBSD__]:
Don't update the .mdebug section of the Alpha COFF symbol table.
Paul Eggert [Mon, 18 Jul 2011 17:21:18 +0000 (10:21 -0700)]
* fileio.c (Fcopy_file): Adjust mode if fchown fails. (Bug#9002)
If fchown fails to set both uid and gid, try to set just gid,
as that is sometimes allowed. Adjust the file's mode to eliminate
setuid or setgid bits that are inappropriate if fchown fails.
Stefan Monnier [Mon, 18 Jul 2011 02:34:14 +0000 (22:34 -0400)]
* src/xdisp.c (next_element_from_string, next_element_from_buffer): Use EQ
to compare Lisp_Objects.
* src/gnutls.c (syms_of_gnutls): Rename Vgnutls_log_level to
global_gnutls_log_level, don't mistake it for a Lisp_Object.
(init_gnutls_functions, emacs_gnutls_handle_error): Fix up uses.