I recently discovered longlines mode in Emacs (after having been a regular user for 5 yrs!). So I set in my .emacs file
(add-hook 'text-mode-hook 'turn-on-auto-fill)
(add-hook 'text-mode-hook 'longlines-mode)
(do I still need auto-fill? I can't tell...) which also sets org-mode to operate in longlines-mode as well. This seems to mess up the table construction functionality so I'd like to disable longlines mode for org-mode (which appears to incorporate text-mode-hooks) but keep it enabled for text (.txt) files.
I wonder if anyone has a solution to this? I am slowly picking up bits of Emacs Lisp but have not studied up on manipulating mode-hooks yet...
Thanks much! -Stephen
Try visual-line-mode
, which supplants longlines-mode
since Emacs-23.1.
You should be able to explicitly disable longlines-mode
in org-mode
by adding a hook to org-mode-hook
:
(add-hook 'org-mode-hook
'(lambda ()
(longlines-mode -1)))
Edit: Thanks to Török Gábor for pointing out my elisp fail :-)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With