Closed Elzair closed 9 years ago
Thanks for the very detailed bug report. I'm sure I will be able to reproduce and get back to you with an answer, maybe a fix.
@Elzair, I've analysed this problem. First of all, rainbow-delimiters-mode
does work in lisp-mode
, that is, lisp files. Can you confirm this?
I have confirmed it does not work in sly-mrepl-mode
.
The reason for that is that sly-mrepl-mode
does not use font-lock-mode
, which rainbow-delimiters-mode
requires. This is technically a limitation in rainbows-delimiters
so I've removed the "bug" tag from this issue.
That said, there is a workaround. In the hook where you would normally turn on rainbow-delimiters-mode
, make sure font-lock-mode
is activated before.
(defun sly-mrepl-turn-on-rainbow-delimiters ()
(font-lock-mode 1)
(rainbow-delimiters-mode 1))
(add-hook 'sly-mrepl-mode-hook 'sly-mrepl-turn-on-rainbow-delimiters 'append)
rainbow-delimiters
will start working. Some faces will be changed, but I can minimize that with a future commit. In my tests in Emacs 24.4 everything works:
However in 24.3 you might run into problems. See issue #1.
Well, I added (font-lock-mode 1)
to my sly-mrepl-mode-hook
, and everything works fine in both lisp-mode
and sly-mrepl-mode
. Thank you!
I have attempted to use rainbow-delimiters in both
sly-mrepl-mode
and the minor-modesly-mode
, and it does not work in either.I then executed the following elisp code with M-:
I then started the sly-mrepl (with M-x sly) and attempted to turn on rainbow-delimiters (with M-:
(rainbow-delimiters-mode-turn-on)
), but nothing happened.