Mercurial > emacs
changeset 111047:1e7d8f405703
Merge changes from emacs-23 branch.
author | Juanma Barranquero <lekktu@gmail.com> |
---|---|
date | Tue, 19 Oct 2010 13:44:07 +0200 |
parents | e02e55f79038 (current diff) f0ba7e7104ca (diff) |
children | 3c2bab829253 |
files | lisp/ChangeLog lisp/emacs-lisp/regexp-opt.el lisp/minibuffer.el lisp/repeat.el src/ChangeLog src/s/cygwin.h src/xftfont.c |
diffstat | 9 files changed, 73 insertions(+), 18 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/ChangeLog Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/ChangeLog Tue Oct 19 13:44:07 2010 +0200 @@ -1,3 +1,22 @@ +2010-10-19 Stefan Monnier <monnier@iro.umontreal.ca> + + * repeat.el (repeat): Use read-key (bug#6256). + +2010-10-19 Chong Yidong <cyd@stupidchicken.com> + + * emacs-lisp/unsafep.el: Don't mark functions that display + messages as safe. Suggested by Johan Bockgård. + +2010-10-19 Stefan Monnier <monnier@iro.umontreal.ca> + + * minibuffer.el (completion--replace): Move point where it belongs + when there's a common suffix (bug#7215). + +2010-10-19 Kenichi Handa <handa@m17n.org> + + * international/characters.el: Add category '|' (word breakable) + to fullwidth characters. + 2010-10-19 Michael Albinus <michael.albinus@gmx.de> * net/tramp-sh.el (tramp-do-file-attributes-with-stat)
--- a/lisp/emacs-lisp/regexp-opt.el Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/emacs-lisp/regexp-opt.el Tue Oct 19 13:44:07 2010 +0200 @@ -141,11 +141,10 @@ (require 'cl)) (defun regexp-opt-group (strings &optional paren lax) - ;; Return a regexp to match a string in the sorted list STRINGS. - ;; If PAREN non-nil, output regexp parentheses around returned regexp. - ;; If LAX non-nil, don't output parentheses if it doesn't require them. - ;; Merges keywords to avoid backtracking in Emacs' regexp matcher. - + "Return a regexp to match a string in the sorted list STRINGS. +If PAREN non-nil, output regexp parentheses around returned regexp. +If LAX non-nil, don't output parentheses if it doesn't require them. +Merges keywords to avoid backtracking in Emacs' regexp matcher." ;; The basic idea is to find the shortest common prefix or suffix, remove it ;; and recurse. If there is no prefix, we divide the list into two so that ;; \(at least) one half will have at least a one-character common prefix. @@ -239,9 +238,7 @@ (defun regexp-opt-charset (chars) - ;; - ;; Return a regexp to match a character in CHARS. - ;; + "Return a regexp to match a character in CHARS." ;; The basic idea is to find character ranges. Also we take care in the ;; position of character set meta characters in the character set regexp. ;;
--- a/lisp/emacs-lisp/unsafep.el Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/emacs-lisp/unsafep.el Tue Oct 19 13:44:07 2010 +0200 @@ -101,15 +101,13 @@ (dolist (x '(;;Special forms and catch if or prog1 prog2 progn while unwind-protect ;;Safe subrs that have some side-effects - ding error message minibuffer-message random read-minibuffer - signal sleep-for string-match throw y-or-n-p yes-or-no-p + ding error random signal sleep-for string-match throw ;;Defsubst functions from subr.el caar cadr cdar cddr ;;Macros from subr.el - save-match-data unless when with-temp-message + save-match-data unless when ;;Functions from subr.el that have side effects - read-passwd split-string replace-regexp-in-string - play-sound-file)) + split-string replace-regexp-in-string play-sound-file)) (put x 'safe-function t)) ;;;###autoload
--- a/lisp/international/characters.el Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/international/characters.el Tue Oct 19 13:44:07 2010 +0200 @@ -188,6 +188,9 @@ cp932-2-byte)) (map-charset-chars #'modify-category-entry l ?j)) +;; Fullwidth characters +(modify-category-entry '(#xff01 . #xff60) ?\|) + ;; Unicode equivalents of JISX0201-kana (let ((range '(#xff61 . #xff9f))) (modify-category-entry range ?k)
--- a/lisp/minibuffer.el Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/minibuffer.el Tue Oct 19 13:44:07 2010 +0200 @@ -508,10 +508,11 @@ (setq suffix-len (1+ suffix-len))) (unless (zerop suffix-len) (setq end (- end suffix-len)) - (setq newtext (substring newtext 0 (- suffix-len))))) - (goto-char beg) - (insert newtext) - (delete-region (point) (+ (point) (- end beg)))) + (setq newtext (substring newtext 0 (- suffix-len)))) + (goto-char beg) + (insert newtext) + (delete-region (point) (+ (point) (- end beg))) + (forward-char suffix-len))) (defcustom completion-cycle-threshold nil "Number of completion candidates below which cycling is used.
--- a/lisp/repeat.el Tue Oct 19 11:50:07 2010 +0200 +++ b/lisp/repeat.el Tue Oct 19 13:44:07 2010 +0200 @@ -335,7 +335,7 @@ (setq real-last-command 'repeat) (setq repeat-undo-count 1) (unwind-protect - (while (let ((evt (read-event))) ;FIXME: read-key maybe? + (while (let ((evt (read-key))) ;; For clicks, we need to strip the meta-data to ;; check the underlying event name. (eq (or (car-safe evt) evt)
--- a/src/ChangeLog Tue Oct 19 11:50:07 2010 +0200 +++ b/src/ChangeLog Tue Oct 19 13:44:07 2010 +0200 @@ -1,3 +1,16 @@ +2010-10-19 Ken Brown <kbrown@cornell.edu> + + * s/cygwin.h (SIGNALS_VIA_CHARACTERS): New define (bug#7225). + +2010-10-19 Kenichi Handa <handa@m17n.org> + + Fix incorrect font metrics when the same font is opened with + different pixelsizes. + + * xftfont.c: Include composite.h. + (xftfont_shape): New function. + (syms_of_xftfont): Set xftfont_driver.shape. + 2010-10-18 Julien Danjou <julien@danjou.info> * frame.c (Fframe_pointer_visible_p):
--- a/src/s/cygwin.h Tue Oct 19 11:50:07 2010 +0200 +++ b/src/s/cygwin.h Tue Oct 19 13:44:07 2010 +0200 @@ -101,5 +101,8 @@ returns ENOSYS. A workaround is to set G_SLICE=always-malloc. */ #define G_SLICE_ALWAYS_MALLOC +/* Send signals to subprocesses by "typing" special chars at them. */ +#define SIGNALS_VIA_CHARACTERS + /* arch-tag: 5ae7ba00-83b0-4ab3-806a-3e845779191b (do not change this comment) */
--- a/src/xftfont.c Tue Oct 19 11:50:07 2010 +0200 +++ b/src/xftfont.c Tue Oct 19 13:44:07 2010 +0200 @@ -32,6 +32,7 @@ #include "blockinput.h" #include "character.h" #include "charset.h" +#include "composite.h" #include "fontset.h" #include "font.h" #include "ftfont.h" @@ -664,6 +665,23 @@ return len; } +Lisp_Object +xftfont_shape (Lisp_Object lgstring) +{ + struct font *font; + struct xftfont_info *xftfont_info; + FT_Face ft_face; + Lisp_Object val; + + CHECK_FONT_GET_OBJECT (LGSTRING_FONT (lgstring), font); + xftfont_info = (struct xftfont_info *) font; + ft_face = XftLockFace (xftfont_info->xftfont); + xftfont_info->ft_size = ft_face->size; + val = ftfont_driver.shape (lgstring); + XftUnlockFace (xftfont_info->xftfont); + return val; +} + static int xftfont_end_for_frame (FRAME_PTR f) { @@ -753,6 +771,9 @@ xftfont_driver.draw = xftfont_draw; xftfont_driver.end_for_frame = xftfont_end_for_frame; xftfont_driver.cached_font_ok = xftfont_cached_font_ok; +#if defined (HAVE_M17N_FLT) && defined (HAVE_LIBOTF) + xftfont_driver.shape = xftfont_shape; +#endif register_font_driver (&xftfont_driver, NULL); }