Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > Workshop

Notices

Reply
 
Thread Tools Search this Thread
Old 08-18-2020, 09:21 AM   #1
angharad09
Enthusiast
angharad09 began at the beginning.
 
Posts: 30
Karma: 10
Join Date: Aug 2011
Device: none
some basic questions about width/height/size

If anyone can help out with one or more of the following questions, I'd be grateful. I've been trying to read up on them for a couple of days and am still not quite getting it.

(1a)
When width and height are given as %s, what are they a % of?
The viewing screen?
Some absolute value set higher up in the hierarchy?
The size of the image in pixels (if it's an image)?
Something else?
(1b)
Do % values affect images and text blocks the same way?

(2)
I know it's important to get image size right for quality+size reasons, but does image size also affect height/width %s in any way?

(3)
Are any of the answers different for epub vs azw3/mobi?

Many thanks.
angharad09 is offline   Reply With Quote
Old 08-18-2020, 10:39 AM   #2
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 36,982
Karma: 148318166
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by angharad09 View Post
If anyone can help out with one or more of the following questions, I'd be grateful. I've been trying to read up on them for a couple of days and am still not quite getting it.

(1a)
When width and height are given as %s, what are they a % of?
The viewing screen?
Some absolute value set higher up in the hierarchy?
The size of the image in pixels (if it's an image)?
Something else?
(1b)
Do % values affect images and text blocks the same way?
A % of the block the image is being displayed in. And yes.

Quote:
Originally Posted by angharad09 View Post
(2)
I know it's important to get image size right for quality+size reasons, but does image size also affect height/width %s in any way?
The image should be scaled to fit unless you have a ridiculously large image.

Quote:
Originally Posted by angharad09 View Post
(3)
Are any of the answers different for epub vs azw3/mobi?
Think of it as epub/azw3 vs. mobi. The image handling in mobi's is a PITA. Images are specified in pixels. Media queries become your best friend. You'll find quite a few books especially those generated with Vellum that have pairs of code for images for azw3/mobi to make life a bit easier.

Code:
<a class="link-contains-image" href="http://www.testrina.com"><img src="../Images/image00741.jpeg" alt="Testrina Publishing" class="title-page-publisher-logo-image high-res" data-AmznRemoved="mobi7"/>

<img alt="Testrina Publishing" class="title-page-publisher-logo-image low-res" src="../Images/image00162.jpeg" width="172" height="75" data-AmznRemoved-M8="true"/></a>
Code:
<div class="ornamental-break ornamental-break-as-image" data-AmznRemoved="mobi7"><img src="../Images/svgimg0091.svg" alt="" class="inline-ornamental-break"/></div>

<p class="ornamental-break ornamental-break-as-text" data-AmznRemoved-M8="true">* * *</p>
DNSB is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Image resizing issues while using max-height/max-width Detroa ePub 22 08-26-2020 06:17 PM
How to get book cover width and height in Calibre Python code? datcha Library Management 3 02-11-2016 09:55 AM
Resizing images, retaining width-height rato, and only if necessary. Vanguard3000 Sigil 7 07-31-2015 10:43 AM
Flightcrew : is px for the height/width forbidden ? NicolasR Sigil 2 02-11-2011 03:51 AM
WIDTH and HEIGHT in <img> tags Pablo Sigil 3 06-10-2010 05:37 PM


All times are GMT -4. The time now is 04:09 AM.


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