![]() |
#1 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,439
Karma: 4276871
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Calibre Reader Ignores Background Color?
I was testing some of my own code using CSS body { background-color: #66ff66; ...} which is an obvious bright green background.
But the Calibre book reader doesn't show me that green. I see it in the Calibre book Editor, and setting the cover from the epub also shows green--just not in the reader. If I go into the reader's Color preferences, I can change the background, but it appears to ignore the "Override all book colors: Never" setting. I'm seeing this on Win10 in Calibre v5.6 (portable) and v5.10.1 (64bit), with reader launched from Calibre GUI, from file extension association in the OS and from the Content Server. Calibre v2.85.1 (portable) did show the green. I did check for any existing threads or bug reports about this and didn't find any. Minimal example epub is attached. |
![]() |
![]() |
![]() |
#2 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,021
Karma: 62040591
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
In the example file, the green background also doesn't appear in the preview pane of 5.10.1's ebook-edit.exe, while it does in 3.48's.
(also, I laughed at the description on the title page) Last edited by ownedbycats; 01-24-2021 at 06:33 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 950
Karma: 1183425
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite
|
Tested here on 5.10.1 and 4.23 and it didn't work on any. Using !important makes it work, though.
|
![]() |
![]() |
![]() |
#4 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,439
Karma: 4276871
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
|
![]() |
![]() |
![]() |
#5 |
Custom User Title
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 9,021
Karma: 62040591
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
|
Side-by-side comparison on Windows 10 Home (19041).
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
null operator (he/him)
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 20,771
Karma: 27405072
Join Date: Mar 2012
Location: Sydney Australia
Device: none
|
The one of the left may be a Dark Matter effect
BR |
![]() |
![]() |
![]() |
#7 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 44,149
Karma: 22670164
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Yes, body background is under the control of the user, not the book creator. If you really want to override body background color, wrap the contents of body in a div with a background.
|
![]() |
![]() |
![]() |
#8 |
Plugin Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,439
Karma: 4276871
Join Date: Dec 2011
Location: Midwest USA
Device: Kindle Paperwhite(10th)
|
Interesting.
I know I tested using body {background-color: ...} in a lot of different readers several years ago and they must have mostly worked, otherwise I wouldn't have included that as the way to change background in FFF. Trying it now a few places, I see that color works in Calibre Edit book preview and Calibre's "Set the cover for the book from the selected format" (AKA from calibre.ebooks.metadata.meta.get_metadata()), plus partially in Apple iPad's Books app, but not any other apps or readers that I tried. Which I guess is a good thing to know. I'll have to take that make note of that in the default FFF CSS. |
![]() |
![]() |
![]() |
#9 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 75,093
Karma: 131686272
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Would it be possible to remove the user control, leave the background as white and allow background colors to wor without diving it?
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Background color in Calibre 4 viewer | jbacelar | Calibre | 10 | 10-07-2019 09:21 PM |
Calibre PDF Output: Adding Background Rgb colors customization options and Font Color | Lodan | 7 | 02-17-2019 09:09 AM | |
Css for Calibre viewer background-color | Cjammi | Calibre | 5 | 03-10-2017 12:09 PM |
Calibre's reader ignores pagebreaks? | Joseph Picard | Conversion | 3 | 06-01-2012 09:46 PM |
Any epub reader for PC allows me to change text and background color? | ttluisa | General Discussions | 5 | 05-11-2010 11:04 PM |