Hi,

At Mon, 7 Jan 2002 18:38:09 +0900,
Ville Mattila <mulperi / iki.fi> wrote:
> The 1.41 from CVS disables coloring. I'm using FSF emacs 21.1.1 for NT.
> I think that the problem is that fon-lock-defaults are nil in ruby-mode.

Sorry, I didn't check for FSF emacs.  Does it fix by this?
Although I'm not sure whether it has
font-lock-syntactic-keywords.


Index: ruby-mode.el =================================================================== RCS file: /cvs/ruby/src/ruby/misc/ruby-mode.el,v retrieving revision 1.41 diff -u -2 -p -r1.41 ruby-mode.el --- ruby-mode.el 2002/01/05 03:22:41 1.41 +++ ruby-mode.el 2002/01/07 10:48:00 @@ -721,10 +721,18 @@ An end of a defun is found by moving for ("^\\(=\\)end\\(\\s \\|$\\)" 1 (7 . nil)))) - (put 'ruby-mode 'font-lock-defaults - '((ruby-font-lock-keywords) - nil nil nil - beginning-of-line - (font-lock-syntactic-keywords - . ruby-font-lock-syntactic-keywords))) + (cond ((featurep 'xemacs) + (put 'ruby-mode 'font-lock-defaults + '((ruby-font-lock-keywords) + nil nil nil + beginning-of-line + (font-lock-syntactic-keywords + . ruby-font-lock-syntactic-keywords)))) + (t + (add-hook 'ruby-mode-hook + '(lambda () + (make-local-variable 'font-lock-defaults) + (setq font-lock-defaults '((ruby-font-lock-keywords) nil nil)) + (setq font-lock-keywords ruby-font-lock-keywords) + (setq font-lock-syntactic-keywords ruby-font-lock-syntactic-keywords))))) (defun ruby-font-lock-docs (limit)
-- Nobu Nakada