This simple script adds a “Toggle BG Color” button above all images which allows you to quickly toggle between the light theme and dark theme color for the background of the image. Handy as transparent animated gifs that use aliasing can look bad against the dark theme, and of course some images look better with a dark background. This lets you swap just the image background color itself with the push of a button.
By default the button will always appear in the uploader bar, but you can edit the script and change the value of “AlwaysLink” in the script to set it to only appear on images tagged transparent background or derpibooru theme illusion.
It In Action:
I’ve since given this script a complete rewrite and added a slider bar feature as well. You can use these sliders to tweak the RGB values of the image’s background color and set it to anything you want. Click the down arrow beside the button and go nuts. Again, this feature can be turned off by editing he script and changing the value of “UseSliders”:
I mostly added the sliders thing out of boredom / curiosity , but let me know if you find a use for it beyond brief novelty. From what I’ve been told the sliders are only supported by Chrome, Opera, and the newest versions of Firefox, so if they cause your browser problems they can be toggled off (as stated above) or fixed by updating / changing browsers.
V1.0 – 2016/03/30 – Initial release
V2.0 - 2017/07/23 - Script rewrite. Now works consistently on all images tagged “transparent”, “transparent background”, and “derpibooru theme illusion”
V2.1 - 2017/07/23 - Added feature to toggle the script and changed the default setting.
V3.0 - 2017/08/01 - Script rewrite. Added slider function.
Download (Old 2.1 version) (Kept available because why not?)
Disclaimer and Such
Use at your own risk. This script does not store or access any user data. This script has been tested but may not be entirely bug free.
Derpibooru costs over $25 a day to operate - help support us financially!