
.
CSS to Color Background of Searched Words?
10 posts
• Page 1 of 1
Does this still work (I have not tested it):
https://www.reddit.com/r/firefox/comments/dv0jnc/how_can_i_change_my_find_highlight_ctrlf_color_is/ Changing those colors can be difficult because there is code present to ensure proper contrast (this can swap text and background color) and using a dark theme can make things more complicated (on a light background you can use almost all colors).
It is usually the background set via ui.textSelectBackgroundAttention https://searchfox.org/mozilla-release/s ... ndFeel.cpp Last edited by dickvl on October 11th, 2020, 2:42 pm, edited 1 time in total.
Hi jscher. Appreciate the input. Unfortunately the code from link you provided doesnt change the background color. Thanks for trying anyway.
Hi. Appreciate the link.. but the link is broken. I tried 'ui.textSelectBackgroundAttention' which does change the background color but does so randomly as its a shot in the dark trying to find the right hexadecimal color code with a dark background that appeals to me. Sadly I found an adequate color but it will work on sites with light backgrounds while the background color changes to white on sites with light background colors. It appears that the code adjusts to the website's background color. So basically I'm back to square 1. Wish there were a way to turn off this adjustment and just apply a static background color without it dynamically changing according to a site's background color. If thats possible let me know. Thanks. Sorry, I tried to convert a DXR link and went wrong.
https://searchfox.org/mozilla-release/s ... ndFeel.cpp
Wow.. theres hundreds of lines. Is it possible for you to point me to the right codes? Thanks. My point is to get a list of ui.text prefs that are used for various cases and search the source code to see what they are about.
https://searchfox.org/mozilla-release/s ... tion&path= https://searchfox.org/mozilla-release/s ... rFrame.cpp
I checked out the links. Maybe you can still help. The line that works for me is "ui.textSelectBackgroundAttention." But you can only apply a few color codes that are darkish but the grand majority of color codes will turn to white background. Do you know any color codes that are dark that actually work? This works well for me on various color themes:
ui.textHighlightBackground: blue ui.textHighlightForeground: white ui.textSelectBackgroundAttention: blue
10 posts
• Page 1 of 1
Who is onlineUsers browsing this forum: Google [Bot] and 4 guests |
![]() |