Behdad Esfahbod
bd67253118
Some more whitespace fixes from pep8 tool
2015-04-26 01:59:01 -04:00
Behdad Esfahbod
d897eb0486
Micro optimization
2014-06-16 20:35:12 -04:00
Behdad Esfahbod
d06ecc6b25
Use basestring instead of str
2014-06-16 20:30:17 -04:00
Behdad Esfahbod
5598d1de5a
[cff] Speed up operand handling
...
I get ~7% speedup just avoiding a redirection.
2014-06-16 20:23:12 -04:00
Behdad Esfahbod
8d44d79ee2
Minor simplification
2014-06-16 20:23:12 -04:00
Behdad Esfahbod
1ae29591ef
from __future__ import absolute_import
...
Such that our Python 2 is closer to Python 3.
Part of https://github.com/behdad/fonttools/issues/77
2014-01-14 15:07:50 +08:00
Behdad Esfahbod
78c02b6af3
Fix T1CharString decompile()
...
self.program is never None; it's set to [] if using bytecode.
So fixup the check.
2013-12-04 13:16:49 -05:00
Behdad Esfahbod
153ec40209
Fix a few pychecker warnings
...
Fixes https://github.com/behdad/fonttools/issues/58
2013-12-04 01:15:46 -05:00
Behdad Esfahbod
f918ab4cf6
Fix typos
...
From
4d2d8c9642
2013-11-29 17:12:43 -05:00
Behdad Esfahbod
e388db566b
py23 Use new-style classes
...
Such that we get the same semantics in both Python 2 and 3.
2013-11-28 18:53:30 -05:00
Behdad Esfahbod
278c88c0af
py23 Fix psCharStrings bytes issues
2013-11-28 17:32:44 -05:00
Behdad Esfahbod
18316aa769
ps23 More bytes fixes. All ''join()'s fixed
2013-11-28 17:32:43 -05:00
Behdad Esfahbod
319c5fd10e
py23 introduce byteord() and use it
2013-11-28 17:32:42 -05:00
Behdad Esfahbod
32c10eecff
py23 from __future__ import division and adjust divisions
2013-11-28 17:32:42 -05:00
Behdad Esfahbod
30e691edd0
py23 from __future__ import print_function
2013-11-27 17:27:45 -05:00
Behdad Esfahbod
b7a2d797a4
py23 Use bytechr() instead of chr()
2013-11-27 15:25:00 -05:00
Behdad Esfahbod
7ed91eca1e
py23 import in all nontrivial source files and unused import cleanup
2013-11-27 15:25:00 -05:00
Behdad Esfahbod
14fb031125
Remove most uses of module string
2013-11-27 14:01:44 -05:00
Behdad Esfahbod
b774f9f684
2to3 --fix=types manual additions
...
Don't know why the tool didn't catch these.
2013-11-27 14:01:44 -05:00
Behdad Esfahbod
3ec6a25823
2to3 --fix=print with manual fixup
2013-11-27 04:57:33 -05:00
Behdad Esfahbod
002c32fd0d
2to3 --fix=types with manual fixups
2013-11-27 04:48:20 -05:00
Behdad Esfahbod
e5ca79699d
2to3 --fix=map with manual cleanup
2013-11-27 04:38:16 -05:00
Behdad Esfahbod
ac1b435946
2to3 --fix=idioms
2013-11-27 04:15:34 -05:00
Behdad Esfahbod
3a9fd30180
2to3 equivalent to --fix=tuple_params
...
I hope I got this all right...
2013-11-27 03:30:21 -05:00
Behdad Esfahbod
cd5aad92f2
2to3 --fix=raise
2013-11-27 02:42:28 -05:00
Behdad Esfahbod
846d09e380
Allow None for globalSubrs in T2CharString
2013-11-18 14:11:30 -05:00
Behdad Esfahbod
f09f1d4064
Raise exceptions on unimplemented T2CharString operators
2013-08-19 14:16:07 -04:00
jvr
e56bc902cf
- t1Lib.py can now properly read PFA fonts
...
- fixed "flex" bug in T1 charstring reader
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@549 4cde692c-a291-49d1-8350-778aa11640f8
2008-03-10 21:58:00 +00:00
jvr
7099f4c0f9
support the deprecated dotsection T2 operator
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@505 4cde692c-a291-49d1-8350-778aa11640f8
2006-02-25 21:39:33 +00:00
jvr
d4561ec1b4
some flex hint fixes from rroberts
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@499 4cde692c-a291-49d1-8350-778aa11640f8
2005-05-07 08:41:12 +00:00
jvr
95c9e9fc11
This patch fixes two things
...
- in T2 charstrings, a byte code of 255 is followed by a 16.16 fixed
point number, not a 4-byte int as in T1. Noted by rroberts.
- some integers were not correctly encoded in the T1 compiler.
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@485 4cde692c-a291-49d1-8350-778aa11640f8
2005-02-23 21:22:27 +00:00
jvr
8b8b44904e
- Implemented the flex operators for T2
...
- Changed a whole bunch of XXX traps into NotImplementedErrors
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@456 4cde692c-a291-49d1-8350-778aa11640f8
2003-09-17 17:32:11 +00:00
jvr
d3ee2d4319
- Properly support the pen protocol for open sub paths in Type 1
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@452 4cde692c-a291-49d1-8350-778aa11640f8
2003-09-16 09:48:28 +00:00
jvr
6628513fe4
T2: I'm not sure if the seac-variant of the endchar operator may be
...
combined with actual outlines, but if it is, we need to do the closePath
before the components are added.
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@440 4cde692c-a291-49d1-8350-778aa11640f8
2003-08-29 08:05:39 +00:00
jvr
382df6c42a
added deprecated endchar/seac support for T2 charstrings
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@439 4cde692c-a291-49d1-8350-778aa11640f8
2003-08-28 20:43:06 +00:00
jvr
489d76a340
Refactored outline extraction for CharStrings. The interface to
...
T{1,2}OutlineExtractor is not backwards compatible and this change
basically makes them private classes: CharStrings now have a .draw()
method that takes a Pen object (see fontTools.pens.*), so you never
have to deal with the extractor objects yourself. Only lightly tested.
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@417 4cde692c-a291-49d1-8350-778aa11640f8
2003-08-24 19:56:16 +00:00
jvr
9920ad5286
added and tweaked some asserts
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@414 4cde692c-a291-49d1-8350-778aa11640f8
2003-08-24 16:25:12 +00:00
jvr
b58176e5ac
added support for raw bytecode: this happens unintentionally for subrs that aren't referenced, but it's good to have anyway, in case we want to switch T2 decompilation off.
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@257 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-24 11:55:37 +00:00
jvr
4e5af60930
CFF/T2 <-> XML roundtripping has begun!
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@254 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-24 09:58:04 +00:00
jvr
f2cf9c5d6d
first working version of CFF/T2 compiler; needs cleanup/refactoring, and doesn't import from XML yet; hardly tested.
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@253 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-23 21:50:36 +00:00
jvr
586345b7c1
fixed ctnrmask problem: hints weren't counted correctly
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@247 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-17 18:37:07 +00:00
jvr
455af6592b
first stab at compiling T2 CharStrings
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@244 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-17 07:07:26 +00:00
jvr
6f03a58f59
(nit)
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@239 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-16 18:13:01 +00:00
jvr
dc18128aa9
added delta array support to DictDecompiler
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@235 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-15 07:40:33 +00:00
jvr
bf2f402913
fix argument type order
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@233 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-14 13:49:50 +00:00
jvr
dbc2c173b3
moved some stuff to cffLib
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@225 4cde692c-a291-49d1-8350-778aa11640f8
2002-05-13 16:19:51 +00:00
jvr
aa00a279ae
behave nicely when *any* subpath doesn't start with a moveto.
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@171 4cde692c-a291-49d1-8350-778aa11640f8
2001-08-16 11:02:05 +00:00
jvr
239498a496
behave nicely when the font doesn't do an initial moveto.
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@170 4cde692c-a291-49d1-8350-778aa11640f8
2001-08-16 10:35:28 +00:00
Just
b68a700595
don't print extra error info to stdout
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@136 4cde692c-a291-49d1-8350-778aa11640f8
2001-06-24 15:14:06 +00:00
Just
dab433233b
fixed broken import
...
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@71 4cde692c-a291-49d1-8350-778aa11640f8
2000-01-31 14:33:17 +00:00