View Single Post
Old 01-14-2012, 06:55 PM   #6
Morkl
Connoisseur
Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.Morkl can talk to the animals.
 
Posts: 80
Karma: 68347
Join Date: Oct 2009
Location: Sweden
Device: PRS-T1
These are the @font-face directives that the Sony software generates for Amasis:
Code:
@font-face{ font-family: serif; font-style:normal; font-weight:normal; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
@font-face{ font-family: serif; font-variant:small-caps; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
@font-face{ font-family: serif; font-style:italic; font-weight:normal; src: url(res:///ebook/fonts/AmasisMTW1G-Italic.otf);}
@font-face{ font-family: serif; font-style:normal; font-weight:bold; src: url(res:///ebook/fonts/AmasisMTW1G-Bold.otf);}
@font-face{ font-family: serif; font-style:italic; font-weight:bold; src: url(res:///ebook/fonts/AmasisMTW1G-BoldItalic.otf);}
@font-face{ font-family: sans-serif; font-style:normal; font-weight:normal; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
@font-face{ font-family: sans-serif; font-variant:small-caps; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
@font-face{ font-family: sans-serif; font-style:italic; font-weight:normal; src: url(res:///ebook/fonts/AmasisMTW1G-Italic.otf);}
@font-face{ font-family: sans-serif; font-style:normal; font-weight:bold; src: url(res:///ebook/fonts/AmasisMTW1G-Bold.otf);}
@font-face{ font-family: sans-serif; font-style:italic; font-weight:bold; src: url(res:///ebook/fonts/AmasisMTW1G-BoldItalic.otf);}
I put them in a sample document and tested it, and italics and bold did not work. Turns out the following lines break things:
Code:
@font-face{ font-family: serif; font-variant:small-caps; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
and/or
@font-face{ font-family: sans-serif; font-variant:small-caps; src: url(res:///ebook/fonts/AmasisMTW1G.otf);}
Any CSS gurus here that know how to fix them?

In the meantime, here is a EbookReader.apk with the small-caps bits removed:
http://morkl.se/reader/readermod_v1.zip (has its own package name, so it installs as normal APK and the stock reader does not need to be removed)
I tested it with a sample document and all the internal fonts seem to work with bold/italics, via the font selector.
Morkl is offline   Reply With Quote