ynakajima / ttf.js Goto Github PK
View Code? Open in Web Editor NEWJavaScript font library for Node.js and browser.
JavaScript font library for Node.js and browser.
headerと仮に呼んでいたテーブルの正式名称が Offset Table だとわかったので修正する
「%」の曲線部分の一部が突出する。
Quivira.ttf -> GID: 0
[ { x: 555, y: 205, on: 0 },
{ x: 510, y: 184, on: 0 },
{ x: 474, y: 137, on: 0 },
{ x: 467, y: 110, on: 1 },
{ x: 463, y: 96, on: 0 },
{ x: 463, y: 83, on: 1 },
{ x: 463, y: 71, on: 0 },
{ x: 467, y: 60, on: 1 },
{ x: 473, y: 36, on: 0 },
{ x: 508, y: 15, on: 0 },
{ x: 529, y: 15, on: 1 },
{ x: 549, y: 15, on: 0 },
{ x: 594, y: 36, on: 0 },
{ x: 630, y: 83, on: 0 },
{ x: 637, y: 110, on: 1 },
{ x: 641, y: 124, on: 0 },
{ x: 641, y: 137, on: 1 },
{ x: 641, y: 149, on: 0 },
{ x: 638, y: 161, on: 1 },
{ x: 631, y: 184, on: 0 },
{ x: 597, y: 205, on: 0 },
{ x: 576, y: 205, on: 1 } ]
i want to know the char which the ttf has,can i do it by your lib?
/src/ttf.js:239
throw 'Not support cmap format'+format+' yet! Please submit an iss
^
At first, thank you for sharing this and it help me to finish the project. On the one hand, it works on almost TTF files. On the other hand, it couldn't parse OTF files. However, OTF files are more popular than other Font files in these days. Hence, I probably do otf.js which might fork from ttf.js which you've done.
But... I don't know how to start because I have no idea at the first step. Could you please tip me how to start if you available? I will extremely appreciate that. :)
An edge case error really, but the ability to open webfonts could be quite handy.
Error: RangeError: argument 1 accesses an index that is out of range
Source File: http://ynakajima.github.com/ttf.js/vendor/jdataview.js
Line: 126
Example files (edited Ostrich Regular fonts):
http://duckduckgo.gr/ttfjs_test_fonts/Ostrich_Regular.ttf [original open source font]
http://duckduckgo.gr/ttfjs_test_fonts/Ostrich_blank_properties.ttf
http://duckduckgo.gr/ttfjs_test_fonts/Ostrich_invalid_properties.ttf
http://duckduckgo.gr/ttfjs_test_fonts/ostrich_protected_squirrel.ttf [webfont made with fontsquirrel generator]
TTFEdit [http://ttfedit.sourceforge.net/] will open the same files properly. No ttf parser that I know of can open such malformed files.
ostrich_protected_squirrel.ttf:
Maybe if there was an option to pre-populate or use custom values for any properties of the font would fix this issue?
Full circle glyphs are displayed incorrectly (vector path is broken) for some reason.
You may test with the following:
http://goo.gl/g7YOo
http://goo.gl/SMOhE
http://goo.gl/XCxgJ
http://goo.gl/1xXv7
http://goo.gl/zbZjq
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.