                 caml-types-number-re " "
                 caml-types-number-re " "
                 caml-types-number-re)))
-  (setq caml-types-location-re 
-        (concat "^" caml-types-position-re " " caml-types-position-re)
-        ))
+  (setq caml-types-location-re
+        (concat "^" caml-types-position-re " " caml-types-position-re)))
+
 (defvar caml-types-expr-ovl (make-overlay 1 1))
-(overlay-put caml-types-expr-ovl 'face 'region)
-(defvar caml-types-type-ovl (make-overlay 1 1))
-(overlay-put caml-types-type-ovl 'face 'region)
+
+(make-face 'caml-types-face)
+(set-face-doc-string 'caml-types-face
+                     "face for hilighting expressions and types")
+(if (not (face-differs-from-default-p 'caml-types-face))
+    (set-face-background 'caml-types-face "#88FF44"))
+
+(overlay-put caml-types-expr-ovl 'face 'caml-types-face)
 
 (defun caml-types-show-type (arg)
   "Show the type of expression or pattern at point.

            ;; not strictly correct
            (re-search-forward
             "^type(\n  \\(\\([^\n)]\\|.)\\|\n[^)]\\)*\\)\n)")
             ;; (move-overlay caml-types-type-ovl
             ;; (match-beginning 1) (match-end 1)
             ;;   type-buf)
            (message (format "type: %s" (match-string 1)))
            (narrow-to-region (match-beginning 0) (match-end 0))
            ; (set-mark (match-beginning 1))
            )))
      (if (and (= arg 4)
               (not (window-live-p (get-buffer-window type-buf))))
          (display-buffer type-buf))
 ;       (let
 ;           ((window (get-buffer-window type-buf))
 ;            (this-window (selected-window)))
 ;         (if window
 ;             (progn
 ;               (select-window window)
 ;               (goto-char (mark))
 ;               (select-window this-window))))
      (unwind-protect
          (sit-for 60)
        (delete-overlay caml-types-expr-ovl)))))

          (if (null loc)
              (progn
                (delete-overlay caml-types-expr-ovl)
                (message
                 "Point is not within a typechecked expression or pattern.")
                (narrow-to-region 1 1))
            (let ((left (caml-types-get-pos target-buf (nth 0 loc) (nth 1 loc)))
                  (right (caml-types-get-pos target-buf
                                             (nth 2 loc) (nth 3 loc))))
