View Single Post
Old 01-29-2019, 07:52 AM   #17
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,827
Karma: 8700631
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by momoha View Post
I’m sorry my replies are getting a bit rude...
Don't worry

Quote:
...I am reaching such a state of frustration with this
I can understand that.

Quote:
I spent the whole day on this again, and I found two codes that really aren’t that great but eases the work a little bit, and they seem to be working fine (tested with ePub3).

Link to SVG image with "calc" to ease the process:
Code:
<p class="texte"><img style="width: height: 1em; calc(1em*width/height);" alt="Logo Canada" src="../Images/canada.svg"/></p>
SVG code embedded, can be processed with regex so useful for books with lots of SVG. But properties="svg" has to be added in the content.opf. So SVG markup is pasted in the ePub, and this is added in the <svg>:
Code:
preserveAspectRatio="xMidYMin slice" style="width: 1em; padding-bottom: calc(1em*height/width); height: 1px; overflow: visible"
Ok. But now we have another issue; if you want only one epub, the property "calc" under epub2 is not well supported You need to work only with css2 so ereaders based on epub2/epub3 will be able to open the epub without problems.
RbnJrg is online now   Reply With Quote