Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 10-16-2024, 08:36 AM   #1
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,741
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Images and blank space

I know in ePub2 when you have some text on screen and then an image that doesn't fit in the remaining space, the image gets pushed to the next page and you end up with blank space.

In ePub3, is there a way to have the blank space filled with text when the image drops off to the next page?
JSWolf is online now   Reply With Quote
Old 10-16-2024, 08:52 AM   #2
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,347
Karma: 20171571
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
I'm not sure if there is a special ePub 3 function, or if you could get an effect like that with display:flex...but couldn't you get that with using float??

I haven't tested this...I'm taking a break at work ...but something like this might work:

Code:
div {float:left; width:100%; text-align:center; break-inside:avoid}

<div>
  <img alt="" src="test.jpg" />
  Caption text
</div>

<p>Other text.</p>
<p>Other text.</p>

Last edited by Turtle91; 10-16-2024 at 08:56 AM.
Turtle91 is offline   Reply With Quote
Advert
Old 10-16-2024, 09:57 AM   #3
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,741
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Turtle91 View Post
I'm not sure if there is a special ePub 3 function, or if you could get an effect like that with display:flex...but couldn't you get that with using float??

I haven't tested this...I'm taking a break at work ...but something like this might work:

Code:
div {float:left; width:100%; text-align:center; break-inside:avoid}

<div>
  <img alt="" src="test.jpg" />
  Caption text
</div>

<p>Other text.</p>
<p>Other text.</p>
But what about centered or full width images?
JSWolf is online now   Reply With Quote
Old 10-16-2024, 10:46 AM   #4
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,347
Karma: 20171571
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by JSWolf View Post
But what about centered or full width images?

Same thing - the div takes up the full width, but you just set the image width to whatever is desired inside the div:


Code:
div     {float:left; width:100%; text-align:center; break-inside:avoid}
div img {width:50%; margin:0 auto}


<div>
   <img alt="" src="test.jpg" />
   Caption text
 </div>
 
<p>Other text.</p>
<p>Other text.</p>
Turtle91 is offline   Reply With Quote
Old 10-16-2024, 12:17 PM   #5
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,762
Karma: 8700631
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by JSWolf View Post
In ePub3, is there a way to have the blank space filled with text when the image drops off to the next page?
YES MAN!! And that is one of the best advantage of epub3 over epub2. And now I realize that you never read what I posted

Some time ago I wrote a post with examples about what you can get with epub3; read the following posts:

https://www.mobileread.com/forums/sh...3&postcount=14

https://www.mobileread.com/forums/sh...33&postcount=7

After that, I posted the method to get that (in that case, was for a full page image but is easy to adapt the method for an image of any size). Read the following posts of mine:

https://www.mobileread.com/forums/sh...3&postcount=17

https://www.mobileread.com/forums/sh...4&postcount=29

For not full page images, is also possible to employ the <img> tag instead of a svg wrapper, something like what I wrote here:

https://www.mobileread.com/forums/sh...4&postcount=19

With epub3 YOU CAN AVOID FRAGMENTATION!!! That is, there is not any blank spaces generated by images or tables or text or whatever (unless, of course, you want those blank spaces are there).

Last edited by RbnJrg; 10-16-2024 at 12:47 PM.
RbnJrg is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting rid of the Bottom Margin's Blank Space denbertu KOReader 8 01-16-2020 10:58 AM
Eliminate first paragraph tab after blank space? nws ePub 8 04-10-2015 03:07 AM
Return of large blank footer space in 2.10.0 roycymru Kobo Reader 6 11-09-2013 01:50 PM
Problem with ePub - blank space around images SoonerJim Sigil 17 02-26-2011 01:40 PM
RTF Settings and blank space at the bottom of the page Greg G Sony Reader 2 10-10-2006 05:31 AM


All times are GMT -4. The time now is 01:56 PM.


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