Mozilla Firefox 57+ : custom toolbar is still supported but how to manage it?
I have recently migrated all my Firefox profiles to version 58.0.2.
For some profiles, the custom toolbar that I used before FF57+ is now gone. I think this custom toolbar was brought by a legacy extension like Classic Theme Restorer. Since this extension is no more supported in FF57+, the toolbar is gone which is normal. But on some profiles, I saw that my custom toolbar was still here (see attached screenshots)
My custom toolbar is the one which contains the AdBlock Plus red icon (among others).
This gaves me some hope. This clearly indicates that custom toolbar is still implemented, although we can't create it directly from the GUI. I checked the browser.uiCustomization.state parameter in about:config. I saw that my "__customToolbar_Syl" custom toolbar was still referenced in the "placements" and "dirtyAreaCache" sections (which is not the case on the profiles without my custom toolbar).
The structure of browser.uiCustomization.state is the following: { "placements": { "widget-overflow-fixed-list":[] ,"__customToolbar_Syl":[...] => my custom toolbar ,"PersonalToolbar":[...] => bookmarks toolbar ,"nav-bar":[...] => toolbar containing the address bar ,"TabsToolbar":[...] => toolbar containing the tabs ,"toolbar-menubar":[...] => top toolbar containing the menus ,"addon-bar":[...] => this is my old toolbar at the bottom (which was used by Download Status Bar (legacy extension) ,"ctraddon_addon-bar":[...] => old toolbar of Classic Theme Restorer extension ,"ctraddon_extra-bar":[...] => old toolbar of Classic Theme Restorer extension ,"web-developer-toolbar":[...] => old toolbar of a dev extension } ,"seen":[...] ,"dirtyAreaCache":["addon-bar","PersonalToolbar","nav-bar","TabsToolbar","toolbar-menubar","PanelUI-contents","ctraddon_addon-bar","web-developer-toolbar","ctraddon_extra-bar","widget-overflow-fixed-list"] ,"currentVersion":13 ,"newElementCount":1424 }
I tried to insert my custom toolbar on another profile (in "placements" and "dirtyAreaCache"), but it never worked. Each time Firefox is restarted, the toolbar is removed from the browser.uiCustomization.state parameter. I don't understand why on some profiles my custom toolbar is never deleted, and why it is deleted on others. I hope Firefox will give the ability to create a custom toolbar in next releases. Otherwise, where will we put all the extension's buttons/icons and keep them all visible in the interface (without using the hidden extra list)? For the moment I put them in the menu toolbar, but this is not ideal (on the screenshot you see very few extension's icons as this is a test profile. On my production profiles I have more than 100 extensions...)
Mozilla gives absolutely no documentation about this parameter. For instance, I found by myself that I could insert custom separators in the different toolbars using the browser.uiCustomization.state parameter. And this works well.
การตอบกลับทั้งหมด (12)
That's very interesting. The about:config preference indicates what is on the bar, but that structural element obviously is not part of a standard installation, and needs to be injected into the code of the interface.
As far as I know, an extension cannot do that now, but there are some hacky ways sometimes referred to under the umbrella name "userChrome.js". See: https://www.userchrome.org/what-is-userchrome-js.html
Do you recall ever installing any files into the chrome folder of your profile, or into Firefox's program folders, that could be injecting the "__customToolbar_Syl" bar?
There is no "chrome" folder in my Firefox's program folders. In my profile, there is a unique "chrome" folder inside \storage\permanent\ containing some sqlite files. I don't know what they are used for. I have never performed manual actions in this folder. I have never used the legacy extension userChromeJS. I don't have any userChrome.js file in my profile or in Firefox's program folder. But I used many extensions in the past that may had injected some toolbar: - Classic Theme Restorer - Download Status Bar - Organize Status Bar (Revived) - Tab Mix Plus
fyi : USSER CHROME URL'S
- https://www.howtogeek.com/334716/how-to-customize-firefoxs-user-interface-with-userchrome.css/
- http://techdows.com/2017/09/classic-theme-restorer-userchrome-css-modify-firefox-57-photon-ui.html
- https://github.com/Aris-t2/CustomCSSforFx/issues/1
- https://www.accessfirefox.org/Theme-Font-Size-Changer.php
- https://www.userchrome.org/
- https://www.accessfirefox.org/Firefox_Accessibility_Themes.php
- https://www.userchrome.org/what-is-userchrome-css.html
- http://kb.mozillazine.org/UserChrome.css
- https://github.com/axydavid/FirefoxUI/blob/master/README.md
- https://github.com/wilfredwee/photon-australis
- https://www.reddit.com/r/FirefoxCSS/
Note not all code in one place.
Hi syldub, I may have been too hasty in my earlier message. Let me spell that out in more detail:
The chrome folder -- if one has been created -- would be in your profile folder. When you're looking at the folder in alphabetical order, it would be after bookmarkbackups and browser-extension-data, and before crashes.
If you have a chrome folder in the profile where you DO have an extra toolbar, what's in there?
The Autoconfig file -- if one has been created -- would be Firefox's program folder. To look for that, there are two possible locations (varies for 32-bit / 64-bit):
- C:\Program Files\Mozilla Firefox\defaults\pref
- C:\Program Files (x86)\Mozilla Firefox\defaults\pref
Caution: Do not double-click script files! The default action for a script file it to execute as a Windows system script. (Typically this would just show an error, but why risk it.)
I suggest making sure Windows is showing hidden files: https://support.microsoft.com/en-us/help/14201/windows-show-hidden-files
A file named channel-prefs.js is normal. Any other file in this folder could be an Autoconfig file that runs legacy code to modify Firefox, or points to another file that contains the code. See anything unexpected here?
Hi, Thanks for you clear explanations. I don't have a chrome folder in the profile where I have an extra toolbar, I use a 64-bit Firefox. I don't have any autoconfig file. The only file in folder C:\Program Files\Mozilla Firefox\defaults\pref\ is the channel-prefs.js file. My Windows File Explorer is configured to show the hidden files.
Can you post the content of userChrome.css ?
Are there any other (.xml) files in the chrome folder apart from userChrome.css and userContent.css?
I just upgraded from Firefox version 58.0.2 to 59.0.1, the custom toolbar disappeared... gone
Before upgrading: I don't have any userChrome.css, neither in the Firefox's program folder nor in any of my profiles folders. Like I just said before, I don't have any chrome folder in the Firefox's program folder.
This is not about the Firefox program folder, but about the Firefox profile folder that is in a different location in "AppData\Roaming".
You can use the button on the "Help -> Troubleshooting Information" (about:support) page to go to the current Firefox profile folder or use the about:profiles page.
- Help -> Troubleshooting Information -> Profile Directory:
Windows: Show Folder; Linux: Open Directory; Mac: Show in Finder - http://kb.mozillazine.org/Profile_folder_-_Firefox
This is not about the Firefox program folder, but about the Firefox profile folder that is in a different location in "AppData\Roaming". => Yes, I made a mistake when answering this: Like I just said before, I don't have any chrome folder in the Firefox's program folder.
As I said before : I don't have a chrome folder in the profile where I have an extra toolbar
You wrote above:
Like I just said before, I don't have any chrome folder in the Firefox's program folder.
I assume this was a typo?
Firefox 56 and older still had builtin support for the Addon toolbar (present in the DOM), but didn't support it in the user interface (customization).
Absent a special file of some kind, I think we are left without any explanation for how the extra bar in the screenshot was possible:
Simply adding items to xulstore.json and prefs.js does not seem to be enough to cause Firefox to display a bar. ???
@cor-el : Yes this was a typo.