--===============1905736043== Content-Type: multipart/signed; protocol="application/pgp-signature"; micalg=pgp-sha1; boundary="Boundary-02=_YpkQANXh102B3Jb" Content-Transfer-Encoding: 7bit --Boundary-02=_YpkQANXh102B3Jb Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Saturday 28 February 2004 19:51, Toshitaka Fujioka wrote: > Hello, > > Current CVS HEAD's kmail can not use non latin1 folder name, > correctly. eg. dose not work file in to folder filter action > > The attached patch is fix this problem. > Please review. Thanks for the patch, but... > I'll commit this patch, if anyone has no objection. Objection. ;-) See below. > Index: folderstorage.cpp > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > RCS file: /home/kde/kdepim/kmail/folderstorage.cpp,v > retrieving revision 1.13 > diff -u -3 -d -p -r1.13 folderstorage.cpp > --- folderstorage.cpp=A0=A0=A026 Feb 2004 11:56:32 -0000=A0=A0=A0=A0=A0= =A01.13 > +++ folderstorage.cpp=A0=A0=A028 Feb 2004 18:31:32 -0000 > @@ -709,7 +709,7 @@ QString FolderStorage::label() const > =A0 =A0if ( folder() && folder()->isSystemFolder() && !mLabel.isEmpty() ) > =A0 =A0 =A0 return mLabel; > =A0 =A0if ( folder() && folder()->isSystemFolder() ) > - =A0 =A0 return i18n( folder()->name().latin1() ); > + =A0 =A0return folder()->name(); > =A0 =A0return mFolder->name(); > =A0} This is wrong. The API docu of KMFolder::label() says "Returns the label=20 of the folder for visualization.". And 'for visualization' means=20 translated. OTOH, I don't think FolderStorage::label() should even=20 exist. The label definitely belongs to the folder, but not to the=20 storage. If FolderStorage::label() is used somewhere although=20 =46olderStorage::name() should be used then those calls have to be fixed. Also I wonder what this part of the patch should fix. The filenames of=20 all system folders are in Latin 1 (actually they are even in ASCII). =3D=3D=3D=3D=3D > - QString escapedName =3D QString( name() ); > + QString escapedName =3D QString::fromLocal8Bit( name() ); I'm pretty sure that the correct fix is the following: > - QString escapedName =3D QString( name() ); > + QString escapedName =3D QString( folder()->name() ); This seems to be just another folderstorage regression. =3D=3D=3D=3D=3D > - mStorage =3D new KMFolderCachedImap( this, aFolderName.latin1() ); > + mStorage =3D new KMFolderCachedImap( this,=20 > aFolderName.local8Bit().data() );=20 This part of the patch and the other similar changes shouldn't hurt. But=20 it also shouldn't really change anything because aFolderName.latin1()=20 or aFolderName.local8Bit().data() is only used of name for the=20 =46olderStorage-QObject. But this name is pretty much irrelevant because=20 it shouldn't be used anywhere. =3D=3D=3D=3D=3D All in all I guess that my proposed patch > - QString escapedName =3D QString( name() ); > + QString escapedName =3D QString( folder()->name() ); in FolderStorage::idString() will fix the problem. Till agrees that=20 name() is wrong, so I'll commit this change. Please try if this fixes=20 your problems. Regards, Ingo --Boundary-02=_YpkQANXh102B3Jb Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQBAQkpYGnR+RTDgudgRAnibAJ93TYkA9tEb/5cOS6cLbx/sL1t1iACfd36w timk4WjaWj1yvolOIl3Bp/s= =vzj9 -----END PGP SIGNATURE----- --Boundary-02=_YpkQANXh102B3Jb-- --===============1905736043== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ KMail developers mailing list KMail-devel@kde.org https://mail.kde.org/mailman/listinfo/kmail-devel --===============1905736043==--