4 ms·
BTW, this feature is a complete fail -- say I write 3431/5147, and what do I get? 343(1/5)147, so not only still ugly, but also incorrect mathematically.
by mbq 15y ago
BTW, this feature is a complete fail -- say I write 3431/5147, and what do I get? 343(1/5)147, so not only still ugly, but also incorrect mathematically.
- nitrogen 15y agoYeah, it can only support those fractions that are included in the specification and the font itself, like 1/2, 3/4, 5/8. It's a typographic special case.
- mbq 15y agoI know -- the problem is the syntax. You can't safely apply this to any document, because it may change the meaning of it. Such things should only exist as unicode characters or character entities.
- sukuriant 15y agoI'm not sure your argument is valid. How is the decision made to convert x/y to fraction form? Is it white-space/punctuation+whitespace on either side? If that's the case, then: xxx/yyy will never become fraction form; however, x/y and x/y. (as in the end of a sentence) will.
- yeswecan 15y agoThe only way to guarantee it is to have an HTML tag to identify the fraction - <frac>11/63</frac> or similar.
- mbq 15y agoBut this does not work this way -- it seems it just blindly consumes char before and after / and converts if this fraction has a glyph in the font. Also, what you suggest is hard to implement since there are numerous localisation-dependent options what a whitespace/punctuation is and where to search it.
- DieBuche 15y agoNo, it's not. It works like it's suppossed to do for any (not actual regex) /d+ \/ /d+ . See screenshot here: http://imgur.com/gwlHJ http://imgur.com/gwlHJ Fonts supporting the frac feature have a separate set of smaller numbers, and these get dynamically composed into fractions once you type them.
- webfuel 15y agoMaybe things will change with how the browser implements fractions but 112/3 = 11(2/3) and 3431/5147 = 3431/5147 (there is no 1/5) http://imgur.com/a/4FFNy http://imgur.com/a/4FFNy Edit: Spelling.
- mbq 15y agoGot me; I tested 3431/4147 and then made an error when posting a comment; this is my original screenshot: http://imgur.com/MajJD http://imgur.com/MajJD
- DieBuche 15y agoThat's actually an issue with that specific font. Try editing the first Verdana Example (3/4 Ale..), that works for me for 1234/5678.