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

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 11-26-2009, 06:56 PM   #1
erik5000
Member
erik5000 began at the beginning.
 
Posts: 15
Karma: 12
Join Date: Nov 2009
Device: sony prs600
Embedded fonts in epub

I have made an epub book and it works well. Only I try to embed a Garamond font and it does not show up on the Sony PRS600. The font stays Times New Roman-like.
The underlying HTML file shows up OK in Firefox, CSS and all.
I mentiooned the OTF in the content.opf ok...
Tried ttf and otf font... all NO GO !
Anyone succeeded in embedding fonts on this machine ?
please help !
erik5000 is offline   Reply With Quote
Old 11-26-2009, 07:57 PM   #2
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 37,777
Karma: 18492088
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
Have a look at The Secret Adversary by Agatha Christie. It is an ePub with embedded fonts. You can have a look and see how it's done.

http://www.mobileread.com/forums/showthread.php?t=53913
JSWolf is offline   Reply With Quote
Old 12-03-2009, 02:12 AM   #3
quillaja
Connoisseur
quillaja began at the beginning.
 
quillaja's Avatar
 
Posts: 79
Karma: 42
Join Date: Sep 2009
Device: sony reader touch (prs-600)
did you change the CSS to style the text with the new font? just sticking the file into the epub won't change anything (except the size of the epub). don't forget to reference the font file in the manifest, too.

this post here has some details. it says it's for "after calibre" but the process is exactly the same.

http://www.mobileread.com/forums/showthread.php?t=61587

i've had no problem embedding a font and having it show up on my prs600, even a japanese font (for a japanese text).
quillaja is offline   Reply With Quote
Old 12-04-2009, 05:58 PM   #4
erik5000
Member
erik5000 began at the beginning.
 
Posts: 15
Karma: 12
Join Date: Nov 2009
Device: sony prs600
fonts in prs600

Yes, I did all those things.
Weird thing is, some <H1> headings show up in the correct font and others do not.
And another thing is, that FireFox (with epub plug-in) shows the embedded font alright, but the Adobe Digital Edition program does not, as does not the PRS600.
I show some parts of relevant files:
the CSS:

@font-face
{
font-weight: normal;
font-family: "TrumpMediaevalLTStd-Roman" ;
src: url(fonts/TrumpMediaevalLTStd-Roman.otf) ;
}

h3.toc_heading
{
margin-left: 24px;
font-family: "TrumpMediaevalLTStd-Roman";
}
h1
{
margin-top:12.0pt;
margin-right:0.5px;
margin-bottom:24.0pt;
margin-left:14.2pt;
text-indent:0pt;
font-size:140%;
font-family: "TrumpMediaevalLTStd-Roman" ;
}

a HTML file (showing the h3 right):

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="http://www.w3.org/1999/xhtml; charset=utf-8" http-equiv="Content-Type"/>
<link rel="stylesheet" type="text/css" href="ccjr2.css" />
<title>Table of Contents</title>
</head>
<body>
<h3 class="toc_heading">Table of Contents</h3>

Another HTML file (H1 showing the STANDARD font, not the mediaeval)
FF shows it right, but Adobe and the SOny NOT:

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="http://www.w3.org/1999/xhtml; charset=utf-8" http-equiv="Content-Type"/>
<link REL="stylesheet" href="ccjr2.css" type="text/css" />
<title>Introduction</title>
</head>
<body>
<p class="Author" style=" ">
Samuel Freeman
</p>
<h1>
Introduction
<br/>
John Rawls - An Overview
</h1>

and a piece of the <manifest> part of the OPF:

<item id="ClassGarmndItBT" href="fonts/ClassicalGaramondItalicBT.ttf" media-type="application/vnd-ms-truetype"/>
<item id="TrumpMediaevalLTStd-Italic" href="fonts/TrumpMediaevalLTStd-Italic.otf" media-type="application/vnd-ms-truetype"/>
<item id="TrumpMediaevalLTStd-Roman" href="fonts/TrumpMediaevalLTStd-Roman.otf" media-type="application/vnd-ms-truetype"/>
<item id="TrajanProBold" href="fonts/TrajanPro-Bold.otf" media-type="application/vnd-ms-truetype"/>
</manifest>

Anybody has a solution ??
erik5000 is offline   Reply With Quote
Old 12-05-2009, 09:04 PM   #5
jackie_w
Wizard
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 2,877
Karma: 4200035
Join Date: Sep 2009
Location: UK
Device: Sony PRS-350, PB360, Kobo Glo/AuraHD/Aura6"/AuraH2O
Hi Erik,
Does it make a difference if you add
font-style: normal;
to the @font-face in the CSS
i.e.

@font-face
{
font-style: normal;
font-weight: normal;
font-family: "TrumpMediaevalLTStd-Roman" ;
src: url(fonts/TrumpMediaevalLTStd-Roman.otf) ;
}
jackie_w is offline   Reply With Quote
Old 12-05-2009, 09:31 PM   #6
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 37,777
Karma: 18492088
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Sony Reader PRS-650, iPad, nook STR
You don't need font-weight, but you do need font-style.
JSWolf is offline   Reply With Quote
Old 12-08-2009, 11:59 AM   #7
erik5000
Member
erik5000 began at the beginning.
 
Posts: 15
Karma: 12
Join Date: Nov 2009
Device: sony prs600
grrrrrrr

Before assembling HTML files into an epub is is absolutely, unequivocally necessary to VALIDATE THE HTML.
As I just found out.

Adobe Digital Edition and Sony are by far not as easy-going as Firefox is.
Incomplete tag pairs are killing.
erik5000 is offline   Reply With Quote
Old 12-08-2009, 12:55 PM   #8
DaleDe
Grand Sorcerer
DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.DaleDe ought to be getting tired of karma fortunes by now.
 
DaleDe's Avatar
 
Posts: 9,725
Karma: 5072190
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2
Quote:
Originally Posted by erik5000 View Post
Before assembling HTML files into an epub is is absolutely, unequivocally necessary to VALIDATE THE HTML.
As I just found out.

Adobe Digital Edition and Sony are by far not as easy-going as Firefox is.
Incomplete tag pairs are killing.
Exactly, That is the difference between XHTML that ePUB uses and HTML that firefox reads.

Dale
DaleDe 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
HTML -> EPUB with no embedded fonts doremifaso Calibre 10 09-25-2010 06:56 AM
iPad iBooks, ePub, embedded fonts & encryption pdurrant Apple Devices 37 06-08-2010 02:24 PM
Opus Opus, ePub and 'embedded' fonts AnemicOak Bookeen 5 11-10-2009 01:21 PM
ePub embedded fonts JSWolf Ectaco jetBook 9 09-14-2009 09:43 PM
ePub + Embedded Fonts Cygfrydd ePub 11 03-02-2009 06:56 PM


All times are GMT -4. The time now is 09:29 AM.


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