Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 05-21-2017, 08:10 PM   #16
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,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by Cyberseeker View Post
I cannot attach an svg file, but can you duplicate a 900w x 1076h image in Sigil and make it stretch?
Yes, I do all the time. Most of the cover images I use are 1000ish wide x 1600 tall. They stretch, or condense, to the best fit for the display screen without losing the aspect ratio. If the image is very tall and maxes out the available screen height, then there will be extra space added to the sides so the images aspect ratio doesn't change.

That is probably why your shorter image makes it all the way across and the taller does not.

edit: if you do NOT want to maintain the aspect ratio then you can change the <svg> to:
preserveaspectratio="none"

Last edited by Turtle91; 05-21-2017 at 08:26 PM.
Turtle91 is offline   Reply With Quote
Old 06-06-2017, 01:42 AM   #17
Cyberseeker
Connoisseur
Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.
 
Posts: 60
Karma: 602194
Join Date: Apr 2017
Device: Ipad
Quote:
Originally Posted by Turtle91 View Post
Yes, I do all the time. Most of the cover images I use are 1000ish wide x 1600 tall. They stretch, or condense, to the best fit for the display screen without losing the aspect ratio. If the image is very tall and maxes out the available screen height, then there will be extra space added to the sides so the images aspect ratio doesn't change.

That is probably why your shorter image makes it all the way across and the taller does not.

edit: if you do NOT want to maintain the aspect ratio then you can change the <svg> to:
preserveaspectratio="none"
My images are 900px x 160 px and they stretch across the screen using the code you gave me.

Code:
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="100%" height="100%" preserveAspectRatio="xMidYMid meet" version="1.1" viewBox="0 0 900 160">
<image width="900" height="160" xlink:href="../Images/myimage.svg"/>
</svg>
However, there is a considerable gap above and below my image. Is there any way to minimize the unwanted white area?
Cyberseeker is offline   Reply With Quote
Old 06-06-2017, 02:31 AM   #18
fbrzvnrnd
Fanatic
fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.fbrzvnrnd ought to be getting tired of karma fortunes by now.
 
Posts: 554
Karma: 400004
Join Date: Feb 2009
Device: ONYX M96
Why you are embedding an SVG inside an SVG?
fbrzvnrnd is offline   Reply With Quote
Old 06-06-2017, 03:24 PM   #19
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,094
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Quote:
Originally Posted by Cyberseeker View Post
However, there is a considerable gap above and below my image. Is there any way to minimize the unwanted white area?
Again, referencing my earlier post:
Quote:
The preserveAspectRatio="xMidYMid meet" selection takes care of that. It centers the image using the options: xMidYMid meet.

Check here for a definition of all the SVG terms.
Clicking on the link will take you to the website which describes all the different aspects of the element: preserveAspectRatio

If you fiddle with the yMid, yMin, yMax options you may get something close to what you are looking for but as others have mentioned it's very difficult to do reliably across all devices/apps.
Turtle91 is offline   Reply With Quote
Old 06-07-2017, 02:53 PM   #20
Cyberseeker
Connoisseur
Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.Cyberseeker ought to be getting tired of karma fortunes by now.
 
Posts: 60
Karma: 602194
Join Date: Apr 2017
Device: Ipad
OK, I've changed yMid to yMin when the image is placed at the bottom, and that helps.

As an aside, is there a way of inserting a 'title' pop up? I tried inserting it between 'height' and 'xlink' but no luck.
Cyberseeker is offline   Reply With Quote
Reply

Tags
image, svg, width, zoom


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
fit a image to the width of screen leescott ePub 7 07-23-2015 10:39 AM
Maximize Image Francois Driesen Calibre 8 08-19-2014 02:58 PM
Changing image width in the economist goios Recipes 1 04-24-2014 01:29 PM
problem with floating image and relative width jobalcaen ePub 5 08-17-2013 07:53 AM
Setting Image width on news feed Wiggles Calibre 2 08-13-2010 02:10 AM


All times are GMT -4. The time now is 08:40 AM.


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