From 4c15e0f715c0db74d6c2d6d37fc50781ad6fee9c Mon Sep 17 00:00:00 2001 From: morioka Date: Wed, 11 Mar 1998 12:09:43 +0000 Subject: [PATCH] tm 7.94. --- emu-e20.el | 9 ++++----- emu-xemacs.el | 35 +++++++++++++++++++++++++++++------ 2 files changed, 33 insertions(+), 11 deletions(-) diff --git a/emu-e20.el b/emu-e20.el index e2f377a..5f10996 100644 --- a/emu-e20.el +++ b/emu-e20.el @@ -3,7 +3,7 @@ ;; Copyright (C) 1996 Free Software Foundation, Inc. ;; Author: MORIOKA Tomohiko -;; Version: $Id: emu-e20.el,v 5.0 1996/10/23 06:37:13 morioka Exp $ +;; Version: $Id: emu-e20.el,v 6.0 1996/11/07 20:06:52 morioka Exp $ ;; Keywords: emulation, compatibility, Mule ;; This file is part of tl (Tiny Library). @@ -30,15 +30,14 @@ (require 'emu-19) -(defun fontset-height (fontset) +(defun fontset-pixel-height (fontset) + (require 'cl) (let* ((info (fontset-info fontset)) (height (aref info 1)) ) (if (> height 0) height - (let ((str - (car (aref (aref info 2) 0)) - )) + (let ((str (car (find-if (function identity) (aref info 2))))) (if (string-match "--\\([0-9]+\\)-\\*-\\*-\\*-\\*-\\*-ISO8859-1" str) (string-to-number (substring str (match-beginning 1)(match-end 1)) diff --git a/emu-xemacs.el b/emu-xemacs.el index 2b3c306..a1eb807 100644 --- a/emu-xemacs.el +++ b/emu-xemacs.el @@ -1,14 +1,14 @@ -;;; emu-xemacs.el --- Emacs 19 emulation module for XEmacs +;;; emu-xemacs.el --- emu API implementation for XEmacs ;; Copyright (C) 1995 Free Software Foundation, Inc. ;; Copyright (C) 1995,1996 MORIOKA Tomohiko ;; Author: MORIOKA Tomohiko ;; Version: -;; $Id: emu-xemacs.el,v 7.10 1996/08/30 15:14:30 morioka Exp $ +;; $Id: emu-xemacs.el,v 7.12 1996/11/15 14:02:56 morioka Exp $ ;; Keywords: emulation, compatibility, XEmacs -;; This file is part of tl (Tiny Library). +;; This file is part of emu. ;; This program is free software; you can redistribute it and/or ;; modify it under the terms of the GNU General Public License as @@ -21,9 +21,9 @@ ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, -;; Boston, MA 02111-1307, USA. +;; along with XEmacs; see the file COPYING. If not, write to the Free +;; Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA +;; 02111-1307, USA. ;;; Code: @@ -141,6 +141,29 @@ `(mapconcat #'char-to-string ,char-list "")) +;;; @@ to avoid bug of XEmacs 19.14 +;;; + +(or (string-match "^../" + (file-relative-name "/usr/local/share" "/usr/local/lib")) + ;; This function was imported from Emacs 19.33. + (defun file-relative-name (filename &optional directory) + "Convert FILENAME to be relative to DIRECTORY +(default: default-directory). [emu-xemacs.el]" + (setq filename (expand-file-name filename) + directory (file-name-as-directory + (expand-file-name + (or directory default-directory)))) + (let ((ancestor "")) + (while (not (string-match (concat "^" (regexp-quote directory)) + filename)) + (setq directory (file-name-directory (substring directory 0 -1)) + ancestor (concat "../" ancestor))) + (concat ancestor (substring filename (match-end 0))) + )) + ) + + ;;; @ end ;;; -- 1.7.10.4