unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Howto turn on longlines-mode in .emacs?
@ 2009-05-08 13:16 nic.d.m.1
  2009-05-08 13:42 ` Anselm Helbig
  2009-05-09 11:18 ` Sean Sieger
  0 siblings, 2 replies; 8+ messages in thread
From: nic.d.m.1 @ 2009-05-08 13:16 UTC (permalink / raw)
  To: help-gnu-emacs

Hi!

I want to turn on longlines-mode by default, so I put the following in
my .emacs file:

(setq longlines-mode t)

But it doesn't work. Any hints?

If I then type: M-x longlines-mode emacs writes: "longlines-mode
disabled", if I type it again, it works...

thanks
nic


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-08 13:16 Howto turn on longlines-mode in .emacs? nic.d.m.1
@ 2009-05-08 13:42 ` Anselm Helbig
  2009-05-09 19:55   ` nic.d.m.1
  2009-05-09 11:18 ` Sean Sieger
  1 sibling, 1 reply; 8+ messages in thread
From: Anselm Helbig @ 2009-05-08 13:42 UTC (permalink / raw)
  To: help-gnu-emacs

Hi!

> I want to turn on longlines-mode by default, so I put the following in
> my .emacs file:
> 
> (setq longlines-mode t)
> 
> But it doesn't work. Any hints?

How about this one:

  (add-hook 'find-file-hook 'longlines-mode)

HTH, 

Anselm


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-08 13:16 Howto turn on longlines-mode in .emacs? nic.d.m.1
  2009-05-08 13:42 ` Anselm Helbig
@ 2009-05-09 11:18 ` Sean Sieger
  1 sibling, 0 replies; 8+ messages in thread
From: Sean Sieger @ 2009-05-09 11:18 UTC (permalink / raw)
  To: help-gnu-emacs

nic.d.m.1@googlemail.com writes:

    If I then type: M-x longlines-mode emacs writes: "longlines-mode
    disabled", if I type it again, it works...

It sounds like you're toggling longlines-mode off and on.

Do

C-h f longlines-mode





^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-08 13:42 ` Anselm Helbig
@ 2009-05-09 19:55   ` nic.d.m.1
  2009-05-09 22:33     ` Peter Dyballa
  2009-05-10  0:49     ` Anselm Helbig
  0 siblings, 2 replies; 8+ messages in thread
From: nic.d.m.1 @ 2009-05-09 19:55 UTC (permalink / raw)
  To: help-gnu-emacs

Hi!

Thanks for help. In the meantime I realized that longlines-mode has
some drawbacks for example it doesn't work correctly with comments in
latex.

Now I use

(add-hook 'LaTeX-mode-hook 'turn-on-auto-fill)

in my .emacs file

which seems to work together with comments in latex.

The con of this thing is, that I have to work with a fixed fill-column
value.

regards
nic


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-09 19:55   ` nic.d.m.1
@ 2009-05-09 22:33     ` Peter Dyballa
  2009-05-10  0:49     ` Anselm Helbig
  1 sibling, 0 replies; 8+ messages in thread
From: Peter Dyballa @ 2009-05-09 22:33 UTC (permalink / raw)
  To: nic.d.m.1; +Cc: emacs list


Am 09.05.2009 um 21:55 schrieb nic.d.m.1:

> The con of this thing is, that I have to work with a fixed fill-column
> value.


Have you thought of setting it to 9,999 or such? (A file or buffer  
can have local variables set.)

--
Greetings

   Pete

I love deadlines. I love the whooshing noise they make as they go by.
				– Douglas Adams







^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-09 19:55   ` nic.d.m.1
  2009-05-09 22:33     ` Peter Dyballa
@ 2009-05-10  0:49     ` Anselm Helbig
  2009-05-10  8:54       ` Harald Hanche-Olsen
  1 sibling, 1 reply; 8+ messages in thread
From: Anselm Helbig @ 2009-05-10  0:49 UTC (permalink / raw)
  To: help-gnu-emacs

Hi! 

> Thanks for help. In the meantime I realized that longlines-mode has
> some drawbacks for example it doesn't work correctly with comments in
> latex.

Yes, longlines-mode is great for some files but not so great for
others. You should turn it on for major modes where you need it
regularly by adding it to the major-mode's hook. For one-off cases
file variables come in handy. See (info "(emacs) File variables") if
you don't know about them yet. 

Regards,

Anselm


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-10  0:49     ` Anselm Helbig
@ 2009-05-10  8:54       ` Harald Hanche-Olsen
  2009-05-10  9:24         ` Teemu Likonen
  0 siblings, 1 reply; 8+ messages in thread
From: Harald Hanche-Olsen @ 2009-05-10  8:54 UTC (permalink / raw)
  To: help-gnu-emacs

+ Anselm Helbig <anselm.helbig+news2009@googlemail.com>:

> Yes, longlines-mode is great for some files

I would argue that with emacs 23 (and possibly earler), longlines-mode
is no longer great. Just turn off auto-fill-mode and (setq word-wrap t)
instead. This is much more robust, and doesn't interact badly with some
major modes the way longlines-mode does.

-- 
* Harald Hanche-Olsen     <URL:http://www.math.ntnu.no/~hanche/>
- It is undesirable to believe a proposition
  when there is no ground whatsoever for supposing it is true.
  -- Bertrand Russell


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Howto turn on longlines-mode in .emacs?
  2009-05-10  8:54       ` Harald Hanche-Olsen
@ 2009-05-10  9:24         ` Teemu Likonen
  0 siblings, 0 replies; 8+ messages in thread
From: Teemu Likonen @ 2009-05-10  9:24 UTC (permalink / raw)
  To: help-gnu-emacs

On 2009-05-10 10:54 (+0200), Harald Hanche-Olsen wrote:

> I would argue that with emacs 23 (and possibly earler), longlines-mode
> is no longer great. Just turn off auto-fill-mode and (setq word-wrap
> t) instead. This is much more robust, and doesn't interact badly with
> some major modes the way longlines-mode does.

Or perhaps use visual-line-mode which conveniently sets other related
variables too and redefines some movement keys to act on visual lines.


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2009-05-10  9:24 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-08 13:16 Howto turn on longlines-mode in .emacs? nic.d.m.1
2009-05-08 13:42 ` Anselm Helbig
2009-05-09 19:55   ` nic.d.m.1
2009-05-09 22:33     ` Peter Dyballa
2009-05-10  0:49     ` Anselm Helbig
2009-05-10  8:54       ` Harald Hanche-Olsen
2009-05-10  9:24         ` Teemu Likonen
2009-05-09 11:18 ` Sean Sieger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).