Register Guidelines E-Books Today's Posts Search

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

Notices

Closed Thread
 
Thread Tools Search this Thread
Old 11-22-2013, 06:35 AM   #76
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 918
Karma: 1803094
Join Date: Jun 2011
Device: PC, t1, t2, t3, aura 2 v1, clara HD, Libra 2, Nxtpaper 11
I see that font files do not yet appear under the Fonts section, but rather under the Miscellaneous section. A known issue I assume?
Attached Thumbnails
Click image for larger version

Name:	calibre.png
Views:	247
Size:	8.2 KB
ID:	115574  
DrChiper is offline  
Old 11-22-2013, 06:44 AM   #77
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No fonts should be recognized. I am guessing that the mimetype for the fonts in the opf is incorrect. calibre uses font media types from here:

http://idpf.org/epub/30/spec/epub30-...re-media-types
kovidgoyal is offline  
Advert
Old 11-22-2013, 07:27 AM   #78
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 918
Karma: 1803094
Join Date: Jun 2011
Device: PC, t1, t2, t3, aura 2 v1, clara HD, Libra 2, Nxtpaper 11
Quote:
Originally Posted by kovidgoyal View Post
No fonts should be recognized.
I'm afraid I do not follow you here. My test file does contain font files.

Quote:
Originally Posted by kovidgoyal View Post
I am guessing that the mimetype for the fonts in the opf is incorrect.
Sigil reports the exact same test file as shown in the attachement. Hence, I doubt whether the opf is incorrect. In fact Sigil reports "No problems". I attach my test file for your consideration.
Attached Thumbnails
Click image for larger version

Name:	calibre.png
Views:	279
Size:	10.7 KB
ID:	115575  
Attached Files
File Type: epub Test2.epub (316.0 KB, 164 views)

Last edited by DrChiper; 11-22-2013 at 07:31 AM.
DrChiper is offline  
Old 11-22-2013, 08:20 AM   #79
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Change the mimetype in the opf from application/x-font-ttf to application/x-font-truetype and the font files will be recognized.

In any case, I will change it in the next release to recognize font files even if their mimetype is incorrect.
kovidgoyal is offline  
Old 11-22-2013, 08:48 AM   #80
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 918
Karma: 1803094
Join Date: Jun 2011
Device: PC, t1, t2, t3, aura 2 v1, clara HD, Libra 2, Nxtpaper 11
Quote:
Originally Posted by kovidgoyal View Post
Change the mimetype in the opf from application/x-font-ttf to application/x-font-truetype and the font files will be recognized.
I did and Sigil now complains (for every entry):
The <item> element's "media-type" attribute has value "application/x-font-truetype", but the file's media type is "application/x-font-ttf".

According your answer I can assume Sigil is wrong for this notification?

BTW: The font files are now indeed correctly recognized by calibre.

Googeling, I found this which might explain Sigil behavior:

Apparently ISO/IEC JTC 1/SC34 are working on a new font top-level metatype. But on
the other hand they also recognize "application/x-font-ttf" as being the
experimental (read: not standardized) de facto MIME type for Truetype fonts.
Number of Google hits for all three possibilities:
"application/x-truetype-font" 2100
"application/x-font-truetype" 4100
"application/x-font-ttf" 45900

So "application/x-font-ttf" it is. It beats the other two by an order of magnitude. I know it's not an *official* standard, but it is a de facto one, and even ISO/IEC JTC 1/SC34 recognizes it. So it should probably be enforced as an industry best practice.

Last edited by DrChiper; 11-22-2013 at 08:59 AM.
DrChiper is offline  
Advert
Old 11-22-2013, 09:53 AM   #81
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
See the link I posted earlier, the value calibre uses comes from the epub 3.0 specification. The epub 2.0 specification does not specify anything for the mimetype for font files, therefore calibre uses the values from the epub 3.0 spec.

In practice, it does not matter. No software that I know of cares which one you use. As I said, I will change Tweak Book to ignore incorrect mimetypes for font files in the future.
kovidgoyal is offline  
Old 11-22-2013, 10:00 AM   #82
DrChiper
Bookish
DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.DrChiper ought to be getting tired of karma fortunes by now.
 
DrChiper's Avatar
 
Posts: 918
Karma: 1803094
Join Date: Jun 2011
Device: PC, t1, t2, t3, aura 2 v1, clara HD, Libra 2, Nxtpaper 11
Ok Kovid, its clear. Thanks for the explanation.
DrChiper is offline  
Old 11-29-2013, 12:27 AM   #83
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
This weeks release has support for renaming files, splitting/merging of files and pretty printing of all html/css/opf/ncx files. The pretty printing even pretty prints css embedded inside html files.

You can split by clicking the split button under the preview panel and then clicking in the preview panel at the location you want the split to happen.

You can merge by selecting multiple files in the files browser and right clicking.

Rename files by right clicking.

Pretty print by clicking the pretty print button in the editor toolbar or pretty print all files via the Tools menu.

splitting/merging/renaming should automatically fix all links and references to the affected files.
kovidgoyal is offline  
Old 11-29-2013, 03:11 AM   #84
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,163
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
Kovid, when did the split happen?

I can click the button and go with the mouse in the preview-window. There I can see a green line. After I click on a position, nothing happen. Maybe I am doing something wrong.

Calibre64 1.13.0
Windows Vista64
Divingduck is offline  
Old 11-29-2013, 03:19 AM   #85
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
The split happens immediately (it might take a few seconds depending on the size of the file being split). You should see a new file in the files browser on the left.
kovidgoyal is offline  
Old 11-29-2013, 03:26 AM   #86
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,163
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
No, thats what I was looking for. I try it with 2 files, a big one and a smal one.
I try to do it in the 32 and 64 bit Version.
Divingduck is offline  
Old 11-29-2013, 03:31 AM   #87
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
I haven't tested it on windows, but it should make no difference. Can you post a file for which it is failing.
kovidgoyal is offline  
Old 11-29-2013, 03:35 AM   #88
tmc
Junior Member
tmc began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jan 2013
Device: none
Hi kovid,
it doesnt work me either, It gives following error
preview js:undefined:281: TypeError: cannot call request_split(): unknown type `QList<int>'
tmc is offline  
Old 11-29-2013, 03:37 AM   #89
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,163
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
I did it with the file from DrChiper and a other one. I can upload it in launchpad if you like.

I will try a test in ubunto too.
Divingduck is offline  
Old 11-29-2013, 03:44 AM   #90
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 44,001
Karma: 22669822
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Ah another problem caused by the difference between PyQt on my dev machine and the build machine. Sigh. I will upload fixed builds in a bit.
kovidgoyal is offline  
Closed Thread


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to make Sigil live varlog Sigil 136 10-25-2013 02:34 PM
how many tocs does Sigil make? Gregg Bell Sigil 17 01-31-2013 09:39 AM
How do I make all .pdf's in my calibre library open in calibre instead of preview morbo3000 Library Management 9 07-30-2011 10:39 AM
using sigil to make changes befote conversion alansplace Sigil 11 06-07-2011 07:50 AM
i can't make sigil run in fedora 14 nastarovia Sigil 1 01-20-2011 05:02 AM


All times are GMT -4. The time now is 02:15 PM.


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