Set default body background

  • Is there any way to set a default body background colour for pages without forcing the background to change if it is already set?

  • Stylish?

  • The generated stylesheet from a script that I have in Violentmonkey acts like an external stylesheet. Would not a stylesheet from Stylish also act like an external stylesheet?

  • When does your stylesheet load? I don't really know CSS, but I recall that Opera 12's userCSS required writing "!important" to override site styles as the stylesheet loaded last (the one from the website) normally takes precedence. If your stylesheet loads first but does not use "!important" then it functions like a default.

  • The problem is that the stylesheet generated by a script within Violentmonkey does not need "!important" to override, and external stylesheets that load along with web pages do not need that either. Content stylesheets work differently. To set a default with one of those, you omit "!important", whereas to override, you include it. Presto Opera did make provision for a content stylesheet, but WebKit Opera does not seem to have any provision at all for one.

    Would Stylish be any different?

  • Would Stylish be any different?

    Just test it.

    You can create another profile for testing purposes if you need.

  • I hardly think that installing another extension just to change one parameter is worthwhile. If the body background is set, a script I have in Violentmonkey will make it darker if it is light. If no background is set, that script does nothing. I have a bookmarklet that can change the body background. I guess I should just settle for that.

Log in to reply
 

Looks like your connection to Opera forums was lost, please wait while we try to reconnect.