02-08-2013, 05:06 PM | #16 | |
ɴₐɴ
Posts: 421
Karma: 2507940
Join Date: Jun 2011
Location: 37.2N 93.3W
Device: KV PW4 PW3 PW2
|
Quote:
https://www.mobileread.com/forums/sho...24#post2358224 ^ That actually hides the fonts. Not sure if removing them is advisable. |
|
02-08-2013, 05:09 PM | #17 |
Enthusiast
Posts: 37
Karma: 260446
Join Date: Feb 2013
Device: Kindle Paperwhite
|
Much obliged. Now if could only get those monospace fonts for my programming books...
|
02-09-2013, 11:14 PM | #18 | |
Wizard
Posts: 4,742
Karma: 246906703
Join Date: Dec 2011
Location: USA
Device: Oasis 3, Oasis 2, PW3, PW1, KT
|
Quote:
All you need to do is put the monospaced sections into <code> .. </code> blocks in your html inside the book. That can be inside epub, kf8, or plain html. Convert that epub/html into mobi or azw3, or tweak a azw3 in calibre. If you need more fancy things / different fonts, you need to use css stylesheets and call for a specific font by name that you already installed or embed into the book. This html: Code:
<html><head><title>Test</title></head><body> <h1 align=center>Testing <code></h1> <p align=justify>Normal font: <code>monospaced</code>. Normal again.</p> <p align=left><code> 0123456789 ABCDEFGHIJ this is all monospaced<br>new line.</code></p> </body></html> |
|
02-10-2013, 08:26 AM | #19 | |
curly᷂͓̫̙᷊̥̮̾ͯͤͭͬͦͨ ʎʌɹnɔ
Posts: 3,002
Karma: 50506927
Join Date: Dec 2010
Location: ♁ ᴺ₄₅°₃₀' ᵂ₇₃°₃₇' ±₆₀"
Device: K3₃.₄.₃ PW3&4₅.₁₃.₃
|
Quote:
This also works nicely on a Kindle Keyboard. With the Droid_Sans Mono font installed in the font hack it gives: |
|
02-10-2013, 10:34 AM | #20 | |
Wizard
Posts: 4,742
Karma: 246906703
Join Date: Dec 2011
Location: USA
Device: Oasis 3, Oasis 2, PW3, PW1, KT
|
Quote:
And just extracted all the fonts from PW to take a look, and it uses: KindleBlackboxRegular.ttf Have to keep looking on how to change the default mono font. But then the one on the PW does look quite nice, and comes in regular, bold, italic and bold-italic. |
|
02-10-2013, 12:46 PM | #21 | |
curly᷂͓̫̙᷊̥̮̾ͯͤͭͬͦͨ ʎʌɹnɔ
Posts: 3,002
Karma: 50506927
Join Date: Dec 2010
Location: ♁ ᴺ₄₅°₃₀' ᵂ₇₃°₃₇' ±₆₀"
Device: K3₃.₄.₃ PW3&4₅.₁₃.₃
|
Quote:
Last edited by PoP; 02-10-2013 at 03:24 PM. |
|
02-10-2013, 04:15 PM | #22 |
Enthusiast
Posts: 37
Karma: 260446
Join Date: Feb 2013
Device: Kindle Paperwhite
|
Oh guys, I think you misunderstood me. I have monospaced font wherever I need it. The question was whether I'm able to change the default monospace font with he USE_ALT_FONTS hack.
|
02-10-2013, 07:42 PM | #23 |
Wizard
Posts: 4,742
Karma: 246906703
Join Date: Dec 2011
Location: USA
Device: Oasis 3, Oasis 2, PW3, PW1, KT
|
Aehm, no. I tried a few things to no avail. That leaves only to install your monospaced font via USE_ALT_FONTS and calling it directly by name, rather than font-family. But that would require of editing your books, possibly only the stylesheets in them.
|
02-21-2013, 04:26 PM | #24 | |
ɴₐɴ
Posts: 421
Karma: 2507940
Join Date: Jun 2011
Location: 37.2N 93.3W
Device: KV PW4 PW3 PW2
|
Quote:
Code:
<match target="pattern"> <test qual="any" name="family"><string>KindleBlackboxC</string></test> <edit name="family" mode="assign"><string>DejaVu Sans Mono</string></edit> </match> Last edited by JimmyR; 02-21-2013 at 04:31 PM. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
the question of downgrading from 3.4 to 3.3 | bruce1203 | Kindle Developer's Corner | 8 | 10-28-2012 11:03 PM |
Touch Downgrading to 1.9.4 | actiss | Kobo Reader | 4 | 07-09-2011 01:51 PM |
JB5: downgrading FW->possible ? | smallhagrid | Ectaco jetBook | 5 | 08-19-2010 03:10 PM |
Classic Downgrading nook? | jjjason1 | Barnes & Noble NOOK | 5 | 02-06-2010 10:00 PM |
Downgrading K2 firmware | hmemcpy | Amazon Kindle | 7 | 05-17-2009 09:36 PM |