Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Writer2ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-15-2012, 11:03 PM   #1
teh603
Snarky Snark
teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.
 
teh603's Avatar
 
Posts: 1,198
Karma: 6244877
Join Date: Sep 2011
Location: Coastal Texas
Device: Asus TF300
Font Embedding?

Are there any updates on font embedding in Writer2ePub?

I'm curious because there's some FOSS fonts I've got that would be great in an ePub, but at this point there doesn't seem to be any way to embed them.
teh603 is offline   Reply With Quote
Old 08-21-2012, 10:35 AM   #2
weedfreak
Addict
weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.
 
weedfreak's Avatar
 
Posts: 302
Karma: 185297
Join Date: Sep 2009
Location: Ankh Morpork
Device: calibre
Not really sure why anyone would want to embed fonts in an ebook, unless it is a few fancy illuminated caps perhaps. First thing I do is delete embedded fonts.

In any case there seems to be an option to do it in document preferences, you may need to edit the macro to get your font in the list.
weedfreak is offline   Reply With Quote
Old 08-22-2012, 01:50 AM   #3
eBookLuke
Writer2ePub creator
eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.
 
eBookLuke's Avatar
 
Posts: 341
Karma: 106889
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
Font embedding is still work in progress, sorry.
Luke
eBookLuke is offline   Reply With Quote
Old 08-23-2012, 02:39 PM   #4
Freeshadow
temp. out of service
Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.
 
Posts: 2,252
Karma: 12572656
Join Date: May 2010
Location: Duisburg (DE)
Device: BeBook mini
Quote:
Originally Posted by weedfreak View Post
Not really sure why anyone would want to embed fonts in an ebook(...) First thing I do is delete embedded fonts.
Since the "why" has already been covered in a fair bunch of threads I suggest you take a sheet of paper and write: "Not everyone lives in ASCII-land; not every firmware supplies fonts for every language." 100 times.
Freeshadow is offline   Reply With Quote
Old 09-04-2012, 09:32 AM   #5
teh603
Snarky Snark
teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.
 
teh603's Avatar
 
Posts: 1,198
Karma: 6244877
Join Date: Sep 2011
Location: Coastal Texas
Device: Asus TF300
Quote:
Originally Posted by weedfreak View Post
Not really sure why anyone would want to embed fonts in an ebook, unless it is a few fancy illuminated caps perhaps. First thing I do is delete embedded fonts.

In any case there seems to be an option to do it in document preferences, you may need to edit the macro to get your font in the list.
Because that way I'd be able to set the title on the title page and the chapter headings in the same font that I used on the cover. I also like setting text in Bookman or a FOSS equivalent (like TexGyre Bonum) instead of Times New Roman; TNR is a very light, tight-kerning face and I've never really liked how it can shave two or three pages off your final page count on a long writing project.

That having been said, I feel your pain when it comes to people trying to set their entire book in something ridiculous like Comic Sans.
teh603 is offline   Reply With Quote
Old 09-07-2012, 02:43 AM   #6
weedfreak
Addict
weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.weedfreak can program the VCR without an owner's manual.
 
weedfreak's Avatar
 
Posts: 302
Karma: 185297
Join Date: Sep 2009
Location: Ankh Morpork
Device: calibre
I can understand that use for embeded fonts even if I do not agree with the bloat introduced by the process, I also dislike Times New Roman - Comic Sans is almost preferable to it.

If I remember correctly the standard W2Epub CSS file sets font family to Garamond, serif, sansserif, monospace. It is easy to change that with Macro editor so you can list fonts by your preference in the hope that readers have the first or second choice fonts installed. I realise this is not ideal for what you want but it does give some control over the rendered look.

An option that I have seen used for title page and headers is to create them as images. This is also not ideal as some readers do not dislay images well. FBReader will only display images if the file structure is none standard, flat, that is all files in one directory.

I am not sure there is a simple solution unless you create the ebook in W2Epub then edit it further with something like Sigil, which has a habit of changing your styles with informing you, but does allow font embeding.
weedfreak is offline   Reply With Quote
Old 09-07-2012, 07:17 AM   #7
Freeshadow
temp. out of service
Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.
 
Posts: 2,252
Karma: 12572656
Join Date: May 2010
Location: Duisburg (DE)
Device: BeBook mini
The bloat problem is a different one:
Solution would be a script analysing the epub in question, create lists of used chars only of every used fontfile (+ ligatures where fitting pairs appear) and pass them via python to fontforge to make an individually tailored subset *tf
Freeshadow is offline   Reply With Quote
Old 09-08-2012, 01:06 AM   #8
eBookLuke
Writer2ePub creator
eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.
 
eBookLuke's Avatar
 
Posts: 341
Karma: 106889
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
Quote:
Originally Posted by Freeshadow View Post
The bloat problem is a different one:
Solution would be a script analysing the epub in question, create lists of used chars only of every used fontfile (+ ligatures where fitting pairs appear) and pass them via python to fontforge to make an individually tailored subset *tf
The eBook Club Italia is working to a such solution since one year…
We have a working software prototype, as soon as we find time to spend on it, we will release a tool online for this job.
Freeshadow, if you are an experienced Python programmer and you have time to spend, wish you help us in this project?
If so, feel free to contact me in PM

Luke
eBookLuke is offline   Reply With Quote
Old 09-08-2012, 01:12 AM   #9
eBookLuke
Writer2ePub creator
eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.eBookLuke is the king of the Divan.
 
eBookLuke's Avatar
 
Posts: 341
Karma: 106889
Join Date: Sep 2009
Location: Genova, Italy
Device: Cybook Bebook iLiad Kindle HanlinV2 Readius SonyPRS500 SonyPRS700 etc
Quote:
Originally Posted by weedfreak View Post
If I remember correctly the standard W2Epub CSS file sets font family to Garamond, serif, sansserif, monospace.
More or less…
Was true in the first version, now I don't set anymore any font.

Now my goal is to check the glyphs used in the document, and warning the user if some non-ade glyph is present in the document.

Luke
eBookLuke is offline   Reply With Quote
Old 09-28-2012, 05:18 PM   #10
Freeshadow
temp. out of service
Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.
 
Posts: 2,252
Karma: 12572656
Join Date: May 2010
Location: Duisburg (DE)
Device: BeBook mini
font file stripping

Quote:
Originally Posted by eBookLuke View Post
The eBook Club Italia is working to a such solution since one year…
We have a working software prototype, as soon as we find time to spend on it, we will release a tool online for this job.
Freeshadow, if you are an experienced Python programmer and you have time to spend, wish you help us in this project?
If so, feel free to contact me in PM

Luke
Hi Luke,

I couldn't even hello world in python

I just was thinking about if and how such font stripping could be possible since I read a posting confirming that someone got in trouble embedding a commercial font. (I think Dennis posted)
Keeping in mind that commercial full utf-range containing fonts are not only expensive (thinking about the Linotype collection CDs here... 4 digit prices) but huge too (isn't, the full UTF Times New Roman, according to Wikipedia several megabytes big?)
It would make sense to strip them for several reasons:

1.)I can't think of a book really needing ALL of the glyphs: several languages (some purely historic), math, physics etc. and the kitchen sink.

If a book with such needs exists it makes the Rosetta Stone look like a nursery rhyme. I think such a case is highly improbable.

So let's strip and save size.

When we remove the unused glyphs without changing the location of the used ones inside the font it should be fine with the epub specs I think.

2.) when stripped, to strictly! what's needed in a specific epub, then renamed because of said modifications, replace the original fontfiles in the epub and finally run pdurrands obfuscation script over it.

The result would be as close to font embedding like it's done with PDFs, as it can be done with epubs.

And now the real kicker:
This similarity should give a way to use fonts acquired under pre-epub licensing terms because as with PDFs the embedded data would be neither easily readable nor complete.
Et voilà no problems with using commercial fonts anymore.

IMO you should present the project of the ebook club at the epub general forum for all the reasons above.
Freeshadow is offline   Reply With Quote
Old 09-28-2012, 05:39 PM   #11
pdurrant
The Grand Mouse
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 30,842
Karma: 85467920
Join Date: Jul 2007
Location: Norfolk, England
Device: NOOK ST GlowLight
Quote:
Originally Posted by Freeshadow View Post
I just was thinking about if and how such font stripping could be possible since I read a posting confirming that someone got in trouble embedding a commercial font. (I think Dennis posted)
Keeping in mind that commercial full utf-range containing fonts are not only expensive (thinking about the Linotype collection CDs here... 4 digit prices) but huge too (isn't, the full UTF Times New Roman, according to Wikipedia several megabytes big?)
It would make sense to strip them for several reasons:
I think this is a great idea. Quite tricky to do, but a really great idea.
pdurrant is offline   Reply With Quote
Old 09-28-2012, 06:22 PM   #12
Freeshadow
temp. out of service
Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.Freeshadow ought to be getting tired of karma fortunes by now.
 
Posts: 2,252
Karma: 12572656
Join Date: May 2010
Location: Duisburg (DE)
Device: BeBook mini
Well isn't Calibre doing exactly part of the job? Parsing epubs in python? I notified Kovid about the idea here... Interested what he might have to say.

I was thinking about the problem since here: http://www.mobileread.com/forums/sho...6&postcount=15

and tought about how to best present the idea to the python savvy ones on MR, then Luke wrote here that such a thing is already in the making - sparing me a definitely heavy task of composing a teal deer post hoping some coders might find it useful too.
We know what's commonly said about a user with an idea don't we?

Personally I think such a finalizing tool could make epubs compatible to the majority of commercial font licenses.
And THAT would be a hell of a breakthrough in production of commercially usable epubs.
Freeshadow is offline   Reply With Quote
Old 09-28-2012, 11:20 PM   #13
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: 25,441
Karma: 4961459
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
http://www.mobileread.com/forums/showthread.php?t=81378
kovidgoyal is online now   Reply With Quote
Old 09-29-2012, 02:59 AM   #14
pdurrant
The Grand Mouse
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 30,842
Karma: 85467920
Join Date: Jul 2007
Location: Norfolk, England
Device: NOOK ST GlowLight
What I think Kovid is saying is that calibre has all the XHTML/CSS parsing code needed, and all that would need to be added to calibre would be font subsetting code and some UI elements to turn it on during ePub->ePub 'conversion'.
pdurrant is offline   Reply With Quote
Old 09-29-2012, 09:36 AM   #15
teh603
Snarky Snark
teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.teh603 ought to be getting tired of karma fortunes by now.
 
teh603's Avatar
 
Posts: 1,198
Karma: 6244877
Join Date: Sep 2011
Location: Coastal Texas
Device: Asus TF300
Quote:
Originally Posted by Freeshadow View Post
1.)I can't think of a book really needing ALL of the glyphs: several languages (some purely historic), math, physics etc. and the kitchen sink.

If a book with such needs exists it makes the Rosetta Stone look like a nursery rhyme. I think such a case is highly improbable.

So let's strip and save size.

When we remove the unused glyphs without changing the location of the used ones inside the font it should be fine with the epub specs I think.
What's wrong with just embedding the original font file? One of my favorites only weighs in around 140k. That isn't very big.
teh603 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Another problem embedding font Alabala ePub 26 08-02-2012 05:19 PM
Font embedding sachin Sigil 36 03-30-2012 03:26 AM
Font embedding sachin Sigil 3 03-21-2012 09:19 AM
Do I need a font license if all I'm doing is referring to the font (not embedding)? Stodder Workshop 21 04-21-2011 04:19 AM
Font embedding error Peto Calibre 2 08-05-2008 10:40 AM


All times are GMT -4. The time now is 03:42 AM.


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