diff options
| author | Eli Zaretskii | 2013-06-09 19:49:07 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2013-06-09 19:49:07 +0300 |
| commit | ad257d4f6c67ff216a1944acde6e9cf740922ae8 (patch) | |
| tree | e17842bf53653ac545d60690535be4fc5923c6e9 /src | |
| parent | 52fab9c9b8d690de6e8754995c0027767d356146 (diff) | |
| download | emacs-ad257d4f6c67ff216a1944acde6e9cf740922ae8.tar.gz emacs-ad257d4f6c67ff216a1944acde6e9cf740922ae8.zip | |
Fix current-bidi-paragraph-direction wrt window pointer.
src/xdisp.c (compute_display_string_pos): When W is NULL, use the current
buffer as the object to pass to get-char-property.
(Fcurrent_bidi_paragraph_direction): Assign NULL to the window
pointer member of the bidi iterator, since no window is pertinent
to this function.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/xdisp.c | 8 |
2 files changed, 10 insertions, 3 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 06b738e5043..94c5f76a76d 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -3,6 +3,11 @@ | |||
| 3 | * xdisp.c (get_it_property): If it->object is a buffer, pass to | 3 | * xdisp.c (get_it_property): If it->object is a buffer, pass to |
| 4 | get-char-property the window that is being rendered, instead of | 4 | get-char-property the window that is being rendered, instead of |
| 5 | the buffer, to support window-specific overlays. (Bug#14575) | 5 | the buffer, to support window-specific overlays. (Bug#14575) |
| 6 | (compute_display_string_pos): When W is NULL, use the current | ||
| 7 | buffer as the object to pass to get-char-property. | ||
| 8 | (Fcurrent_bidi_paragraph_direction): Assign NULL to the window | ||
| 9 | pointer member of the bidi iterator, since no window is pertinent | ||
| 10 | to this function. | ||
| 6 | 11 | ||
| 7 | 2013-06-08 Eli Zaretskii <eliz@gnu.org> | 12 | 2013-06-08 Eli Zaretskii <eliz@gnu.org> |
| 8 | 13 | ||
diff --git a/src/xdisp.c b/src/xdisp.c index 2097929128b..5edd4bbbc5f 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -3509,9 +3509,8 @@ compute_display_string_pos (struct text_pos *position, | |||
| 3509 | 3509 | ||
| 3510 | if (string && STRINGP (string->lstring)) | 3510 | if (string && STRINGP (string->lstring)) |
| 3511 | object1 = object = string->lstring; | 3511 | object1 = object = string->lstring; |
| 3512 | else if (!string_p) | 3512 | else if (w && !string_p) |
| 3513 | { | 3513 | { |
| 3514 | eassert (w != NULL); | ||
| 3515 | XSETWINDOW (object, w); | 3514 | XSETWINDOW (object, w); |
| 3516 | object1 = Qnil; | 3515 | object1 = Qnil; |
| 3517 | } | 3516 | } |
| @@ -20013,7 +20012,10 @@ See also `bidi-paragraph-direction'. */) | |||
| 20013 | itb.string.lstring = Qnil; | 20012 | itb.string.lstring = Qnil; |
| 20014 | itb.string.bufpos = 0; | 20013 | itb.string.bufpos = 0; |
| 20015 | itb.string.unibyte = 0; | 20014 | itb.string.unibyte = 0; |
| 20016 | itb.w = XWINDOW (selected_window); | 20015 | /* We have no window to use here for ignoring window-specific |
| 20016 | overlays. Using NULL for window pointer will cause | ||
| 20017 | compute_display_string_pos to use the current buffer. */ | ||
| 20018 | itb.w = NULL; | ||
| 20017 | bidi_paragraph_init (NEUTRAL_DIR, &itb, 1); | 20019 | bidi_paragraph_init (NEUTRAL_DIR, &itb, 1); |
| 20018 | bidi_unshelve_cache (itb_data, 0); | 20020 | bidi_unshelve_cache (itb_data, 0); |
| 20019 | set_buffer_temp (old); | 20021 | set_buffer_temp (old); |