I'm putting together an ePub for use on a Kobo Libra 2 using Sigil, and I've been having issues with the Kobo not recognizing my css for centring a table on a page.
Initially, I was using
Code:
table.center {
margin-left:auto;
margin-right:auto;
}
To no avail. In Sigil's preview pane, it looks perfect. On the Kobo, the table itself looks fine, but is against the left side of the page. I tried putting the table inside a
Code:
<div style="width:100%;"></div>
but it didn't seem to help. I've resorted to using
Code:
table#table1 {
width:70%;
margin-left:15%;
margin-right:15%;
}
But it's not idea since it's fixing the width of the table, rather than wrapping it around the contents.
I'm not sure if this is limited to Kobo devices, or itf its a common thing among eReaders and eBook formatting, but is there an accepted standard way of centring a table on a page that works with Kobo?
(There were a lot of places I could have posted this - Sigil, Kobo, etc - but nothing seemed ideal for this type of question, so I put it here. I'm happy enough if mods move it to somewhere more appropriate.)