Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Conversion

Notices

Reply
 
Thread Tools Search this Thread
Old 04-16-2020, 08:25 AM   #1
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
No resizing with SVG

I'm using a Kobo device and kepub files. I have a new problem with the SVG configuration or else. This following code was working fine until few weeks and I don't understand why it stop operating. Now I don't get the option in the Kobo to resize the SVG image. (I'm using the Tablet output option: no resizing of the original image).

<?xml version='1.0' encoding='utf-8'?>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
...
<style type="text/css">
@page {
margin-bottom: 5pt;
margin-top: 5pt;
}
body {
text-align: center;
padding: 0;
margin: 0;
}
div {
padding: 0;
margin: 0;
}
</style>
</head>

<body>

<div>

<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="100%" height="100%" viewBox="0 0 864 1228" preserveAspectRatio="XmidYmid">
<image width="864" height="1228" xlink:href="Map.jpg"/>
</svg>

</div>

...
jiembe is offline   Reply With Quote
Old 04-16-2020, 09:00 AM   #2
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
That code is basically the same as what I use. Checking one of my books with the Kobo firmware 4.20.x, the image can be zoomed. The most likely reason is that something has happened that the book was not sent to the device as a kepub. Are you using the KoboTouchExtended driver to send the books as a kepub? If so, check that it is still installed and active. There are occasional problems were it needs to be reinstalled.
davidfor is offline   Reply With Quote
Advert
Old 04-16-2020, 09:49 AM   #3
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
I wasn't using the KoboTouchExtended driver. I install it and disable the Kobo Reader device. But I get the same result.
jiembe is offline   Reply With Quote
Old 04-16-2020, 10:00 AM   #4
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by jiembe View Post
I wasn't using the KoboTouchExtended driver. I install it and disable the Kobo Reader device. But I get the same result.
If you weren't using the KoboTouchExtended driver, how where you getting the books to the device as kepub? Are you converting them? Or doing something else?

The "Kobo Reader device" does not come into this. It is used for the original Kobo ereader and the Kobo WiFi. All devices since then use the built-in KoboTouch driver, or if desired, the KoboTouchExtended driver.

But, for the moment, forget about how you are getting the book on the device. Look on the device. In the library list, does the books show as "epub" or "Kobo epub"? It has to be the latter for the image zoom to work. If the recent books are epubs, look for one that is a kepub and check it.
davidfor is offline   Reply With Quote
Old 04-16-2020, 10:01 AM   #5
thiago.eec
Wizard
thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.
 
Posts: 1,211
Karma: 1419583
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite, Kindle Oasis
Quote:
Originally Posted by jiembe View Post
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="100%" height="100%" viewBox="0 0 864 1228" preserveAspectRatio="XmidYmid">
<image width="864" height="1228" xlink:href="Map.jpg"/>
</svg>
I don't know if that might be the problem, but the preserveAspectRatio property is incorrectly set. I think you want this:

Code:
preserveAspectRatio="xMidYMid meet"
thiago.eec is offline   Reply With Quote
Advert
Old 04-16-2020, 10:13 AM   #6
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
Quote:
Originally Posted by davidfor View Post
If you weren't using the KoboTouchExtended driver, how where you getting the books to the device as kepub? Are you converting them? Or doing something else?

The "Kobo Reader device" does not come into this. It is used for the original Kobo ereader and the Kobo WiFi. All devices since then use the built-in KoboTouch driver, or if desired, the KoboTouchExtended driver.

But, for the moment, forget about how you are getting the book on the device. Look on the device. In the library list, does the books show as "epub" or "Kobo epub"? It has to be the latter for the image zoom to work. If the recent books are epubs, look for one that is a kepub and check it.
- I was using the Kobo Touch I supposed. I had never disabled the Kobo Reader device before.

- All my books are kepub.epub even the one I'm trying to make it work.
jiembe is offline   Reply With Quote
Old 04-16-2020, 10:44 AM   #7
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by jiembe View Post
- I was using the Kobo Touch I supposed. I had never disabled the Kobo Reader device before.

- All my books are kepub.epub even the one I'm trying to make it work.
Then I don't know what is happening. Though it might be what @thiago.eec noticed. Though, I would have expected that Kobo would be more likely to not display the image at all.

If you have a book that you can legally post, then we can have a look at it.

And, how exactly are you getting the books onto the device as kepubs? And, doe the device show they are kepubs in the library on the device? Yes, anything the double extension of ".kepub.epub" should be treated as a kepub, but, if unless after the book imported as a kepub, it will not be treated as one.
davidfor is offline   Reply With Quote
Old 04-16-2020, 11:58 AM   #8
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
Quote:
And, how exactly are you getting the books onto the device as kepubs?
I don't quite understand. I'm using the 'send to the device' from the primary Calibre window and send it as kepub. Is there another way?

Adding "meet" don't change anything. My comprehension is meet is implicit (default) when you use X_Y_. Anyway I try that correction without success.

It's look like I'm the only one with this problems! Strange.

The kepub sent to my kobo months ago are still working with the same code as the example.
jiembe is offline   Reply With Quote
Old 04-16-2020, 12:31 PM   #9
gbm
Wizard
gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.gbm ought to be getting tired of karma fortunes by now.
 
Posts: 2,188
Karma: 8888888
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
Quote:
Originally Posted by jiembe View Post
I don't quite understand. I'm using the 'send to the device' from the primary Calibre window and send it as kepub. Is there another way?

Adding "meet" don't change anything. My comprehension is meet is implicit (default) when you use X_Y_. Anyway I try that correction without success.

It's look like I'm the only one with this problems! Strange.

The kepub sent to my kobo months ago are still working with the same code as the example.
Lets delete the problem ebook from you kobo. Let the kobo update the data base, take your time.

Now resend to device.

See if the problem has gone away.

bernie
gbm is offline   Reply With Quote
Old 04-16-2020, 12:52 PM   #10
thiago.eec
Wizard
thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.
 
Posts: 1,211
Karma: 1419583
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite, Kindle Oasis
Quote:
Originally Posted by jiembe View Post
Adding "meet" don't change anything. My comprehension is meet is implicit (default) when you use X_Y_. Anyway I try that correction without success.
Yes, meet/slice are optional and meet is default. But the property value is case sensitive. Using XmidYmid is incorrect. Use xMidYMid, instead.
thiago.eec is offline   Reply With Quote
Old 04-16-2020, 02:08 PM   #11
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
Quote:
Lets delete the problem ebook from you kobo. Let the kobo update the data base, take your time.

Now resend to device.
Yes it work. It could mean I cannot just update the books in the kobo if I have SVG.

I will try to find some not working SVG kepub to see if this is the solution for all.
jiembe is offline   Reply With Quote
Old 04-16-2020, 09:24 PM   #12
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by jiembe View Post
I don't quite understand. I'm using the 'send to the device' from the primary Calibre window and send it as kepub. Is there another way?
Using "Send to device" is the way to get the book on the device. But, as calibre doesn't support kepubs out of the box, you have to do something more to be able to send kepubs to the device. Have you added the books to calibre as kepubs? Have you converted books to kepubs? The most common and simplest way is to use the KoboTouchExtended driver. But, you say that isn't installed.

But, the question I had was to check what the device was seeing the book as. Forget about what you think the book is, that doesn't matter. What matters is what format the device is actually detecting and handling the book as. If "KOBO EPUB" does not show against the book when you look at it in the library on the device, it will not be treated as a kepub, and you will not be able to zoom in on images in it. It is important to check that. Once we know that, then we will at least eliminate a possibility.
Quote:
Adding "meet" don't change anything. My comprehension is meet is implicit (default) when you use X_Y_. Anyway I try that correction without success.
How are you making this change? You cannot edit a kepub in calibre or Sigil. You must be editing the epub version. Or the AWZ3 version. You then need to convert this to kepub to get it on the device. How are you doing that?

And the "meet" default to something. I don't remember what, but it isn't the best choice for centering images. And if the "meet" is missing, it will not affect how the Kobo device will handle the image for zooming, just how it is displayed in the defined viewport.
Quote:
It's look like I'm the only one with this problems! Strange.

The kepub sent to my kobo months ago are still working with the same code as the example.
And that tells me that no matter what else you say, something has changed. My bet is that the books that work have been sent as kepubs properly and show in the devices library as "KOBO EPUB". And the ones that don't have been sent as epubs and show in the devices library as "EPUB".
davidfor is offline   Reply With Quote
Old 04-17-2020, 08:44 AM   #13
jiembe
Zealot
jiembe began at the beginning.
 
Posts: 145
Karma: 10
Join Date: Sep 2016
Location: Montréal Québec
Device: Kobo Glo; Kobo Libra
Quote:
And that tells me that no matter what else you say, something has changed.
Well. Since it was looking I was the only one with the problem I started to suspect my Kobo device. And last night I got to fatal error message from calibre unable to access to the device database result I think of the manipulations I've done yesterday with the plugins.

I've done a reinitialling this morning and the faulty SVG Kepub work well (now at least).

I'm my last post I wrote
Quote:
Yes it work [deleting and resenting]
In fact it works once but not after rebooting.

Now begin the long process of classifying manually the books in the kobo collections (or shelf ?).

Last edited by jiembe; 04-17-2020 at 08:58 AM.
jiembe is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
font size problem calibre viewer, editor, content-server with non-resizing SVG text rjwse@aol.com Editor 11 03-26-2020 12:06 AM
Resizing photos Cinisajoy Lounge 10 11-27-2017 06:41 PM
Can't add cover in Calibre -- get "svg-error" (the property 'svg' should be declared) Just some guy Editor 7 04-11-2017 09:54 PM
Svg wrapper and image resizing Nabodita ePub 24 05-02-2014 12:21 AM
resizing of svg logo with text increasing and decreasing in epub ashokbnpal Introduce Yourself 0 07-21-2011 04:26 AM


All times are GMT -4. The time now is 03:35 PM.


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