Thunderbird 146 does not respect Autoconfig override
I use this dark mode theme: Star Trek in Thunderbird but override Thunderbird so that Thunderbird is in light mode and the folder, message list and message panes have a white background with black text. The override uses the Autoconfig method (for Firefox but it was working also in Thunderbird Customize Firefox using AutoConfig . This is my thunderbird.cfg file in Thunderbird's install folder containing:
// IMPORTANT: Start your code on the 2nd line lockPref("browser.theme.content-theme", 2); lockPref("browser.theme.toolbar-theme", 2);
and my autoconfig.js file in Thunderbird's defaults/pref folder containing:
pref("general.config.filename", "thunderbird.cfg"); pref("general.config.obscure_value", 0);
In Thunderbird 145 this worked - all panes had a white background. However, when I updated to Thunderbird 146, the background in the folder, message list and message panes changed to grey with black or white text. With Thunderbird 146, both files are still present and the prefs in about:config are present with the 2 value. The Thunderbird 146 changelog mentions Visual and UX fixes and security fixes.
My Windows 10 colour settings are: default Windows mode = Dark default app mode = Light. These are my preferred settings.
I have changed temporarily to Thunderbird 140.6.0esr and got the white background re-enabled. How do I get the white background and black text back again in Thunderbird 146 please?
გადაწყვეტა შერჩეულია
Hi Rick. The CSS code from Googlethunderbird did change the three panes to a white background but all of the panes headers remained black.
I was able to solve this from a different angle. morat at mozillazine showed me how to hack the theme's manifest.json so that it would install in Thunderbird 146 and keep everything in light mode. All credit is due to him for his great advice.
This is the new manifest.json for my theme :
{
"applications": {
"gecko": {
"id": "{5d8a994f-2392-492b-9c72-75ddbfda4e60}",
"strict_min_version": "60.0"
}
},
"description": "Star Trek for TB146+",
"manifest_version": 2,
"name": "Star Trek",
"theme": {
"colors": {
"frame": "#ffffff",
"tab_background_text": "#000000"
},
"images": {
"theme_frame": "3.jpg"
}
},
"version": "1.0"
}
And because Thunderbird now considers this a light mode theme, I was able to delete thunderbird.cfg, autoconfig.js and reset browser.theme.content-theme and browser.theme.toolbar-theme to their default setting.
Thank you Googlethunderbird and Rick.
For anybody who wants to try this, amend for your theme as necessary. You need to change the ID using a GUID generator like www.uuidgenerator.net as the changes mean thunderbird will reject the original ID as being corrupted.
პასუხის ნახვა სრულად 👍 0ყველა პასუხი (15)
Hello there Peter cassidy.
You like to have Startrek? Did these colours , did they change with the use of the normal thunderbird css tools? It look s like recommended overhere ifvthey talk about startrek sometimes.
Do you have a rare add on of startrek?
In the past they were created by mozilla , now :
The most are home made and from thunderbird users /supporters /developers /and other humans.
I just might like to have one to.
ჩასწორების თარიღი:
Hi Peter,
That add-on has not been updated in seven years. It's possible that a change in 146 broke it. All I can say is that it is possible.
I do not know anything about autoconfig.js. I wonder if it might be easier or safer to control colors in css files. I too like a white background everywhere, so I put this in my userContent.css file:
body {background-color: white !important;}
And this in my userChrome.css file:
#MsgHeadersToolbar { height: min-content !important; margin-left: -65px !important; background-color: white !important; }
- folderPane {background-color: white !important;}
/* Keep Favorite Folders at the top of folders: */
- tabs-toolbar {background-color: white !important;}
position: sticky; top: 0; background-color: white; z-index: 1; }
- folderTree [data-mode="favorite"] {
Hello there peter cassidy.
Hello there , i did not write this article it s just a copy of text.
You might be interested in to read it?🎅
I hope that all that Startrek stuff is working as you should like to have it.
Solong spock.
Yes,Thunderbird 146 likely did had introduce theme handling , the visual and the ux fixes.
It s build for you guys to get involved with a more direct css approach to target specific elements.
Step 1 . Ensure User Customisations are Enabled Step 2. Create or Modify userChrome.css Step3. Force Colors in the Message Content Pane Step 4. Restart Thunderbird Software.
1. Ensure User Customisations are Enabled :
Go to the Thunderbird menu > Settings > General. Scroll to the very bottom and click the Config Editor button. Click Accept the Risk and Continue. Search for toolkit.legacyUserProfileCustomizations.stylesheets. Toggle the value to true by clicking the double-arrow icon. Close Thunderbird completely.
2. Create or Modify userChrome.css
Next, you need to add specific CSS rules to force the background colors you want.
Open your Thunderbird profile folder. You can find the location by going to the Thunderbird menu > Help > Troubleshooting Information > Open Folder (under "Application Basics"). Inside your profile folder, look for a folder named chrome. If it doesn't exist, create it (note the exact spelling, lowercase). Inside the chrome folder, create a new text file named userChrome.css (again, note the exact spelling and extension). Open userChrome.css with a text editor (like Notepad). Paste the following CSS code into the file to target the relevant panes:
css /* Force white background and black text in Folder Pane */
- folderPane, #folderTree {
background-color: #FFFFFF !important; color: #000000 !important;
}
/* Force white background and black text in Message List (Thread Pane) */
- threadTree, table[is="tree-view-table"] {
background-color: #FFFFFF !important; color: #000000 !important;
}
/* Force white background and black text in the Message Pane content area */ /* This requires using userContent.css (see Step 3) for the actual email b
3. Force Colors in the Message Content Pane
The message content pane (where you read emails) often requires userContent.css because it displays web content.
In the same chrome folder, create a new text file named userContent.css. Open userContent.css and add the following:
css /* Force white background and black text for email content */ @-moz-document url-prefix("about:blank"), url-prefix("chrome://messenger/content/messageWindow.xhtml"), url-prefix("chrome://messenger/content/messageBody.xhtml") {
body {
background-color: #FFFFFF !important;
color: #000000 !important;
}
}
4. Restart Thunderbird
After saving both userChrome.css and userContent.css, restart Thunderbird. The folder, message list, and message panes should now have a white background with black text, overriding your dark mode theme selection.
This method provides granular control over the UI colors, which is the most reliable way to achieve your desired look in newer Thunderbird versions.
Greetings goiglethunderbird.
ჩასწორების თარიღი:
Hi Rick,
Thanks for your help.
I added your code into userContent.css and userChrome.css. Unfortunately the background was still black. I have toolkit.legacyUserProfileCustomizations.stylesheets set as true.
I changed to Thunderbird's own dark theme, but still had a dark background. Does userContent.css and userChrome.css take priority over a dark mode theme? The system theme-auto, which follows the OS settings, gave me a light background.
In about>config I set layout.css.prefers-color-scheme.content-override to 1 which forces Firefox to use light mode when it uses a dark mode theme and the OS is set to light mode. Unfortunately, this doesn't seem to work in Thunderbird.
Sign, it seems with Thunderbird 146 the devs have coded it so that if you use a dark mode theme, that means dark mode. Period.
Hello there peter cassidy
The misding header text :
black text in the folder, message list, and message panes in Thunderbird 146 while using a dark overall theme, you will need to utilize userChrome.css for enhanced customisation, as the previous autoconfig method seems insufficient for overriding the new version's theme logic in all panes.
You might need this to.
Hello there
Yes , both of these functions do overwrite the theme and make changes to that ui interface use. Even the dark -theme to. In this case it stays white text ,strange? You do meant that you like to have other color patterns? Just use the advanced ccs language.
ჩასწორების თარიღი:
Hi Googlethunderbird, Using your userChrome.css and userContent.css, I got the folder pane changed to white. The email message list pane is white for the list of emails but the space below the last email is black when I would like it to be white. The email message pane is still black but there is a button that you can toggle to disable the dark message mode that changes it to white. The headers for all the panes are still black. Can you provide code that will change the space below the last email in the list from black to white? Can you provide code that will change the headers on the folder list, message list and message panes from black to white?
See picture of progress: Dark to white mode progress
Regards, Peter
Given above:
body {background-color: white !important;}
Hello there
Yes i can.
Hello there Peter Cassidy.
The wanted code for the interface. :
css
/* Change background of empty space below last email in the message list */
- threadTree treechildren {
background-color: #FFFFFF !important;
}
/* Change the headers on the folder list (folder pane header) */
- folderPaneHeader {
background-color: #FFFFFF !important; color: #000000 !important; /* Change text color to black for contrast if needed */
}
/* Change the header on the message list pane (the "Subject", "From", "Date" bar) */
- threadPaneHeader {
background-color: #FFFFFF !important; color: #000000 !important; /* Change text color to black for contrast if needed */
}
/* Change the header on the message pane (where the email content is displayed) */
- messagePaneHeader {
background-color: #FFFFFF !important; color: #000000 !important; /* Change text color to black for contrast if needed */
}
/* Ensure the main background of the message pane is also white */
- messagePane, .messageContent {
background-color: #FFFFFF !important;
}
Greetings Googlethunderbird
ჩასწორების თარიღი:
Peter, to be honest, I'm not trying to figure everything out because there seem to be too many interacting and moving parts for me. Config editor customizations, autoconfig, an add-on, a system-level dark mode that you seem to want to override at an app level. I do not use these things and I do not know how they all interact. I have also not updated to 146 yet.
I'm also a little confused, which is probably my fault because I'm not working hard to understand everything. You use a dark theme but want light colors? You ask for black headers against white backgrounds, but also want white headers? You are probably more consistent than that and I am just not trying hard enough to follow.
In any case, in your place, I would simplify. Re-set or remove autoconfig. If you want a mostly dark theme, use the dark theme included with Thunderbird. If you want a mostly light theme, use the light theme included with Thunderbird. If you are not happy with every color in your chosen theme, use only CSS to customize your colors.
By the way, the instances of "1" in our quoted CSS code above should be "#". The HTML interpreter is changing the #s.
I'm sorry that I cannot help more. Googlethunderbird has provided good information. If you have specific questions about CSS, other people on the forum can help answer them too.
შერჩეული გადაწყვეტა
Hi Rick. The CSS code from Googlethunderbird did change the three panes to a white background but all of the panes headers remained black.
I was able to solve this from a different angle. morat at mozillazine showed me how to hack the theme's manifest.json so that it would install in Thunderbird 146 and keep everything in light mode. All credit is due to him for his great advice.
This is the new manifest.json for my theme :
{
"applications": {
"gecko": {
"id": "{5d8a994f-2392-492b-9c72-75ddbfda4e60}",
"strict_min_version": "60.0"
}
},
"description": "Star Trek for TB146+",
"manifest_version": 2,
"name": "Star Trek",
"theme": {
"colors": {
"frame": "#ffffff",
"tab_background_text": "#000000"
},
"images": {
"theme_frame": "3.jpg"
}
},
"version": "1.0"
}
And because Thunderbird now considers this a light mode theme, I was able to delete thunderbird.cfg, autoconfig.js and reset browser.theme.content-theme and browser.theme.toolbar-theme to their default setting.
Thank you Googlethunderbird and Rick.
For anybody who wants to try this, amend for your theme as necessary. You need to change the ID using a GUID generator like www.uuidgenerator.net as the changes mean thunderbird will reject the original ID as being corrupted.
ჩასწორების თარიღი:
Wow. Well done.
Duplicate
ჩასწორების თარიღი:
Hello there peter Cassidy.
Merry Christmas.
ჩასწორების თარიღი: