07-05-2012, 02:56 PM | #61 | |
Hedge Wizard
Posts: 802
Karma: 19999999
Join Date: May 2011
Location: UK/Philippines
Device: Kobo Touch, Nook Simple
|
Problems Converting mobi Files
Quote:
I tried removing the line - font-family: "LiberationSerif" ; - from "Look and Feel" - Extra CSS. I then converted the same mobi file and this time it did not damage the OPF so that all the files could be seen in Sigil. Thanks must go to Kovid for his helping to sort this out. If hope someone with more time and knowledge than myself will amend the plugin as I have found it very useful. |
|
01-04-2013, 07:39 AM | #62 | |
Member
Posts: 12
Karma: 10
Join Date: Jul 2012
Device: Boox M92
|
Fonts: Installed vs Embedded
Quote:
Hi there, the comma separated list does give a list of what fonts to use if the 'system' cannot find a particular font. For instance: In the style.css file you might have: @font-face { font-family: "Liberation", Arial, sans-serif; font-weight: normal; font-style: normal; src: url(../Fonts/LiberationSans-Regular.otf); } The above means - if you can't find font family "Liberation" then use Arial. If you cannot find Arial then use any font that is sans-serif. I believe the use of quotes in such declarations is to handle font family names which have spaces in - e.g.: "Liberation Sans". Note that the fall back strategy is important for those who are testing their ePub document with embed fonts. If your Windows or Linux system has these fonts installed already, then some ePub readers will use those fonts - SIGIL for instance. In contrast, So you assume that the embed fonts are working. However, when you transfer the ePub document to your eReader, the embed font does not work. From my experience, Calibre uses the embed font. |
|
Advert | |
|
01-04-2013, 08:07 AM | #63 | |
frumious Bandersnatch
Posts: 7,537
Karma: 19000627
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Quote:
Code:
p { font-family: "Liberation", Arial, sans-serif; } Code:
@font-face { font-family: "Liberation"; font-weight: normal; font-style: normal; src: url(../Fonts/LiberationSans-Regular.otf); } |
|
01-04-2013, 11:57 PM | #64 |
Booklegger
Posts: 1,801
Karma: 7999816
Join Date: Jun 2009
Location: Toronto, Ontario, Canada
Device: BeBook(1 & 2010), PEZ, PRS-505, Kobo BT, PRS-T1, Playbook, Kobo Touch
|
I'm quite sure Jelby is right, having found and fixed this sort of problem elsewhere.
The @font-face is a declaration of a font, which can be found in a particular src: url(). The font-family in a style is a reference to a desired font, so the fallback list is appropriate there. |
01-05-2013, 02:02 AM | #65 |
Well trained by Cats
Posts: 30,454
Karma: 58055868
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Jelby is correct:
In the @fontface, you are specifying the definition of a single fonts relationship to a family: "Liberation" (it take 4 font weight/stokes to fully define a full family. normal, bold, italic, bold-italic) The font-family in the (style) usage, gets the fallbacks |
Advert | |
|
01-05-2013, 01:52 PM | #66 | |
Member
Posts: 12
Karma: 10
Join Date: Jul 2012
Device: Boox M92
|
Quote:
Kevin |
|
01-07-2013, 03:59 PM | #67 | |
Resident Curmudgeon
Posts: 76,513
Karma: 136565488
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
The current version of Calibre has font subsetting. Subsetting is where when Calibre converts to ePub (maybe AZW3 as well) it checks which embedded fonts are used and also which characters from which fonts. So if you embed a 4 family font in your ePub and the bold italic version is not used, Calibre would delete it. Subsetting also will remove characters from the font(s) that are not used in that specific ePub. So it makes the font files smaller for the used fonts and between cutting out unused fonts/characters, this can make the ePub significantly smaller. What I do once the ePub is done other then subsetting, I load that into Calibre, convert the ePub > ePub (turning on font subsetting in Look & Feel) and in the converted ePub, extract the font directory to replace the font directory in the finished ePub. Then I edit the CSS & OPF as needed for any fonts that were deleted. Once that's done and the ePub validates, I delete the two ePub in Calibre and put in the finished ePub to eventually go on my Reader. |
|
01-30-2013, 11:31 AM | #68 |
A Hairy Wizard
Posts: 3,228
Karma: 19001261
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
Thanks Jon - that is exactly what I was looking for!
I thought I had seen something on MR that someone was making a plugin for Sigil to do all of that automatically...have you heard/seen anything? [edit] Found it! Not a plugin, but a standalone. Last edited by Turtle91; 01-30-2013 at 11:53 AM. |
01-30-2013, 02:37 PM | #69 | |
Resident Curmudgeon
Posts: 76,513
Karma: 136565488
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
01-31-2013, 10:59 AM | #70 |
Grand Sorcerer
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
|
You could also use the Font Squirrel's @font-face Generator in expert mode, which offers more settings than Toxaris's standalone app, to subset fonts.
|
01-31-2013, 11:23 AM | #71 |
A Hairy Wizard
Posts: 3,228
Karma: 19001261
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
Does Font Squirrel scan a document and only provide the characters 'used', or do you need to manually delete the un-used?
|
01-31-2013, 12:26 PM | #72 |
Grand Sorcerer
Posts: 5,640
Karma: 23191067
Join Date: Dec 2010
Device: Kindle PW2
|
Font Squirrel doesn't allow you to exclude unused characters. You can only select glyphs by Unicode ranges, languages or character types (uppercase, lowercase, numbers, punctuation etc.)
IMHO, excluding unused glyphs offers only minimal size advantages. Also if you find a font that you like, you'd have to run the subsetter each time you create a new book to make sure that all characters are included in the subset font. |
01-31-2013, 12:50 PM | #73 | |
A Hairy Wizard
Posts: 3,228
Karma: 19001261
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
Quote:
Thanks for the suggestion though! |
|
01-31-2013, 02:55 PM | #74 |
Wizard
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
|
Keep in mind that Font Squirell will not subset all fonts. Quite a number of fonts are blacklisted.
Also, John, I take some offense to your words. My program was not intended to work as you would like, it works as I wanted. The fact that I am working on a new version that can open ePUB is because I can see some need for it for myself and some others. Quite frankly I don't care if it works better for you. You never ask for something, you demand. |
11-10-2014, 08:14 PM | #75 |
Junior Member
Posts: 3
Karma: 10
Join Date: Oct 2014
Device: none
|
problem with embedfont_plugin.zip in Calibre 2.7 on Linux server
Hello, could anybody help me?
I make conversion of DOCX to EPUB, using Calibre command line. I use all recomandations, writen in this thread, for using plugin embedfont_plugin.zip If I use original plugin version form P.T. in win7 with Calibre 2.7, it works perfect. If I use the same on Linux server with Calibre 2.7. files with fonts are not placed into epub file and error messages written below are displayed in terminal. If I used modified version of plugin form artshim it does not work in win7 with Calibre 2.7 and it does not work in Linux with Calibre 2.7 too. In both operation systems terminal displays the same erro as for plugin from P.T. The error messages are these: Error: Can't find liberation fonts. Running file type plugin EPUB Font embedding plugin failed with traceback: Traceback (most recent call last): File "site-packages/calibre/customize/ui.py", line 154, in _run_filetype_plugins File "calibre_plugins.dummy1.__init__", line 88, in run SystemExit: 0 EPUB output written to /u1/myusername/opt/calibre/KnihaVystup.epub Output saved to /u1/myusername/opt/calibre/KnihaVystup.epub |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Can it embed fonts? | chalimac | Kobo Reader | 1 | 06-27-2017 06:46 PM |
Best Practice: Embed Fonts?? | luthar28 | ePub | 37 | 11-01-2011 05:16 AM |
Possible to embed fonts in CSS of .lit file? | tanzer21 | Calibre | 9 | 06-30-2010 08:26 PM |
Is it possible to UN embed fonts? | lmronan | Sigil | 14 | 06-04-2010 10:26 AM |
Any free software can embed fonts in epub | droople | ePub | 4 | 03-06-2010 06:40 PM |