anchor.diff:  (defmethod clear ((area textarea) &key)
     "Clear the textarea by overwriting the underlying window with #\space.
   
  -If the underlying window has a background char, the background will
  -be used to clear the window."
  -  (with-accessors ((pos element-position) (width width) (height height) (win window)) area
  -    (setf (cursor-position win) pos)
  -    ;; return to the start of the area after the clearing
  -    (save-excursion win
  -      (loop for i from 0 to (1- height) do
  -        (loop for j from 0 to (1- width) do
  -          (goto win pos (list i j))
  -          ;; adding a simple space inherits the attributes and colors from the background char of the window.
  -          (add win #\space))))))
  +The char can be set by setting the :background and :selected-background style.
  +
  +If the underlying window has a background char, that will be used to
  +clear the window."
  +  (with-accessors ((pos element-position) (width width) (height height)
  +                   (win window) (selected selectedp) (style style)) area
  +    (let* ((bg-style (if selected (getf style :selected-background) (getf style :background)))
  +           (bg-char  (if (getf bg-style :simple-char) (getf bg-style :simple-char) #\space)))
  +      (setf (cursor-position win) pos)
  +      ;; return to the start of the area after the clearing
  +      (save-excursion win
  +        (loop for i from 0 to (1- height) do
  +          (loop for j from 0 to (1- width) do
  +            (goto win pos (list i j))
  +            ;; adding a simple space inherits the attributes and colors
  +            ;; from the background char of the window.
  +            (add win bg-char :style bg-style)))))))
   
   (defmethod update-cursor-position ((area textarea))
     (with-accessors ((pos element-position) (win window) (dptr display-pointer)
  
positive.code:     (refresh win)))
  
  (defmethod draw ((area textarea))
    (with-accessors ((pos element-position) (width width) (height height)
                     (inbuf buffer) (dptr display-pointer) (win window)) area
      (clear area)
      (let ((y 0)
            (x 0))
        ;; start at (0 0)
        (goto win pos (list y x))
  
negative.code:             (progn
                ;; all other (graphic) chars
                (when (>= y dptr)
                  (add-char win (nth i inbuf) :style fg-style))
                (if (= x (1- width))
                    ;; if we're at the last column, set the next x to 0 and move downward.
                    (setq y (1+ y) x 0)
  