11 December 2014

Google Play Books: About a Bug with SVG Vector Images [Solved]

Recently, I reported a bug regarding SVG vector images in Google Play Books. The bug has since been corrected by Google.

Google Books Partner support reference: 5-2966000005478.

When you upload an ePub file to the Google Books Partner Center, it takes some hours to be processed. The following steps have to be checked once all the treatment is finished:

GPB: Google Play Books (Google Play store)
GB: Google Books

1. GPB app reader (Android): is the eBook displayed fine?
2. GPB app reader (iOS): is the eBook displayed fine?
3. GPB web interface: is the downloaded ePub file displayed fine in an eBook reader? 
4. GPB web interface: is the downloaded PDF file displayed fine in an eBook reader?
5. GPB web interface (web reader): is the eBook displayed fine?
6. GB web interface (web reader): is the preview of the eBook displayed fine?

Vector images are composed of paths. A path can have a stroke and/or a fill. The bug I reported was concerning steps 4, 5, and 6, for ePub with SVG code (vector images) embedded in the XHTML code. The vector images were displayed fine in the Google Play Books app, but not in the PDF file and in the web reader: the stokes were not displayed! After Google solved the problem, the web reader is displaying the images correctly (but it looks like there are using the fallback from vector/svg to bitmap/png).
Left: the path with a blue stroke and a red fill.
Right: the path with the stroke not displayed.

I reported a similar problem with the open source software Scribus (desktop publishing):

The fill of a curve with only two nodes is not exported in the PDF (Solved in Scribus 1.5)