Mobileread
Font Embedding?
#1  teh603 08-15-2012, 11:03 PM
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.
Reply 

#2  weedfreak 08-21-2012, 10:35 AM
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.
Reply 

#3  eBookLuke 08-22-2012, 01:50 AM
Font embedding is still work in progress, sorry.
Luke
Reply 

#4  Freeshadow 08-23-2012, 02:39 PM
Quote weedfreak
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.
Reply 

#5  teh603 09-04-2012, 09:32 AM
Quote weedfreak
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.
Reply 

#6  weedfreak 09-07-2012, 02:43 AM
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.
Reply 

#7  Freeshadow 09-07-2012, 07:17 AM
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
Reply 

#8  eBookLuke 09-08-2012, 01:06 AM
Quote Freeshadow
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
Reply 

#9  eBookLuke 09-08-2012, 01:12 AM
Quote weedfreak
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
Reply 

#10  Freeshadow 09-28-2012, 05:18 PM
Quote eBookLuke
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.
Reply 

  Next »  Last »  (1/8)
Today's Posts | Search this Thread | Login | Register