View Single Post
Old 10-24-2017, 12:40 PM   #1
roger64
Wizard
roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.roger64 ought to be getting tired of karma fortunes by now.
 
Posts: 2,625
Karma: 3120635
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
Darkening and subsetting fonts

Hi

Here are the results of some trials.

To begin, you'll find four (there are more of them) otf fonts of the Linux Libertine O family. Please note that these fonts are published under the GPL license, and that the further modified and renamed fonts below share of course the same license. They are in the folder: "A original fonts".

These fonts have been darkened using the nice script of Sherman Perry, ReadifyFont.

Quote:
The "latest" version can be found here: https://github.com/shermp/ReadifyFon...ceImprovements
I selected two different darkening levels from a range from 0 to 50 and modified accordingly their side-bearings: 30 is nearly a semi-bold value, while 20 is only neatly darker. I produced four ttf fonts, renamed LibertineO-G30 or LibertineO-G20. The Bold and BoldItalic fonts have not been darkened. These fonts can of course be installed permanently on your system or side-loaded in any decent ebook-reader (like Koreader). They are in the folder: "B darkened."

These darkened fonts have been subsetted with pyftsubset (a part of the fonttools project) against the list of characters named characters330 which contains the 110 unicode characters of the joint EPUB (the list is produced by the reports tool of the Calibre Editor). The subsets are in the folder: "C subsets."

I also joined the test EPUB with its subsetted -and darkened- fonts. It passes the epubcheck validation test.

About size

This way one can embed subsets of any font, including a customized one. Here the regular subset size used for the EPUB is about 44k, and the italic one, 37k (from a common 110 characters list).

As we make it work currently with a single list of characters, pyftsubset can provide a clear size saving advantage if the book use only both regular and italic fonts. This advantage could be greatly reduced, even nullified, if we had to include bold and bolditalics fonts.
Attached Files
File Type: zip trials.zip (4.24 MB, 838 views)

Last edited by roger64; 10-31-2017 at 03:26 AM. Reason: size saving
roger64 is offline   Reply With Quote