![]() |
#76 | ||
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
|
Quote:
HTML: Code:
<p>To open the Index Editor select the menu item <span class="menuitem">Tools→Index→Index Editor</span> or its keyboard shortcut:</p> Code:
span.menuitem { font-family: monospace, courier, sans-serif; font-size: .9em; } IF the device then doesn't support embedded fonts, doesn't have monospace, doesn't have sans-serif, doesn't even support CSS (and doesn't apply/overrides your small font size)... THEN maybe you can shrug your shoulders and say you tried your best... and tell them to stop using Moon+ Reader. ![]() Quote:
![]() But no, no... fight the advice tooth and nail from those who made hundreds/thousands of books tested across dozens of devices from all form factors. ![]() Last edited by Tex2002ans; 09-03-2019 at 10:26 PM. |
||
![]() |
![]() |
![]() |
#77 | |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Quote:
Wouldn't it make more sense for devices to include a monospace font that looks good on their device even if only a small percentage of books need it? Nothing would be harmed by including one, and books that do use a monospace could leave it up to the device to use the best one. |
|
![]() |
![]() |
Advert | |
|
![]() |
#78 | |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Quote:
Devices and software seem to be really behind tech as so few support woff2 even though its been around for ages now so that question is answered and the thread has gone a different direction. As far as working across all readers, developing to the minimum always will result in mediocrity. Web developers don't develop for IE6 anymore. |
|
![]() |
![]() |
![]() |
#79 | |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 79,796
Karma: 146391129
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
https://www.wfonts.com/font/dark-courier Using this will look better and work better for eInk. And if it works on eInk, it will also work on LCD. |
|
![]() |
![]() |
![]() |
#80 |
Obsessively Dedicated...
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,221
Karma: 35037583
Join Date: May 2011
Location: PA {back in the usa!}
Device: Sony PRS-T2, ADE on PC
|
Is Dark Courier redistributable? Quick google didn't find licensing information, just some comments on free font sites that it is "freely distributed" (such comments being semantically meaningless).
It seems to originate from Hewlett-Packard, what do they say about it? My search skills suck. |
![]() |
![]() |
Advert | |
|
![]() |
#81 | |
Klak
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 174
Karma: 150374
Join Date: Sep 2011
Location: Belgrade, Serbia
Device: many
|
yeah, right.
and moby dick is crap literature because whale is not a fish. "from print to ebooks" is five years old book with some bad coding, but that does not mean that monospace font cannot be used in ebooks, as heading in this case. 2 different things. & to quote david carson: "don't mistake legibility for communication" Quote:
|
|
![]() |
![]() |
![]() |
#82 | |
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
Sure--someone can create an eBook that aspires to the "best" available coding--whatever that might be. For example, woo-woo, let's use SVG images in our ePUB, that we're then going to use for a MOBI for Amazon! Wow, all the advantages....but then, oh, yeah, right, NONE of those images would be visible to someone with a KF7 reader. Hell, just embedding images and then coding them in percentages for display (e.g., width:80%) won't work right for KF7 devices, so on most of those, the image would be blown up the full-width of the screen, no matter how blurry or distorted it might make that image. So, commercial coders will hand-code all the fallback coding, to make sure that each image does display correctly--no matter the device. That's developing for IE6, effectively. (Of course...if we don't, the client stands a very good chance of having the book KQNed--Kindle Quality Noticed--too, so..) As I said previously--you have one book to worry about, and you can do whatever blows your skirt up. And if you choose, through a coding decision, to not make the book usable to the readers with today's equivalent of IE6, that's your choice. I'm not saying you are doing that--I'm simply discussing your comment. That's entirely your right. Most people prefer to go for the largest-possible distribution option. I mean, after all--you said that you're deliberately trying to make your book readable by those with poor eyesight or other reading impairments, yes? Not really much difference between doing something like that, and ensuring that Suzie Q with her old Kindle Keyboard can view the file in its entirety, right? Hitch |
|
![]() |
![]() |
![]() |
#83 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Just a note - requiring font subsetting w/o using software to do so, solved problem.
For monospace fonts where I just need 7-bit ASCII Code:
pyftsubset LiberationMono-Regular.ttf \ --unicodes=U+0020-007E \ --output-file="LiberationMono-Regular-ascii.ttf" for other fonts - for western Latin languages I just created a subset that covers everything in Latin 1 (ISO-8859-1), Latin 9 (ISO-8859-15), and Windows-1252 plus two glyphs that are quite common. Text file called WesternLatin.txt containing: Code:
U+0020-007E U+00A0-00FF U+0152-0153 U+0160-0161 U+0178 U+017D-017E U+0192 U+02C6 U+02DC U+2013-2014 U+2018-201A U+201C-201E U+2020-2022 U+2026 U+2030 U+2039-203A U+20AC U+2116 U+2117 U+2122 Code:
pyftsubset FontFile.ttf \ --ignore-missing-glyphs \ --unicodes-file=WesternLatinRange.txt \ --output-file="FontFile-wlatin.ttf" Code:
U+0020-007E U+2300-23FF U+2600-26FF U+2700-27BF And obviously I could do the same if I needed, say, Greek or whatever. It may result in font files slightly larger than if I only included the glyphs actually used but they are still radically smaller than the original fonts - and it means I can edit the content w/o worrying about needing to re-subset the fonts. Just make sure to use unicode-range in the @font-face if you end up using two different subsets from the same font-family, font-style, font-weight, and font-variant. |
![]() |
![]() |
![]() |
#84 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Something I still need to research is which unicode ranges I would need for a subset that covers MathML.
I suspect though for MathML a single font would have way too many glyphs because most MathML is very specific in the glyphs in needs, so a one-size-fits-all approach that I am using for western Latin content is probably not the best approach for MathML but I'll have to look at font size for a MathML specific subset. If its ~ 100kB or smaller then it probably is an okay approach. Especially as WOFF2 gains adoption allowing even further size reduction. |
![]() |
![]() |
![]() |
#85 | |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Quote:
btw my eyes aren't the greatest, which is one of the reasons I like Clear Sans so much - at least with PDF content compiled with LaTeX, my eyes don't get tired when Clear Sans is the body font - but they do with many other fonts. It will be interesting to see if that holds true on a Kobo. |
|
![]() |
![]() |
![]() |
#86 | ||
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
|
Quote:
https://en.wikipedia.org/wiki/Mathem...ols_in_Unicode Quote:
https://en.wikipedia.org/wiki/Catego...Type_typefaces STIX is one of the high-quality free + open ones: https://www.stixfonts.org/ |
||
![]() |
![]() |
![]() |
#87 | ||
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Quote:
Quote:
|
||
![]() |
![]() |
![]() |
#88 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
|
For the technical details, you'll also want to check out:
Unicode ® Technical Report #25 "UNICODE SUPPORT FOR MATHEMATICS" (PDF) And since you're familiar with LaTeX, I assume you know about unicode-math? That's about the only way I know of that easily generates a lot of those obscure maths symbols for you. Side Note: You may also be interested in Will Robertson's (creator of unicode-math) two TUG talks: TUG 2015: Reconciling unicode-math with LaTeX2e mathematics TUG 2018: Progress of fontspec and unicode-math Quote:
A bunch of those ol' Type 1 and TeX fonts were all hackishly done. Sure, it worked in PDF and Print where you only care about the finalized LOOK... but absolutely no way those hacks would work in the web+ebooks, where things need to be kept Accessible, and users are able to copy/paste, change fonts, font sizes, display sizes, etc. It's part of the big reason why AMS + others all pushed to get Maths added to the actual Unicode standard. Last edited by Tex2002ans; 09-06-2019 at 06:37 PM. |
|
![]() |
![]() |
![]() |
#89 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 97
Karma: 200000
Join Date: Aug 2019
Device: none
|
Yeah, it looks like subsetting math is beyond what I would be able to do well - subsetting probably has to do with particular fields as far as what would be likely to be useful.
My math typesetting experience is limited to undergrad calculus level so I don't have experience in the more complex but open source math textbooks were always a dream of mine, it angered me that textbooks were so expensive when 95% of the content between two editions were identical, pretty much only the homework questions changed - thus poor students like me couldn't just use the older edition. It was economics that forced me out of college. -=- It was actually MathML that introduced me to the Document Object Model - needed Math in a web page circa 2000 and didn't want an image (this was before I discovered LaTeX) and Mozilla had basic MathML support if served as XML - but of course serving as XML broke my JS that at the time was full of document.write() I know MathML support in eBooks isn't all that universal yet, but ePub with MathML seems like a path towards open source math books and a better choice than LaTeX to PDF. Learning about the DOM was a lightbulb moment, seeing content as a collection objects made a lot of sense. |
![]() |
![]() |
![]() |
#90 | |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 79,796
Karma: 146391129
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
![]() |
![]() |
![]() |
Tags |
epub, font, woff2 |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Plugin Best Practices | sbenz | Development | 12 | 11-28-2014 10:34 PM |
Superscript best practices? | DiapDealer | ePub | 19 | 04-14-2012 04:28 PM |
Apple practices...... | carpetmojo | News | 67 | 02-16-2012 05:15 AM |
Best practices for margins | Mookiemon | ePub | 8 | 07-24-2011 07:13 PM |
DTBook - best practices | Nate the great | Workshop | 6 | 05-15-2009 04:06 AM |