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?

  • 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 Nov 20 '18 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 Nov 20 '18 at 18:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.