Merge from origin/emacs-27
acc9b46153
Fix merging of region face for non-ASCII charactersc2a13969e4
Make drag and drop on NS open all URLs (bug#43470)
This commit is contained in:
commit
950911373c
2 changed files with 7 additions and 12 deletions
|
@ -511,15 +511,9 @@ string dropped into the current buffer."
|
|||
(set-frame-selected-window nil window)
|
||||
(raise-frame)
|
||||
(setq window (selected-window))
|
||||
(cond ((memq 'ns-drag-operation-generic operations)
|
||||
;; Perform the default action for the type.
|
||||
(if (eq type 'file)
|
||||
(dolist (data objects)
|
||||
(dnd-handle-one-url window 'private (concat "file:" data)))
|
||||
(dnd-insert-text window 'private string)))
|
||||
((memq 'ns-drag-operation-copy operations)
|
||||
;; Try to open the file/URL. If type is nil, try to open
|
||||
;; it as a URL anyway.
|
||||
(cond ((or (memq 'ns-drag-operation-generic operations)
|
||||
(memq 'ns-drag-operation-copy operations))
|
||||
;; Perform the default/copy action.
|
||||
(dolist (data objects)
|
||||
(dnd-handle-one-url window 'private (if (eq type 'file)
|
||||
(concat "file:" data)
|
||||
|
|
|
@ -21998,6 +21998,7 @@ extend_face_to_end_of_line (struct it *it)
|
|||
in the text area has to be drawn to the end of the text area. */
|
||||
it->glyph_row->fill_line_p = true;
|
||||
|
||||
const int orig_face_id = it->face_id;
|
||||
/* If current character of IT is not ASCII, make sure we have the
|
||||
ASCII face. This will be automatically undone the next time
|
||||
get_next_display_element returns a multibyte character. Note
|
||||
|
@ -22198,6 +22199,7 @@ extend_face_to_end_of_line (struct it *it)
|
|||
if (stretch_width < 0)
|
||||
it->glyph_row->x = stretch_width;
|
||||
}
|
||||
it->face_id = orig_face_id;
|
||||
}
|
||||
else
|
||||
#endif /* HAVE_WINDOW_SYSTEM */
|
||||
|
@ -22207,7 +22209,6 @@ extend_face_to_end_of_line (struct it *it)
|
|||
struct text_pos saved_pos = it->position;
|
||||
Lisp_Object saved_object = it->object;;
|
||||
enum display_element_type saved_what = it->what;
|
||||
int saved_face_id = it->face_id;
|
||||
|
||||
it->what = IT_CHARACTER;
|
||||
memset (&it->position, 0, sizeof it->position);
|
||||
|
@ -22310,7 +22311,7 @@ extend_face_to_end_of_line (struct it *it)
|
|||
it->object = saved_object;
|
||||
it->position = saved_pos;
|
||||
it->what = saved_what;
|
||||
it->face_id = saved_face_id;
|
||||
it->face_id = orig_face_id;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue