Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > KOReader

Notices

Reply
 
Thread Tools Search this Thread
Old 10-01-2025, 11:48 PM   #1
purplethecat
Junior Member
purplethecat began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2025
Device: Boox Page
Line breaks won't show in tables

First photo is how it looks on KOReader (Turned on table borders on KOReader for clarity), second photo is how it looks on Calibre. (how it should look).

The second cell should have line breaks between the phrases, but they don't show up on KOReader.

I've tried changing the style tweaks for tables (including turning on "full-width tables", "ignore publisher table and cell widths") in the KOReader settings and nothing works. Even tried making the font size smaller but nothing.

The HTML on the ebook:
Code:
<table class="table"><tr><td class="tab1"><span class="smallcaps">TOPICS:</span> </td><td>A Proclamation<br>The Wisest of Lines<br>A Poem</td></tr></table>
And from the stylesheet:
Code:
.table {
  font-size: large;
  margin-top: 1em;
  margin-bottom: 2em;
  text-indent: 0em;
  text-align: justify;
  font-weight: bold;
}
.tab1 {
  font-size: small;
  margin-top: 0em;
  margin-bottom: 0em;
  text-indent: 0em;
  text-align: justify;
  padding-left: 0em;
  padding-right: 2em;
  vertical-align: top;
}
I've also tried changing text-align from `justify` to `right` but no fix.

Is this a KOReader issue? The tables are in the beginning of all 40 chapters and I would rather not have to edit the html for every single one, especially since I haven't finished reading the book.

KOReader:


Calibre (how it should look):
purplethecat is offline   Reply With Quote
Old 10-02-2025, 02:27 AM   #2
purplethecat
Junior Member
purplethecat began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2025
Device: Boox Page
Update: my conclusion so far is that KOReader just flattens <br> (changing the widths of the cells didn't work either so it wasn't a spacing issue) so I've just decided to change everything to <div>...
purplethecat is offline   Reply With Quote
Advert
Old 10-02-2025, 02:44 AM   #3
Karellen
Wizard
Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.
 
Karellen's Avatar
 
Posts: 1,652
Karma: 9500498
Join Date: Sep 2021
Location: Australia
Device: Kobo Libra 2
If you use <br/> instead, does that make a difference?

As for the cell width, use

PHP Code:
<tr>
  <
th style="width:20%;">TOPICS:</th>
  <
th style="width:50%;">A Proclamation<br/>The Wisest of Lines<br/>A Poem</th>
</
tr
Fiddle with the % value until you get the sizing right.
Karellen is offline   Reply With Quote
Old 10-02-2025, 02:50 AM   #4
purplethecat
Junior Member
purplethecat began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2025
Device: Boox Page
Quote:
Originally Posted by Karellen View Post
If you use <br/> instead, does that make a difference?

As for the cell width, use

PHP Code:
<tr>
  <
th style="width:20%;">TOPICS:</th>
  <
th style="width:50%;">A Proclamation<br/>The Wisest of Lines<br/>A Poem</th>
</
tr
Fiddle with the % value until you get the sizing right.
<br/> instead of <br> works! I don't know how I didn't think of that. Thank you, you saved me a lot of time lol. Changing the width didn't seem to be necessary.
purplethecat is offline   Reply With Quote
Old 10-02-2025, 02:55 AM   #5
Karellen
Wizard
Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.Karellen ought to be getting tired of karma fortunes by now.
 
Karellen's Avatar
 
Posts: 1,652
Karma: 9500498
Join Date: Sep 2021
Location: Australia
Device: Kobo Libra 2
Quote:
Originally Posted by purplethecat View Post
<br/> instead of <br> works! I don't know how I didn't think of that. Thank you, you saved me a lot of time lol. Changing the width didn't seem to be necessary.
Fantastic!!

As for the table columns, on rare occasions I have seen some weird formatting when the widths are not set and depending on the reader being used. Keep that in the back of your mind in case you find the tables start playing up.
Karellen is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Show tables in a reading device szalonyptak Sigil 11 09-09-2020 04:00 PM
Line breaks on Kindle, no line breaks on 4 PC Siavahda Kindle Formats 0 10-20-2012 05:50 AM
Odd line breaks in tables DTM ePub 9 08-05-2011 02:41 PM
iBooks: pictures do not show in tables georg3200 ePub 32 05-20-2011 03:05 AM
No line breaks ecpepper Amazon Kindle 3 08-09-2009 06:42 PM


All times are GMT -4. The time now is 12:08 PM.


MobileRead.com is a privately owned, operated and funded community.