Commit Graph

23 Commits

Author SHA1 Message Date
Nigel Tao bf25f8ce0e Move files up one level. 2015-08-12 14:30:01 +10:00
Nigel Tao e009753234 freetype/truetype: support symbol fonts such as Webdings.
LGTM=bsiegert
R=bsiegert
CC=golang-codereviews
https://codereview.appspot.com/60380043
2014-02-06 10:38:58 +11:00
Nigel Tao 10cb3b4280 freetype/truetype: calculate advance widths correctly.
The logic is a little clunky, but as before, let's get it right first,
then get it clean once we have a full battery of tests.

R=bsiegert
CC=golang-codereviews
https://codereview.appspot.com/50910043
2014-01-14 09:58:07 +11:00
Nigel Tao 114d43ecfe freetype/truetype: load vertical metrics from the OS/2 table.
R=bsiegert
CC=golang-dev, remyoudompheng
https://codereview.appspot.com/34700043
2013-11-29 10:33:11 +11:00
Nigel Tao cdaff3c716 freetype/truetype: run compound glyph hinting instructions.
Also add API for vertical metrics.

R=bsiegert
CC=golang-dev, remyoudompheng
https://codereview.appspot.com/21330043
2013-11-05 09:58:40 +11:00
Nigel Tao 9e24a6204e freetype/truetype: implement Font.Index binary search.
R=bsiegert
CC=golang-dev
https://codereview.appspot.com/14604044
2013-10-12 09:29:59 +11:00
Nigel Tao 0a778f7f02 freetype/truetype: parse UCS-4 encoded cmap tables.
R=bsiegert
CC=golang-dev
https://codereview.appspot.com/14548046
2013-10-11 07:29:40 +11:00
Nigel Tao ba07cbfbc8 freetype/truetype: set the four phantom points, and adjust the glyph
points accordingly.

Yes, it's a mess, but let's pass the tests first, and then refactor.

R=bsiegert
CC=golang-dev
https://codereview.appspot.com/14419052
2013-10-10 07:43:32 +11:00
Nigel Tao e3b4bc4c1f freetype/truetype: function call opcodes.
R=bsiegert
CC=golang-dev
https://codereview.appspot.com/11983043
2013-07-30 19:20:31 +10:00
Nigel Tao 28cc5fbc5d freetype: move the scaling from FUnits to pixels from package freetype
to package truetype.

R=bsiegert
CC=golang-dev
http://codereview.appspot.com/6427062
2012-07-25 22:10:25 +10:00
Nigel Tao 20ce6ab4df freetype/truetype: variable sized bytecode interpreter stack/store.
R=bsiegert
CC=golang-dev
http://codereview.appspot.com/6343091
2012-07-11 21:49:03 +10:00
Nigel Tao 8ed9e9345e freetype/truetype: first cut of a bytecode interpreter.
R=gri, bsiegert
CC=golang-dev
http://codereview.appspot.com/6347057
2012-07-03 20:46:16 +10:00
Nigel Tao 6baa5f0a46 freetype: optimize []byte to uint16/uint32 conversions.
Thanks to Jeff R. Allen <jra@nella.org> for the conversation that
led to this change.

benchmark              old ns/op    new ns/op    delta
BenchmarkDrawString     21168440     20143860   -4.84%

The number of mallocs per iteration is unchanged.

R=rsc, r
CC=golang-dev, jra
http://codereview.appspot.com/6304077
2012-06-16 12:19:07 +10:00
Nigel Tao a16d1037a1 freetype: re-organize the freetype/truetype package into smaller files.
No code changes, just a copy/paste.

R=bradfitz
CC=golang-dev
http://codereview.appspot.com/6201052
2012-05-07 12:04:52 +10:00
Nigel Tao eaa4846c62 freetype: support TrueType Collection files (.TTC files, as opposed to
.TTF files)

R=bradfitz
CC=golang-dev
http://codereview.appspot.com/6194050
2012-05-07 11:42:35 +10:00
Nigel Tao 9a8fb30c20 freetype: remove arbitrary 1<<24 limit on ttf file size.
I'm not sure why I put that limit in in the first place. I can't find
that limit in either the C Freetype code or the TTF spec.

R=bradfitz
CC=golang-dev
http://codereview.appspot.com/6201043
2012-05-07 09:37:34 +10:00
Nigel Tao d32ba0b88b freetype: fix overflow when converting from a uint16 glyph index to a
file offset.

R=bradfitz
CC=golang-dev
http://codereview.appspot.com/6198043
2012-05-04 15:42:29 +10:00
Nigel Tao 97fe2fb9c1 freetype: import path gofixes.
Also update freetype/truetype for s/int/rune/.

R=rsc, bradfitz
CC=golang-dev
http://codereview.appspot.com/5505067
2011-12-23 10:55:36 +11:00
Nigel Tao 97ddbbf4d0 freetype: gofix errors.
R=rsc, r
CC=golang-dev
http://codereview.appspot.com/5339048
2011-11-08 10:38:49 +11:00
Nigel Tao 2af394dab9 freetype: clarify that the GPL licence is "version 2 or later", not
just version 2. The FTL (Freetype Licence) is still available. This
matches the original Freetype library (written in C).

This only expands and does not further restrict the licensing options
available to users of the freetype-go library.

R=adg
CC=golang-dev
http://codereview.appspot.com/1731049
2010-08-03 11:07:23 +10:00
Nigel Tao 7707aeaf6a Freetype-Go: support compound glyphs.
R=r
CC=golang-dev
http://codereview.appspot.com/1196045
2010-05-20 05:30:00 -07:00
Nigel Tao 25c38cfec1 Freetype-Go: new freetype package to provide a convenience API to
draw text onto an image.

This is a simple API that doesn't handle line breaking, ligatures,
right-to-left or vertical scripts, and other fancy features.

R=r, rsc
CC=golang-dev
http://codereview.appspot.com/1121045
2010-05-14 13:29:53 +10:00
Nigel Tao f6caa104ec Freetype-Go: truetype parser initial check-in.
Parsing a malformed TTF may result in an index out-of-bounds panic,
rather than guaranteeing to return an error. This may be tightened
in the future.

R=r, rsc
CC=golang-dev
http://codereview.appspot.com/940044
2010-05-04 09:54:43 +10:00