![]() |
#1 |
Fanatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 558
Karma: 403106
Join Date: Aug 2014
Device: PRS-T1
|
Dynamic fonts?
I wonder whether there is any means to automatically change the .CSS files to fonts or fonts paths according to the eReader?
For instance if the actual device does not have the stock Arial font to point to the embedded (in ePub) one? I know this is (or should be) possible in ePub 3, but I wonder whether would be this possible with ePub 2. Thanks for any ideas. |
![]() |
![]() |
![]() |
#2 |
Addict
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
Afaik it's not possible with ePub 2. With ePub 3 you could use media queries to change fonts i think. You could also use javascript but the support for that is limited to a few devices.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,432
Karma: 48895676
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
you use a list in the font-family line of the class h3 { font-family:"Arial", "blabla", serif; } if it cant find Arial it tries for blabla if it cant find either, the devices: serif |
|
![]() |
![]() |
![]() |
#4 |
Fanatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 558
Karma: 403106
Join Date: Aug 2014
Device: PRS-T1
|
|
![]() |
![]() |
![]() |
#5 |
frumious Bandersnatch
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 7,466
Karma: 17555555
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Which is often a bad idea anyway, because at the end you have to rely on one of the standard font families (serif, sans-serif...), overriding whatever preferred font the user may have selected.
If you are going to distribute the book, use embedded fonts or none at all. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Fanatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 558
Karma: 403106
Join Date: Aug 2014
Device: PRS-T1
|
Well, the story goes as this: I use diacritics (a virgin domain for Englishmen
![]() I consider a bad idea anyway to mix typeface and sizes and colours in a book - a single font should suffices, add one more (eg serif sans-serif pair of the same typeface) and you're done. |
![]() |
![]() |
![]() |
#7 | |
frumious Bandersnatch
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 7,466
Karma: 17555555
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Quote:
I use diacritics, I specify a custom default font in my reader, if a book says "Arial, Verdana, sans-serif", it will just default to the default sans-serif font in my reader, which is neither my choice or your choice, and lacks many characters. |
|
![]() |
![]() |
![]() |
#8 |
Fanatic
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 558
Karma: 403106
Join Date: Aug 2014
Device: PRS-T1
|
I didn't say "random" and it was not my intention.
Au contraire, I intended to name the fonts that are commonly used in such eReaders, or generic ones, like Arial etc. |
![]() |
![]() |
![]() |
#9 |
frumious Bandersnatch
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 7,466
Karma: 17555555
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Of course, it's not random, "arbitrary" would be a better word. Even if they are common or generic names, more likely than not they will not be available on the reader or, if they are, they cannot be accessed simply by writing their name in the CSS. In a web browser you can usually access any installed font in this way, but that's not the case in ebook readers.
|
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre 2.10, Plugins, Shortcuts and Dynamic Menus | JimmXinu | Plugins | 19 | 01-03-2015 07:10 PM |
dynamic content manipulation | maze | ePub | 1 | 02-15-2013 11:01 PM |
Dynamic keymaps | Mackx | iRex Developer's Corner | 42 | 04-25-2012 08:56 AM |
Calibre server on DSL with dynamic IP | Hamlet53 | Library Management | 13 | 06-01-2011 10:23 AM |
Dynamic text with onclick & innerHTML? | Doitsu | ePub | 3 | 01-07-2011 06:33 PM |