* How to turn off auto-fill-mode from Topic Parameters?
@ 2023-06-10 12:12 Adam Sjøgren
2023-06-10 13:02 ` Adam Sjøgren
2023-06-10 21:51 ` yeti
0 siblings, 2 replies; 7+ messages in thread
From: Adam Sjøgren @ 2023-06-10 12:12 UTC (permalink / raw)
To: info-gnus-english
I would like to have auto-fill-mode turned off for all groups in a
specific topic in Gnus.
I tried adding this to my Topic Parameters:
(message-fill-column nil)
after reading the documentation:
,----[ C-h v message-fill-column RET ]
| message-fill-column is a variable defined in ‘message.el’.
|
| Its value is 72
|
| Column beyond which automatic line-wrapping should happen.
| Local value for message buffers. If non-nil, also turn on
| auto-fill in message buffers.
`----
I then read this in the (variable form) part of the manual on Group
Parameters:
,----[ https://www.gnus.org/manual/gnus_21.html ]
| But some variables are evaluated in the article buffer, or in the
| message buffer (of a reply or followup or otherwise newly created
| message). As a workaround, it might help to add the variable in
| question to gnus-newsgroup-variables.
`----
and added this to my .gnus:
(add-to-list 'gnus-newsgroup-variables 'message-fill-column)
However auto-fill-mode is still on when I compose a new article in a
group in the topic.
Is The Right Way™ to add a function to a hook instead?
I just really like configuring behavior using the Topic/Group
Parameters...
:-),
Adam
--
"LUFTVAFFEL!" Adam Sjøgren
asjo@koldfront.dk
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How to turn off auto-fill-mode from Topic Parameters?
2023-06-10 12:12 How to turn off auto-fill-mode from Topic Parameters? Adam Sjøgren
@ 2023-06-10 13:02 ` Adam Sjøgren
2023-06-10 21:51 ` yeti
1 sibling, 0 replies; 7+ messages in thread
From: Adam Sjøgren @ 2023-06-10 13:02 UTC (permalink / raw)
To: info-gnus-english
Adam writes:
> Is The Right Way™ to add a function to a hook instead?
>
> I just really like configuring behavior using the Topic/Group
> Parameters...
I have solved it like this now:
(add-hook 'message-mode-hook (lambda ()
(let ((group (or gnus-newsgroup-name "")))
(when (string-match-p "illuminant:fediverse" group)
(auto-fill-mode -1)))))
inspired by "3.7 Various Message Variables" in the manual,
https://www.gnu.org/software/emacs/manual/html_node/message/Various-Message-Variables.html
But I'd still prefer to use Topic Parameters.
Best regards,
Adam
--
"But I wake up quick Adam Sjøgren
And I wake up sick" asjo@koldfront.dk
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How to turn off auto-fill-mode from Topic Parameters?
2023-06-10 12:12 How to turn off auto-fill-mode from Topic Parameters? Adam Sjøgren
2023-06-10 13:02 ` Adam Sjøgren
@ 2023-06-10 21:51 ` yeti
2023-06-10 22:11 ` Adam Sjøgren
1 sibling, 1 reply; 7+ messages in thread
From: yeti @ 2023-06-10 21:51 UTC (permalink / raw)
To: info-gnus-english
Adam Sjøgren <asjo@koldfront.dk> writes:
> I would like to have auto-fill-mode turned off for all groups in a
> specific topic in Gnus.
Doesn't that sound like a job for gnus-posting-styles?
--
Take Back Control! -- Mesh The Planet!
Do you GNUS too? -- Stop worrying about spam and start to score.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How to turn off auto-fill-mode from Topic Parameters?
2023-06-10 21:51 ` yeti
@ 2023-06-10 22:11 ` Adam Sjøgren
2023-06-10 22:48 ` yeti
0 siblings, 1 reply; 7+ messages in thread
From: Adam Sjøgren @ 2023-06-10 22:11 UTC (permalink / raw)
To: info-gnus-english
yeti writes:
> Adam Sjøgren <asjo@koldfront.dk> writes:
>
>> I would like to have auto-fill-mode turned off for all groups in a
>> specific topic in Gnus.
>
> Doesn't that sound like a job for gnus-posting-styles?
Sounds intriguing - do you have an example of how?
Best regards,
Adam
--
"Our voodoo-dolls are full of hopes" Adam Sjøgren
asjo@koldfront.dk
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How to turn off auto-fill-mode from Topic Parameters?
2023-06-10 22:11 ` Adam Sjøgren
@ 2023-06-10 22:48 ` yeti
2023-06-10 23:01 ` Adam Sjøgren
0 siblings, 1 reply; 7+ messages in thread
From: yeti @ 2023-06-10 22:48 UTC (permalink / raw)
To: info-gnus-english
I don't use topics/groups but
https://gnus.org/manual/big-gnus.html#Group-Parameters
mentions that groups can have a posting-style parameter, so disabling
the fill mode maybe can done like
| (posting-style
| (eval ...change-the-fill-mode-here...
| )
| )
Shouldn't that apply to the whole group then?
--
Take Back Control! -- Mesh The Planet!
Do you GNUS too? -- Stop worrying about spam and start to score.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: How to turn off auto-fill-mode from Topic Parameters?
2023-06-10 22:48 ` yeti
@ 2023-06-10 23:01 ` Adam Sjøgren
2023-06-10 23:07 ` yeti
0 siblings, 1 reply; 7+ messages in thread
From: Adam Sjøgren @ 2023-06-10 23:01 UTC (permalink / raw)
To: info-gnus-english
yeti writes:
> disabling the fill mode maybe can done like
>
> | (posting-style
> | (eval ...change-the-fill-mode-here...
> | )
> | )
>
> Shouldn't that apply to the whole group then?
You're right, adding this to the Topic Parameters:
(posting-style
(eval
(auto-fill-mode -1)))
works.
Thanks for the tip!
Best regards,
Adam
--
"Mmm, what you say? Adam Sjøgren
Mm, that you only meant well? Well, of course you asjo@koldfront.dk
did."
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2023-06-10 23:07 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-10 12:12 How to turn off auto-fill-mode from Topic Parameters? Adam Sjøgren
2023-06-10 13:02 ` Adam Sjøgren
2023-06-10 21:51 ` yeti
2023-06-10 22:11 ` Adam Sjøgren
2023-06-10 22:48 ` yeti
2023-06-10 23:01 ` Adam Sjøgren
2023-06-10 23:07 ` yeti
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).