emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Gnus; Restore multi encoding support for NNTP


From: LdBeth
Subject: Re: [PATCH] Gnus; Restore multi encoding support for NNTP
Date: Sat, 01 Jan 2022 10:11:12 +0800
User-agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (Gojō) APEL-LB/10.8 EasyPG/1.0.0 Emacs/27.2 (x86_64-apple-darwin18.7.0) MULE/6.0 (HANACHIRUSATO)

>>>>> In <874k6o7okc.fsf@gnus.org> 
>>>>>   Lars Ingebrigtsen <larsi@gnus.org> wrote:

Lars> Ah, right, I'd totally forgotten that bit.  I think it can be relied
Lars> upon.  And storing the info as a text property will probably work in
Lars> Gnus -- it'll save the data to .newsrc.eld, as you've found out -- but
Lars> it sounds pretty brittle to me.  That is, I wouldn't be surprised if the
Lars> text property goes missing at some point, because the code in Gnus isn't
Lars> written with text properties in mind.

I have now figured how to write text property into .newsrc.eld: Gnus
does extra UTF-8 encoding when save group names, since it is now
already using UTF-8 encoding internally, I think it would be safe to
just remove that.

ldb> Btw I figured it is not a good idea to do encoding in nntp.el because
ldb> the decoding was not done in nntp.el either.

Lars> Perhaps just having this in an alist in nntp.el somewhere would be the
Lars> most logical choice, even though it means that nntp.el peeks at Gnus
Lars> variables. 

I figured it is more diffcult to do percisely the encoding in nntp.el

Besides, I think it would be more ideal to let
`gnus-group-name-charset-group-alist' still to be generic on all
backends, which is the Emacs 26's old behavior.

Right now this patch has no problem accessing, subscribing servers
with GBK coding system and save the group names with their text
property (test agains the git master branch). The only one missing
puzzle is, the text property would be lost at some point after read in
the newsrc.eld file. I'll do a trace later to find out if this can be
worked out.

Attachment: gnus.patch
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]