diff options
author | hrs <hrs@FreeBSD.org> | 2006-02-21 06:13:54 +0800 |
---|---|---|
committer | hrs <hrs@FreeBSD.org> | 2006-02-21 06:13:54 +0800 |
commit | 02332f529183ed529363c01efc8567401057eccb (patch) | |
tree | f7c1275441ebafe9489e71401d866cb663d88843 /editors/psgml | |
parent | 622e2e6dfd85478173a99426c141269e21cc65a9 (diff) | |
download | freebsd-ports-graphics-02332f529183ed529363c01efc8567401057eccb.tar.gz freebsd-ports-graphics-02332f529183ed529363c01efc8567401057eccb.tar.zst freebsd-ports-graphics-02332f529183ed529363c01efc8567401057eccb.zip |
Fix (sgml-make-character-reference) to use (ucs-to-char) and
(char-to-ucs). Bump PORTREVISION.
Spotted by: kuriyama
Diffstat (limited to 'editors/psgml')
-rw-r--r-- | editors/psgml/Makefile | 2 | ||||
-rw-r--r-- | editors/psgml/files/patch-psgml-edit.el | 31 |
2 files changed, 32 insertions, 1 deletions
diff --git a/editors/psgml/Makefile b/editors/psgml/Makefile index a592b067052..6fabf72d343 100644 --- a/editors/psgml/Makefile +++ b/editors/psgml/Makefile @@ -7,7 +7,7 @@ PORTNAME= psgml PORTVERSION= 1.3.2 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= editors elisp MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= psgml diff --git a/editors/psgml/files/patch-psgml-edit.el b/editors/psgml/files/patch-psgml-edit.el new file mode 100644 index 00000000000..e21da19c692 --- /dev/null +++ b/editors/psgml/files/patch-psgml-edit.el @@ -0,0 +1,31 @@ +--- psgml-edit.el.orig2 Tue Feb 21 07:02:29 2006 ++++ psgml-edit.el Tue Feb 21 07:08:59 2006 +@@ -1876,18 +1876,22 @@ + (match-end 0)) + (if (fboundp 'decode-char) ; Emacs 21, Mule-UCS + (setq c (decode-char 'ucs c)) ++ (if (fboundp 'ucs-to-char) ++ (setq c (ucs-to-char c)) + ;; Else have to assume 8-bit character. +- (if (fboundp 'unibyte-char-to-multibyte) ; Emacs 20 +- (setq c (unibyte-char-to-multibyte c)))) ++ (if (fboundp 'unibyte-char-to-multibyte) ; Emacs 20 ++ (setq c (unibyte-char-to-multibyte c))))) + (insert c))) + ;; Convert character to &#nn; + (t + (let ((c (following-char))) + (delete-char 1) +- (if (fboundp 'encode-char) +- (setq c (encode-char c 'ucs)) +- (if (fboundp 'multibyte-char-to-unibyte) +- (setq c (multibyte-char-to-unibyte c)))) ++ (if (fboundp 'char-to-ucs) ++ (setq c (char-to-ucs c)) ++ (if (fboundp 'encode-char) ++ (setq c (encode-char c 'ucs)) ++ (if (fboundp 'multibyte-char-to-unibyte) ++ (setq c (multibyte-char-to-unibyte c))))) + (insert (format "&#%d;" c)))))) + + (defun sgml-expand-entity-reference () |