anchor.diff:                  :repeat :on)
                  pixmap)))))
   
  -(defmethod clim-clx::font-draw-glyphs ((font freetype-face) mirror gc x y string &key start end translate)
  -  (let ((display (xlib:drawable-display mirror)))
  -    (with-slots (font matrix) font
  +(let ((buffer (make-array 1024 :element-type '(unsigned-byte 32) ; TODO: thread safety
  +                               :adjustable nil :fill-pointer nil)))
  +  (defmethod clim-clx::font-draw-glyphs ((font freetype-face) mirror gc x y string &key start end translate)
  +    (declare (optimize (speed 3)))
  +    (when (< (length buffer) (- end start))
  +      (hef:debugf "fuck!")
  +      (setf buffer (make-array (* 256 (ceiling (- end start) 256))
  +                               :element-type '(unsigned-byte 32)
  +                               :adjustable nil :fill-pointer nil)))
  +    (let ((display (xlib:drawable-display mirror)))
         (destructuring-bind (source-picture source-pixmap) (gcontext-picture mirror gc)
  -        (let ((fg (xlib:gcontext-foreground gc)))
  +        (let* ((fg (xlib:gcontext-foreground gc))
  +               (cache (slot-value font 'glyph-id-cache))
  +               (glyph-ids buffer))
  +          (loop
  +             for i from start below end ; TODO: Read optimization notes. Fix. Repeat.
  +             for i* upfrom 0
  +             as char = (aref string i)
  +             as code = (char-code char)
  +             do (setf (aref buffer i*)
  +                      (or (gcache-get cache code)
  +                          (gcache-set cache code (font-glyph-id font char)))))
  +
             (xlib::render-fill-rectangle source-picture
                                          :src
                                          (list (ash (ldb (byte 8 16) fg) 8)
                                                (ash (ldb (byte 8 8) fg) 8)
                                                (ash (ldb (byte 8 0) fg) 8)
                                                #xFFFF)
  -                                       0 0 1 1))
  -        (setf (xlib::picture-clip-mask (drawable-picture mirror))
  -              (xlib::gcontext-clip-mask gc))
  -        (xlib::render-composite-glyphs
  -         (drawable-picture mirror)
  -         (display-the-glyph-set display)
  -         source-picture
  -         x y
  -         (map 'vector (lambda (x)
  -                        (first
  -                         (display-get-glyph display font matrix (char-code x))))
  -              (subseq string start end)))))))
  +                                       0 0 1 1)
  +          (setf (xlib::picture-clip-mask (drawable-picture mirror))
  +                (xlib::gcontext-clip-mask gc))
  +          (xlib::render-composite-glyphs
  +           (drawable-picture mirror)
  +           (display-the-glyph-set display)
  +           source-picture
  +           x y       
  +           glyph-ids
  +           :end (- end start)))))))
   
   (let ((cache (make-hash-table :test #'equal)))
     (defun make-free-type-face (display font size)
  
positive.code: (defparameter *dpi* 72)
  
  (defparameter *concrete-font-hash* (make-hash-table :test #'equal))
  
  (defun make-concrete-font (vague-font size &key (dpi *dpi*))
    (with-slots (lib filename) vague-font
  
negative.code:                                        (make-vague-font font))))
                       (f (make-concrete-font f.font size)))
                  (declare (type (alien freetype:face) f))
                  (set-concrete-font-size f size *dpi*)
                  (make-instance 'freetype-face
                                 :display display
                                 :font font
                                 :matrix size
                                 :concrete-font f
                                 :ascent  (/ (slot (slot (slot f 'freetype:size_s) 'freetype:metrics) 'freetype:ascender) 64)
                                 :descent (/ (slot (slot (slot f 'freetype:size_s) 'freetype:metrics) 'freetype:descender) -64)))))))
  
  