Gnus development mailing list
 help / color / mirror / Atom feed
* paragraph separator in message mode
@ 2003-02-21 19:59 David S Goldberg
  2003-02-22 21:21 ` Kai Großjohann
  0 siblings, 1 reply; 5+ messages in thread
From: David S Goldberg @ 2003-02-21 19:59 UTC (permalink / raw)


I've had these lines in my message-mode-hook for some time now but
since I just noticed that I needed to make a fix to the regexp I
wonder if it shouldn't somehow be the default behavior for
message-mode.

(make-local-variable 'paragraph-separate)
(setq paragraph-separate
      (concat paragraph-separate
              "\\|<#!*/?\\(multipart\\|part\\|external\\|mml\\|secure\\)"))

This allows me to insert mml via the usual means and not have to worry
about a M-q moving the paragraph onto the same line as the mml tag is
on, which I found annoying.  I got that expression from
mml-quote-region, by the way, which is missing the secure tag.

Thanks,
-- 
Dave Goldberg
david.goldberg6@verizon.net





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

* Re: paragraph separator in message mode
  2003-02-21 19:59 paragraph separator in message mode David S Goldberg
@ 2003-02-22 21:21 ` Kai Großjohann
  2003-02-22 22:22   ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Kai Großjohann @ 2003-02-22 21:21 UTC (permalink / raw)


David S Goldberg <david.goldberg6@verizon.net> writes:

> I've had these lines in my message-mode-hook for some time now but
> since I just noticed that I needed to make a fix to the regexp I
> wonder if it shouldn't somehow be the default behavior for
> message-mode.
>
> (make-local-variable 'paragraph-separate)
> (setq paragraph-separate
>       (concat paragraph-separate
>               "\\|<#!*/?\\(multipart\\|part\\|external\\|mml\\|secure\\)"))

Good idea.  I've committed it.  I'm not sure if I did it right,
though.  Hm.  Semantically, it seems it should be in mml-mode?

And the concat thing is potentially dangerous.  Can it lead to a
non-working value?  Is there a regexp that will break if \\|foo is
appended to it?
-- 
A preposition is not a good thing to end a sentence with.



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

* Re: paragraph separator in message mode
  2003-02-22 21:21 ` Kai Großjohann
@ 2003-02-22 22:22   ` Lars Magne Ingebrigtsen
  2003-02-23 10:37     ` Kai Großjohann
  0 siblings, 1 reply; 5+ messages in thread
From: Lars Magne Ingebrigtsen @ 2003-02-22 22:22 UTC (permalink / raw)


kai.grossjohann@uni-duisburg.de (Kai Großjohann) writes:

> And the concat thing is potentially dangerous.  Can it lead to a
> non-working value?  Is there a regexp that will break if \\|foo is
> appended to it?

I think it would be safer if a "\\(" ... "\\)" pair were added around
each regexp that is concatenated.

-- 
(domestic pets only, the antidote for overdose, milk.)
   larsi@gnus.org * Lars Magne Ingebrigtsen



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

* Re: paragraph separator in message mode
  2003-02-22 22:22   ` Lars Magne Ingebrigtsen
@ 2003-02-23 10:37     ` Kai Großjohann
  2003-02-23 11:32       ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Kai Großjohann @ 2003-02-23 10:37 UTC (permalink / raw)


Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> kai.grossjohann@uni-duisburg.de (Kai Großjohann) writes:
>
>> And the concat thing is potentially dangerous.  Can it lead to a
>> non-working value?  Is there a regexp that will break if \\|foo is
>> appended to it?
>
> I think it would be safer if a "\\(" ... "\\)" pair were added around
> each regexp that is concatenated.

Hm.  Okay.  So do like (format "\\(%s\\)\\|\\(%s\\)" old-value new-value)?

Done.
-- 
A preposition is not a good thing to end a sentence with.



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

* Re: paragraph separator in message mode
  2003-02-23 10:37     ` Kai Großjohann
@ 2003-02-23 11:32       ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 5+ messages in thread
From: Lars Magne Ingebrigtsen @ 2003-02-23 11:32 UTC (permalink / raw)


kai.grossjohann@uni-duisburg.de (Kai Großjohann) writes:

> Hm.  Okay.  So do like (format "\\(%s\\)\\|\\(%s\\)" old-value new-value)?

Yup.

-- 
(domestic pets only, the antidote for overdose, milk.)
   larsi@gnus.org * Lars Magne Ingebrigtsen



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

end of thread, other threads:[~2003-02-23 11:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-02-21 19:59 paragraph separator in message mode David S Goldberg
2003-02-22 21:21 ` Kai Großjohann
2003-02-22 22:22   ` Lars Magne Ingebrigtsen
2003-02-23 10:37     ` Kai Großjohann
2003-02-23 11:32       ` Lars Magne Ingebrigtsen

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 NNTP newsgroup(s).