# HG changeset patch # User Gerd Moellmann # Date 998038924 0 # Node ID db13126288331ae55edb0871da9ef88cb8b45469 # Parent 3e55b265569ae1b3fc595581289040b27b455400 (find-composition): Check if (char-after POS) returns a valid character. diff -r 3e55b265569a -r db1312628833 lisp/ps-mule.el --- a/lisp/ps-mule.el Thu Aug 16 19:48:00 2001 +0000 +++ b/lisp/ps-mule.el Fri Aug 17 09:02:04 2001 +0000 @@ -7,7 +7,7 @@ ;; Maintainer: Kenichi Handa (multi-byte characters) ;; Vinicius Jose Latorre ;; Keywords: wp, print, PostScript, multibyte, mule -;; Time-stamp: <2001/08/07 13:50:53 vinicius> +;; Time-stamp: <2001/08/15 15:34:11 vinicius> ;; This file is part of GNU Emacs. @@ -242,11 +242,11 @@ (+ (* (car rule) 12) (cdr rule))) (defun find-composition (pos &rest ignore) (let ((ch (char-after pos))) - (if (eq (char-charset ch) 'composition) - (let ((components (decompose-composite-char ch 'vector t))) - (list pos (ps-mule-next-point pos) components - (integerp (aref components 1)) nil - (char-width ch))))))) + (and ch (eq (char-charset ch) 'composition) + (let ((components (decompose-composite-char ch 'vector t))) + (list pos (ps-mule-next-point pos) components + (integerp (aref components 1)) nil + (char-width ch))))))) ;; mule package isn't loaded (or (fboundp 'encode-composition-rule) (defun encode-composition-rule (rule) @@ -1130,10 +1130,10 @@ } ifelse } ifelse } ifelse } forall ] /components exch def grestore - + %% Reflect special effects. SpecialEffect - + %% Draw components while ignoring effects other than shadow and outline. components ShowComponents