Vincent Foley wrote: > Hi guys, I'm trying to get ruby-mode and html-mode to work together > with mmm-mode in .rhtml files, and I have a problem: the Ruby code is > not colored (syntax highlight). Right now, I have this code in my > .emacs file for eruby: > > ;; eRuby > (require 'mmm-mode) > (setq mmm-global-mode 'maybe) > (setq mmm-submode-decoration-level 0) > (mmm-add-classes > '((eruby > :submode ruby-mode > :front "<%[=#]?" > :back "%>"))) > (add-to-list 'auto-mode-alist '("\\.rhtml$" . html-mode)) > (add-to-list 'mmm-mode-ext-classes-alist '(html-mode nil eruby)) > > Anything seems suspect to you? Got an idea? Oh, and if I set > mmm-submode-decoration-level to 1 or to 2, the Ruby code is > highlighted in a pale gray and I can't read anything anymore > > Thanks for the tips. > > Vincent Don't know if this is relavent, but it works for me. To get syntax highlighting, I had to make the following modification to the ruby-mode.el file: ---------------------------cut here---------------------------------- *** /home/asfand/src/packages/ruby/ruby-1.8.1/misc/ruby-mode.el Fri Dec 19 17:29:09 2003 --- .emacs-lisp/ruby-mode.el Sun Mar 14 07:36:51 2004 *************** *** 162,166 **** :options '(t nil space) :group 'ruby) ! (eval-when-compile (require 'cl)) (defun ruby-imenu-create-index-in-block (prefix beg end) (let ((index-alist '()) (case-fold-search nil) --- 162,169 ---- :options '(t nil space) :group 'ruby) ! (eval-when-compile ! (require 'cl) ! (require 'font-lock) ! ) (defun ruby-imenu-create-index-in-block (prefix beg end) (let ((index-alist '()) (case-fold-search nil) ---------------------------cut here---------------------------------- Well, it worked for me, thats all that matters :-)