Eli Zaretskii [Tue, 2 Aug 2011 19:16:32 +0000 (22:16 +0300)]
Fix bug #9218 with slow cursor motion and scrolling Org Mode buffers.
src/dispextern.h (struct bidi_it): New member disp_prop_p.
src/xdisp.c: Remove one-slot cache of display string positions.
(compute_display_string_pos): Accept an additional argument
DISP_PROP_P; callers changed. Scan at most 5K characters forward
for a display string or property. If found, set DISP_PROP_P
non-zero.
src/bidi.c (bidi_fetch_char): Accept an additional argument
DISP_PROP_P, and pass it to compute_display_string_pos. Only
handle text covered by a display string if DISP_PROP_P is returned
non-zero. All callers of bidi_fetch_char changed.
Martin Rudalics [Mon, 1 Aug 2011 18:10:58 +0000 (20:10 +0200)]
Don't set dedicated status for reused normal windows (Bug#9215).
* window.el (display-buffer-in-window): Don't set dedicated status
of window here (Bug#9215).
(display-buffer-pop-up-window, display-buffer-pop-up-frame)
(display-buffer-pop-up-side-window)
(display-buffer-in-side-window): Set dedicated status of window
here.
Eli Zaretskii [Mon, 1 Aug 2011 17:34:04 +0000 (20:34 +0300)]
Fix bug #9212 with selective-display under bidi.
src/xdisp.c (forward_to_next_line_start): Accept additional argument
BIDI_IT_PREV, and store into it the state of the bidi iterator had
on the newline.
(reseat_at_next_visible_line_start): Use the bidi iterator state
returned by forward_to_next_line_start to restore the state of
it->bidi_it after backing up to previous newline. (Bug#9212)
nnmaildir.el (nnmaildir-request-accept-article): Don't call `unix-sync' unless it's defined.
gnus-art.el (gnus-article-stop-animations): Use `elt' instead of `aref' for XEmacs compatibiltiy.
spam.el (spam-fetch-field-fast): Rewrite slightly for clarity.
gnus-sum.el (gnus-summary-refer-thread): Since lambdas aren't closures, quote the form properly (bug#9194).
gnus-sum.el (gnus-summary-insert-new-articles): Clean up slightly.
(gnus-summary-insert-new-articles): Protect against servers that are down.
Fix copyrights for javascript and python grammars.
Since these grammars were transcribed from the ECMAScript spec (BSD
licensed) and Python sources (PSL) respectively, the copyright and
license notices must be included in these files.
Juri Linkov [Sat, 30 Jul 2011 09:14:58 +0000 (12:14 +0300)]
* lisp/dired-aux.el (dired-touch-initial): Remove function.
(dired-do-chxxx): For op-symbol `touch', set `initial' to the
current time, and `default' to the last modification time of the
current marked file.
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.
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.