     map)
   "Keymap to navigate/set/enable rdebug breakpoints.")
 
+;; Here the "anchored match" method is used, see `font-lock-keywords'
+;; for details.
+(defvar rdebug-breakpoints-font-lock-keywords
+  '(("\\([0-9]+\\) +\\(\\(n\\)\\|\\(y\\)\\) +at "
+     (1 font-lock-constant-face)
+     (3 font-lock-type-face    nil t)   ; t = ok if not present
+     (4 font-lock-warning-face nil t)   ; ditto.
+     ;; File name and line
+     ("\\([a-zA-Z0-9/_:.]+\\):[0-9]+$"
+      nil                               ; Preform (not used)
+      nil                               ; Postfrom (not used)
+      (1 font-lock-warning-face))
+     ;; Class:function
+     ("\\([a-zA-Z0-9_]*\\):\\([a-zA-Z_][a-zA-Z0-9_]+\\)$"
+      nil                               ; Preform (not used)
+      nil                               ; Postfrom (not used)
+      (1 font-lock-type-face)
+      (2 font-lock-function-name-face))))
+  "Rules for coloring the rdebug breakpoints buffer.")
+
 (defun rdebug-breakpoints-mode ()
   "Major mode for displaying breakpoints in the `rdebug' Ruby debugger.
 

  (use-local-map rdebug-breakpoints-mode-map)
  (setq buffer-read-only t)
  (set (make-local-variable 'rdebug-secondary-buffer) t)
  (run-mode-hooks 'rdebug-breakpoints-mode-hook)
  ;;(if (eq (buffer-local-value 'gud-minor-mode gud-comint-buffer) 'gdba)
  ;;    'gdb-invalidate-breakpoints
  ;;  'gdbmi-invalidate-breakpoints)
  )

;; Work in progress...
(defvar rdebug-breakpoints-font-lock-keywords
  '(("\\([0-9]+\\) +[ny] +at +\\(\\(.*\\):\\([0-9]+\\)\\|\\(.*\\):\\([a-zA-Z_][a-zA-Z0-9_]\\)$")
    (1 font-lock-constant-face)
    (2 font-lock-warning-face)))

;;  '(("@[a-zA-Z0-9_]+" 0 font-lock-variable-name-face)
;;    ("\\<\\(nil\\|true\\|false\\)\\>" 0 font-lock-constant-face)
;;    ("#<\\([a-zA-Z0-9_]+\\):\\([0-9a-fx]*\\)"
;;     (1 font-lock-type-face)
;;     (2 font-lock-constant-face)))
;;  "Font-lock rules for the variables and watch windows in `rdebug'.")

(defun rdebug--setup-breakpoints-buffer (buf comint-buffer)
  "Detects breakpoint lines and sets up keymap and mouse navigation."
  (rdebug-debug-enter "rdebug--setup-breakpoints-buffer"
    (with-current-buffer buf
      (let ((inhibit-read-only t) 
	    (old-line-number (buffer-local-value 'rdebug-current-line-number 
						 buf))
	    (flag))
        (rdebug-breakpoints-mode)

                                (buffer-substring b e))
              (add-text-properties b e
                                   (list 'mouse-face 'highlight
                                         'keymap rdebug-breakpoints-mode-map)))
            (forward-line)))
	(goto-line old-line-number)))
    (rdebug-breakpoints-parse-and-update-cache)
    (rdebug-breakpoints-update-icons (rdebug-all-breakpoints))))
