]> code.delx.au - gnu-emacs/blobdiff - lisp/ps-bdf.el
File regenerated.
[gnu-emacs] / lisp / ps-bdf.el
index 4e19eae6b9ee57967f4207966e00e2552856559e..3f98e527bd7f200b8a74a75d9304c825c15df2d2 100644 (file)
@@ -1,11 +1,11 @@
-;;; ps-bdf.el --- BDF font file handler for ps-print.
+;;; ps-bdf.el --- BDF font file handler for ps-print
 
 ;; Copyright (C) 1998,99,2001 Electrotechnical Laboratory, JAPAN.
 ;; Licensed to the Free Software Foundation.
 
 ;; Keywords: wp, BDF, font, PostScript
-;; Maintainer: Kenichi Handa <handa@etl.go.jp>
-;; Time-stamp: <2001/03/05 09:04:32 vinicius>
+;; Maintainer: Kenichi Handa <handa@etl.go.jp>
+;; Time-stamp: <2001-07-15 12:25:51 pavel>
 
 ;; This file is part of GNU Emacs.
 
@@ -104,7 +104,12 @@ If BDFNAME doesn't exist, return nil."
             (insert-file-contents file-name)
             buf)))))
 
-(defvar bdf-cache-file (convert-standard-filename "~/.bdfcache.el")
+(defvar bdf-cache-file (if (eq system-type 'ms-dos)
+                          ;; convert-standard-filename doesn't
+                          ;; guarantee that the .el extension will be
+                          ;; preserved.
+                          "~/_bdfcache.el"
+                        (convert-standard-filename "~/.bdfcache.el"))
   "Name of cache file which contains information of `BDF' font files.")
 
 (defvar bdf-cache nil
@@ -354,8 +359,11 @@ The value is a list of DWIDTH, BBX, and BITMAP-STRING.
 DWIDTH is a pixel width of a glyph.
 BBX is a bounding box of the glyph.
 BITMAP-STRING is a string representing bits by hexadecimal digits."
-  (let ((coding-system-for-read 'no-conversion)
-       dwidth bbx height yoff bitmap-string)
+  (let* ((coding-system-for-read 'no-conversion)
+        (bbx (elt (bdf-get-font-info bdfname) 4))
+        (dwidth (elt bbx 0))
+        (bitmap-string "")
+        height yoff)
     (condition-case nil
        (with-temp-buffer
          (insert-file-contents bdfname nil offset (+ offset maxlen))