[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Org-mode Babel does not show syntax highlight when open with ano
From: |
Kyle Meyer |
Subject: |
Re: [O] Org-mode Babel does not show syntax highlight when open with another mode |
Date: |
Sat, 17 Oct 2015 03:30:42 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
stardiviner <address@hidden> writes:
> I try to configure Org-mode to open ruby source code block with
> `enh-ruby-mode`.
>
> configuration as following:
>
> #+BEGIN_SRC emacs-lisp
> (with-eval-after-load 'enh-ruby-mode
> (add-to-list 'org-src-lang-modes '("ruby" . enh-ruby)))
> #+END_SRC
>
> This will open code block in `enh-ruby-mode` when you edit with [C-c '].
>
> You can see the syntax highlighting failed result screenshot at here:
>
> http://emacs.stackexchange.com/questions/17042/org-mode-babel-failed-syntax-highlight-after-change-org-src-lang-modes
>
> I hope to keep the syntax highlight, (If can use enh-ruby-mode syntax
> highlight
> will be better).
Sorry for the delayed response. It seems the problem is that
enh-ruby-mode highlights its buffers in a way that doesn't respond to
font-lock-fontify-buffer, which org-src-font-lock-fontify-block calls in
the buffer " org-src-fontification:enh-ruby-mode" to get the faces.
--
Kyle