aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog19
-rw-r--r--lisp/emacs-lisp/regexp-opt.el13
-rw-r--r--lisp/emacs-lisp/unsafep.el8
-rw-r--r--lisp/international/characters.el3
-rw-r--r--lisp/minibuffer.el9
-rw-r--r--lisp/repeat.el2
-rw-r--r--src/ChangeLog13
-rw-r--r--src/s/cygwin.h3
-rw-r--r--src/xftfont.c21
9 files changed, 73 insertions, 18 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index ed11b1c19b1..8d9a1a46bf6 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,22 @@
12010-10-19 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * repeat.el (repeat): Use read-key (bug#6256).
4
52010-10-19 Chong Yidong <cyd@stupidchicken.com>
6
7 * emacs-lisp/unsafep.el: Don't mark functions that display
8 messages as safe. Suggested by Johan Bockgård.
9
102010-10-19 Stefan Monnier <monnier@iro.umontreal.ca>
11
12 * minibuffer.el (completion--replace): Move point where it belongs
13 when there's a common suffix (bug#7215).
14
152010-10-19 Kenichi Handa <handa@m17n.org>
16
17 * international/characters.el: Add category '|' (word breakable)
18 to fullwidth characters.
19
12010-10-19 Michael Albinus <michael.albinus@gmx.de> 202010-10-19 Michael Albinus <michael.albinus@gmx.de>
2 21
3 * net/tramp-sh.el (tramp-do-file-attributes-with-stat) 22 * net/tramp-sh.el (tramp-do-file-attributes-with-stat)
diff --git a/lisp/emacs-lisp/regexp-opt.el b/lisp/emacs-lisp/regexp-opt.el
index 6389b62ea04..116d7b93d90 100644
--- a/lisp/emacs-lisp/regexp-opt.el
+++ b/lisp/emacs-lisp/regexp-opt.el
@@ -141,11 +141,10 @@ This means the number of non-shy regexp grouping constructs
141 (require 'cl)) 141 (require 'cl))
142 142
143(defun regexp-opt-group (strings &optional paren lax) 143(defun regexp-opt-group (strings &optional paren lax)
144 ;; Return a regexp to match a string in the sorted list STRINGS. 144 "Return a regexp to match a string in the sorted list STRINGS.
145 ;; If PAREN non-nil, output regexp parentheses around returned regexp. 145If PAREN non-nil, output regexp parentheses around returned regexp.
146 ;; If LAX non-nil, don't output parentheses if it doesn't require them. 146If LAX non-nil, don't output parentheses if it doesn't require them.
147 ;; Merges keywords to avoid backtracking in Emacs' regexp matcher. 147Merges keywords to avoid backtracking in Emacs' regexp matcher."
148
149 ;; The basic idea is to find the shortest common prefix or suffix, remove it 148 ;; The basic idea is to find the shortest common prefix or suffix, remove it
150 ;; and recurse. If there is no prefix, we divide the list into two so that 149 ;; and recurse. If there is no prefix, we divide the list into two so that
151 ;; \(at least) one half will have at least a one-character common prefix. 150 ;; \(at least) one half will have at least a one-character common prefix.
@@ -239,9 +238,7 @@ This means the number of non-shy regexp grouping constructs
239 238
240 239
241(defun regexp-opt-charset (chars) 240(defun regexp-opt-charset (chars)
242 ;; 241 "Return a regexp to match a character in CHARS."
243 ;; Return a regexp to match a character in CHARS.
244 ;;
245 ;; The basic idea is to find character ranges. Also we take care in the 242 ;; The basic idea is to find character ranges. Also we take care in the
246 ;; position of character set meta characters in the character set regexp. 243 ;; position of character set meta characters in the character set regexp.
247 ;; 244 ;;
diff --git a/lisp/emacs-lisp/unsafep.el b/lisp/emacs-lisp/unsafep.el
index 851a1f7652b..a62f8de4010 100644
--- a/lisp/emacs-lisp/unsafep.el
+++ b/lisp/emacs-lisp/unsafep.el
@@ -101,15 +101,13 @@ in the parse.")
101(dolist (x '(;;Special forms 101(dolist (x '(;;Special forms
102 and catch if or prog1 prog2 progn while unwind-protect 102 and catch if or prog1 prog2 progn while unwind-protect
103 ;;Safe subrs that have some side-effects 103 ;;Safe subrs that have some side-effects
104 ding error message minibuffer-message random read-minibuffer 104 ding error random signal sleep-for string-match throw
105 signal sleep-for string-match throw y-or-n-p yes-or-no-p
106 ;;Defsubst functions from subr.el 105 ;;Defsubst functions from subr.el
107 caar cadr cdar cddr 106 caar cadr cdar cddr
108 ;;Macros from subr.el 107 ;;Macros from subr.el
109 save-match-data unless when with-temp-message 108 save-match-data unless when
110 ;;Functions from subr.el that have side effects 109 ;;Functions from subr.el that have side effects
111 read-passwd split-string replace-regexp-in-string 110 split-string replace-regexp-in-string play-sound-file))
112 play-sound-file))
113 (put x 'safe-function t)) 111 (put x 'safe-function t))
114 112
115;;;###autoload 113;;;###autoload
diff --git a/lisp/international/characters.el b/lisp/international/characters.el
index cf43bb1e6ca..e33f1449357 100644
--- a/lisp/international/characters.el
+++ b/lisp/international/characters.el
@@ -188,6 +188,9 @@ Combining diacritic or mark (Unicode General Category M)")
188 cp932-2-byte)) 188 cp932-2-byte))
189 (map-charset-chars #'modify-category-entry l ?j)) 189 (map-charset-chars #'modify-category-entry l ?j))
190 190
191;; Fullwidth characters
192(modify-category-entry '(#xff01 . #xff60) ?\|)
193
191;; Unicode equivalents of JISX0201-kana 194;; Unicode equivalents of JISX0201-kana
192(let ((range '(#xff61 . #xff9f))) 195(let ((range '(#xff61 . #xff9f)))
193 (modify-category-entry range ?k) 196 (modify-category-entry range ?k)
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el
index 98380f3926e..ee1fcae3119 100644
--- a/lisp/minibuffer.el
+++ b/lisp/minibuffer.el
@@ -508,10 +508,11 @@ Moves point to the end of the new text."
508 (setq suffix-len (1+ suffix-len))) 508 (setq suffix-len (1+ suffix-len)))
509 (unless (zerop suffix-len) 509 (unless (zerop suffix-len)
510 (setq end (- end suffix-len)) 510 (setq end (- end suffix-len))
511 (setq newtext (substring newtext 0 (- suffix-len))))) 511 (setq newtext (substring newtext 0 (- suffix-len))))
512 (goto-char beg) 512 (goto-char beg)
513 (insert newtext) 513 (insert newtext)
514 (delete-region (point) (+ (point) (- end beg)))) 514 (delete-region (point) (+ (point) (- end beg)))
515 (forward-char suffix-len)))
515 516
516(defcustom completion-cycle-threshold nil 517(defcustom completion-cycle-threshold nil
517 "Number of completion candidates below which cycling is used. 518 "Number of completion candidates below which cycling is used.
diff --git a/lisp/repeat.el b/lisp/repeat.el
index 86484ec68d6..abab47e7dc8 100644
--- a/lisp/repeat.el
+++ b/lisp/repeat.el
@@ -335,7 +335,7 @@ recently executed command not bound to an input event\"."
335 (setq real-last-command 'repeat) 335 (setq real-last-command 'repeat)
336 (setq repeat-undo-count 1) 336 (setq repeat-undo-count 1)
337 (unwind-protect 337 (unwind-protect
338 (while (let ((evt (read-event))) ;FIXME: read-key maybe? 338 (while (let ((evt (read-key)))
339 ;; For clicks, we need to strip the meta-data to 339 ;; For clicks, we need to strip the meta-data to
340 ;; check the underlying event name. 340 ;; check the underlying event name.
341 (eq (or (car-safe evt) evt) 341 (eq (or (car-safe evt) evt)
diff --git a/src/ChangeLog b/src/ChangeLog
index 7046d13262f..c9d0e80c12f 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,16 @@
12010-10-19 Ken Brown <kbrown@cornell.edu>
2
3 * s/cygwin.h (SIGNALS_VIA_CHARACTERS): New define (bug#7225).
4
52010-10-19 Kenichi Handa <handa@m17n.org>
6
7 Fix incorrect font metrics when the same font is opened with
8 different pixelsizes.
9
10 * xftfont.c: Include composite.h.
11 (xftfont_shape): New function.
12 (syms_of_xftfont): Set xftfont_driver.shape.
13
12010-10-18 Julien Danjou <julien@danjou.info> 142010-10-18 Julien Danjou <julien@danjou.info>
2 15
3 * frame.c (Fframe_pointer_visible_p): 16 * frame.c (Fframe_pointer_visible_p):
diff --git a/src/s/cygwin.h b/src/s/cygwin.h
index 4d58542e660..157ef72f550 100644
--- a/src/s/cygwin.h
+++ b/src/s/cygwin.h
@@ -101,5 +101,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
101 returns ENOSYS. A workaround is to set G_SLICE=always-malloc. */ 101 returns ENOSYS. A workaround is to set G_SLICE=always-malloc. */
102#define G_SLICE_ALWAYS_MALLOC 102#define G_SLICE_ALWAYS_MALLOC
103 103
104/* Send signals to subprocesses by "typing" special chars at them. */
105#define SIGNALS_VIA_CHARACTERS
106
104/* arch-tag: 5ae7ba00-83b0-4ab3-806a-3e845779191b 107/* arch-tag: 5ae7ba00-83b0-4ab3-806a-3e845779191b
105 (do not change this comment) */ 108 (do not change this comment) */
diff --git a/src/xftfont.c b/src/xftfont.c
index dc82c28b215..a44921a11df 100644
--- a/src/xftfont.c
+++ b/src/xftfont.c
@@ -32,6 +32,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
32#include "blockinput.h" 32#include "blockinput.h"
33#include "character.h" 33#include "character.h"
34#include "charset.h" 34#include "charset.h"
35#include "composite.h"
35#include "fontset.h" 36#include "fontset.h"
36#include "font.h" 37#include "font.h"
37#include "ftfont.h" 38#include "ftfont.h"
@@ -664,6 +665,23 @@ xftfont_draw (struct glyph_string *s, int from, int to, int x, int y, int with_b
664 return len; 665 return len;
665} 666}
666 667
668Lisp_Object
669xftfont_shape (Lisp_Object lgstring)
670{
671 struct font *font;
672 struct xftfont_info *xftfont_info;
673 FT_Face ft_face;
674 Lisp_Object val;
675
676 CHECK_FONT_GET_OBJECT (LGSTRING_FONT (lgstring), font);
677 xftfont_info = (struct xftfont_info *) font;
678 ft_face = XftLockFace (xftfont_info->xftfont);
679 xftfont_info->ft_size = ft_face->size;
680 val = ftfont_driver.shape (lgstring);
681 XftUnlockFace (xftfont_info->xftfont);
682 return val;
683}
684
667static int 685static int
668xftfont_end_for_frame (FRAME_PTR f) 686xftfont_end_for_frame (FRAME_PTR f)
669{ 687{
@@ -753,6 +771,9 @@ syms_of_xftfont (void)
753 xftfont_driver.draw = xftfont_draw; 771 xftfont_driver.draw = xftfont_draw;
754 xftfont_driver.end_for_frame = xftfont_end_for_frame; 772 xftfont_driver.end_for_frame = xftfont_end_for_frame;
755 xftfont_driver.cached_font_ok = xftfont_cached_font_ok; 773 xftfont_driver.cached_font_ok = xftfont_cached_font_ok;
774#if defined (HAVE_M17N_FLT) && defined (HAVE_LIBOTF)
775 xftfont_driver.shape = xftfont_shape;
776#endif
756 777
757 register_font_driver (&xftfont_driver, NULL); 778 register_font_driver (&xftfont_driver, NULL);
758} 779}