0

I am defining a new mode in emacs, but I want to have the same syntax highlighting as Org mode. How can I do this?

2
  • Do you want to define a new mode based on orgmode? In that case you can use (define-derived-mode my-new-mode org-mode "My New Mode" "Docstring" ...).
    – Tobias
    Commented Nov 20, 2018 at 18:00
  • If you only want to set font-lock-keywords you can use the function org-set-font-lock-defaults to set org-font-lock-keywords and font-lock-defaults buffer-locally.
    – Tobias
    Commented Nov 20, 2018 at 18:07

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.