Created attachment 8814239 [details] Sin título.png User Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0 Build ID: 20161104212021 Steps to reproduce: Nothing, clean installation. Actual results: Name for "Deleted" folder is displayed in English instead of Spanish language.
¡Está mal! ;-) Which version are you using?
Actually, we need the version and the exact localisation, Spanish from Spain or Argentina, Chile, Mexico. https://www.youtube.com/watch?v=eyGFz-zIjHE - ver a partir del minuto 2:12 ;-)
Yes, specify the regional variant, Thunderbird version and the exact steps you follow to reproduce the error. I've just used Transvision to look up the word and none of the four localizations seem to have that word untranslated. Also, please note that the en-US word for the folder where deleted items are placed is not named "Deleted", but "Trash". I actually think you're seeing the name of a folder already created in an IMAP account.
Sorry I didn't specified, the version is the last one, 45.5.0, and the localization es-ES.
Created attachment 8814481 [details] es-ES name for Trash folder in Local Folders and an IMAP (Gmail) account So, this is definitely due to your specific IMAP account. Both the local folders and a GMail account Trash folder are translated as "Papelera2.
Thanks for clarifying.
So I have to deal with it and leave it in English, OK.
Can't you rename the folder at IMAP level? Use the web interface of the provider to rename it? Or check the subscribe menu.
It's a software problem, the folder cannot be renamed in any way. If I use the browser to enter my mail account the name is displayed correctly in Spanish. All the folders are named automatically and correctly by Thunderbird except the Deleted folder. For example: Deleted | imap://*@imap-mail.outlook.com/Deleted | Deleted Inbox | imap://*@imap-mail.outlook.com/INBOX | Bandeja de entrada Junk | imap://*@imap-mail.outlook.com/Junk | Correo no deseado Etc. If the folders are named by Thunderbird is to be expected that all of them are, and not all except the Deleted one. I also tried to force rename using about:config, mail.server.server1.trash_folder_name, but it doesn't save my modifications, it keeps switching back to "Deleted" by itself.
OK, I configured a Hotmail/Outlook/Live account in a Spanish version of TB 45.x and the folder is called "Deleted". In an English version of TB, the folder is also called "Deleted" not "Trash". Let's look at it from the Thunderbird side again.
Kent, Magnus, how do the "special" folders get their names? Why would the Outlook/Trash folder be called "Deleted" in English and localised versions of TB? I did an experiment on Outlook. I created a folder "Deleted" and got told that this created a name conflict. So obviously the Outlook folder is called "Deleted" internally, but since TB recognises it as special folder, why doesn't it assign a special name?
It's a bit complex. RFC 6154 makes us set some flags. See nsMsgDBFolder::SetPrettyName and there around.
Created attachment 8814729 [details] [diff] [review] 1320191-deleted-folder.patch This works. With this patch, the folder is called "Trash" and would be localised properly.
Comment on attachment 8814729 [details] [diff] [review] 1320191-deleted-folder.patch Review of attachment 8814729 [details] [diff] [review]: ----------------------------------------------------------------- I don't think this is right. The "name" should get set correctly to internally "trash" from somewhere... I don't know the details but it's complicated. We map up "our" special names to what the server tells us, if it tells us. Then localize them if necessary.
Thank you for your attention guys!
This is indeed complicated. Following http://kb.mozillazine.org/IMAP_Trash_folder I deleted the preference mail.server.server#.trash_folder_name with the effect that I now have a Trash folder (which most likely TB will use for deleted items) and a Deleted folder (which most likely Hotmail will use). Most likely the Trash folder would be localised. Reporter, if you're interested, delete/reset the preference mail.server.server#.trash_folder_name (you need to replace # with the real number) and report back what happens. I still think there is a problem in reliably detecting the Hotmail Deleted folder. Maybe we need to tweak in nsImapIncomingServer::DiscoveryDone(). Well, on second thought, the folder *is* detected, but it's then not subject to localisation since it's only localised if it was originally called "Trash". Otherwise TB assumes that the name found is the name that the user wants to see.
Summarising: The problem seems to be that Micro$oft in their infinite wisdom don't use the standard trash name "Trash" (like all other IMAP services I know) but instead "Deleted". TB only localises if the folder is originally called "Trash" and hands all other names on to the user interface, most likely since it already assumes them to be localised. So I'd have to see where to tweak this since Magnus didn't like the hack I presented. Looks like we'll have to treat M$ servers differently, just like we treat Gmail differently.
Treating differently probably isn't the thing to do. I'm not sure we actually do that for Gmail folders either, IIRC we're using what server tells us to. As I recall, some things to be aware of - imap servers may tell you the special folders - we support imap servers having special folders localized server side (I don't recall what we display for those) - thunderbird will let you run localized thunderbird versions, but still with same folder names, so you can switch back and forth (for POP)
Gmail is treated differently: https://dxr.mozilla.org/comm-central/rev/4f8486123b817d6b18bf2684a0f7e5facf725ce6/mailnews/imap/src/nsImapIncomingServer.cpp#1547 > we support imap servers having special folders localized server side Yes. But you can't distinguish between a localisation on the server side and "Deleted". Both are not the standard name "Trash". > imap servers may tell you the special folders Yes: https://dxr.mozilla.org/comm-central/rev/4f8486123b817d6b18bf2684a0f7e5facf725ce6/mailnews/imap/src/nsImapIncomingServer.cpp#1582 The problem is that we only display the localised name if the original name was "Trash" which is not the case for M$. So in my patch I localise when "Trash" or "Deleted" is found. This is the only solution I can think of, unless we want to treat M$ differently. But I wouldn't know how. Gmail at least is recognisable by their extra bit: https://dxr.mozilla.org/comm-central/rev/4f8486123b817d6b18bf2684a0f7e5facf725ce6/mailnews/imap/src/nsImapCore.h#149 I didn't see anything like this of M$. So maybe you'd like to reconsider the r- here.
I've tried to rename or restore "trash_folder_name" before, it always reset back to "Deleted". I've also tried to delete it completely editing prefs.js and editing it and make the file read only, doesn't work, it sets back to "Deleted" all the time.
Comment on attachment 8814729 [details] [diff] [review] 1320191-deleted-folder.patch Review of attachment 8814729 [details] [diff] [review]: ----------------------------------------------------------------- > - else if (mFlags & nsMsgFolderFlags::Trash && name.LowerCaseEqualsLiteral("trash")) > + else if (mFlags & nsMsgFolderFlags::Trash && // Microsoft calls the folder "Deleted". > + (name.LowerCaseEqualsLiteral("trash") || name.LowerCaseEqualsLiteral("deleted"))) Oh, it's similar to filename =Unsent Messages, en-US folder name=Outbox, localized "Outbox" in each localized build. In this case, "folder name=Outbox" is wriiten in Unsent Messages.msf, and, IIRC, "localized Outbox of a localized build" was written in .msf file in special situation. I actually saw "related msgStore name=trash" in Trash.msf when "trash" was created by user, and I saw "localized Trash of a localized build" in Trash.msf. This was a cause of phenomenon of "Trash disappered, I can't delete mail!" which seems to still occur in some user's non-ordinal environment. If done on "Deleted", "Sent Items", "Sent Mail", "bin", "Draft"(Yahoo! IMAP) and so on, I belive localized name for them should be provided, instead of "faked localized name via. faked folder name".
I think we are better distinguish following: a) Use Deleted as special folder in Thunderbird automatically, as Trash is used as special folder in Thunderbird automatically. b) Show localized name for Deleted if Deleted is used as "Special Folder of Trash" via. Server Settings.
To Jorg K. I think method provided by your patch sample is partially correct for enhancement of b) in previous my comment. If folder has "Special Folder attribute of Trash" && if the folder's prettiestName.toLowerCase() is contained in table of TraseNameSet, true==TraseNameSet.has(prettiestName.toLowerCase() of the folder) where TraseNameSet=new Set(["trash","deleted","bin",...]) Use it as-is in en-US build and use localized name for it in localized build at Folder Pane/Folder Picker. After it, all is up to localizer of localized build on localized name of "Deleted", "bin" etc. Then, localizer can freely create localized name for "Deleted", "deleted", "DeLeTed", ... .
Magnus, putting NI for you to reconsider the patch or give some better instructions so we don't forget this.