90beb95b77- rename file to fileOrPath - check for capability, not type, so XMLWriter can hanlde unicode filenames (on OS-es that support them).
jvr
2005-01-17 21:34:06 +00:00
f34c6f3937fix for new 2.4 hex() behavior
jvr
2004-12-24 16:07:01 +00:00
e0912bb819fix for new 2.4 hex() behavior
jvr
2004-12-24 15:59:35 +00:00
0cc0b31fdeUpdates from Adam Twardoch. Thanks!
jvr
2004-12-14 07:55:55 +00:00
28ae196229Refactored and enhanced table order support: - Rewrote sorting function, it was really quite buggy. - Added reorderFontTables() functions, which reorders the tables in a font at the sfnt level. - TTFont.save() will now by default rewrite the font in the optimized order. This is done through a temp file since our dependency checking logic gets in the way of writing the tables in a predefined order directly (if table A depends on B, table B will always be compiled and written first, so this prevents A from showing up in the file before B).
jvr
2004-11-16 10:37:59 +00:00
427f9802bcmake sure that a cmap subtable instance always has a language attr, so __cmp__ can't fail
jvr
2004-09-26 18:32:50 +00:00
fba0609d54Fix for [ 808370 ] Dumping Legendum.otf fails on 'kern' table Work around buggy kern table.
jvr
2004-09-25 10:56:15 +00:00
1fae9b48d3[ 637398 ] Failure while parsing OpenType file Deal with empty Coverage table: it will be None so won't have a .glyphs attribute.
jvr
2004-09-25 10:31:29 +00:00
266bf21dbeworkaround for bug [ 766694 ] Error from invalid date
jvr
2004-09-25 10:01:12 +00:00
980fae897abug #784690: simple workaround for buggy name table
jvr
2004-09-25 09:12:00 +00:00
a84b28d934- Refactored XML writing, removed lots of code duplicaiton - Only output unicode names as comments if we're in fact dealing with a unicode cmap subtable (and this is -- in theory -- independent of cmap format)
jvr
2004-09-25 09:06:58 +00:00
175f048123whoops, rolling back accidental #! commits
jvr
2004-09-25 08:24:37 +00:00
39c1918939"Downgraded" AGL list to the "Adobe Glyph List For New Fonts", which is most appropriate here. There may be a use for the "big" AGL, but that will have to become a new module.
jvr
2004-09-25 08:12:50 +00:00
13325c613a[ 845172 ] Updating to Unicode 4.0.0 Instead of using a list internally, I now use a dict, since the unicode mapping is quite sparse (lots of unused slots).
jvr
2004-09-25 07:47:41 +00:00
6588c4e2dfPatch #845551 from Anthony Fok: - two minor typos - changed copyright year in LICENSE (and it's 2004 now...)
jvr
2004-09-25 07:35:05 +00:00
0cd79a5642Patch #845571 from Anthony Fok: - better exception msg in loca table - renamed "version" to "language" in cmap - made cmap 12 work (untested by me)
jvr
2004-09-25 07:30:47 +00:00
7718d95951whoops, forgot one part os OS/2 version 3 support
jvr
2004-09-25 07:19:27 +00:00
30bcb12dcbadded support for OS/2 table #3
jvr
2004-09-24 18:33:19 +00:00
05e2541b49Fixed subtle bug in curve intersection logic: due to floating point errors, sometimes a legitimate solution is ever so slightly over 1.0. Those used to be filtered out; now checking for 1.0 + 1e-10.
jvr
2003-10-14 20:30:07 +00:00
8e1d75b1a3ReverseChainSingleSubst support from Yannis H. (must get that generate-otdata-from-the-docs working again)
jvr
2003-09-22 13:12:55 +00:00
df1f145e5abug from the spec leaked into here; pointed out by Yannis H.
jvr
2003-09-22 07:09:33 +00:00
7325cb480echecked in with unix line endings -- this probably needs proper review
jvr
2003-09-18 07:33:01 +00:00
8b8b44904e- Implemented the flex operators for T2 - Changed a whole bunch of XXX traps into NotImplementedErrors
jvr
2003-09-17 17:32:11 +00:00
f184f75486Added lots of doco and doctests.
jvr
2003-09-16 11:01:40 +00:00
0b0fec3b08debogofied doc string, added another one
jvr
2003-09-16 10:14:48 +00:00
d3ee2d4319- Properly support the pen protocol for open sub paths in Type 1
jvr
2003-09-16 09:48:28 +00:00
cc580ac0f8Added Pen for reportlab.graphics.
jvr
2003-09-15 12:26:10 +00:00
27f108844ethis should have been part of the previous path by some fixes from klchxbec
jvr
2003-09-11 07:11:35 +00:00
fbff58cd78Correctly deal with the TT-no-on-curve special case.
jvr
2003-09-09 23:29:45 +00:00
23cb200532Factored out the SuperBezier and TT-implied-point algorithms, as the may be useful separately from pens.
jvr
2003-09-07 09:41:28 +00:00
40cde70f16- added endPath() method to the Pen protocol, as a counterpart for closePath() for *open* sub paths. This allows pen implementations to reliably detect the end of a sub path. - improved various doc strings.
jvr
2003-09-06 16:00:03 +00:00
49b5521f2eensure that the current point is always set correctly
jvr
2003-09-05 14:18:26 +00:00
fc3879e463- renamed all l,t,r,b tuff to xMin, yMin, xMax, yMax - added ome more doc strings - added some minimal test code
jvr
2003-08-29 19:29:46 +00:00
6628513fe4T2: 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.
jvr
2003-08-29 08:05:39 +00:00
382df6c42aadded deprecated endchar/seac support for T2 charstrings
jvr
2003-08-28 20:43:06 +00:00
934fe5fb8f- added support for quadratic contours that have NO on-curve points. - more doco and comments.
jvr
2003-08-28 19:30:46 +00:00
53d7523c1cmore doco and comments
jvr
2003-08-28 19:03:29 +00:00
1cff4cb190workaround for buggy 2.2 mac support
jvr
2003-08-28 18:23:43 +00:00
bafa66e665Another patch from rroberts. He writes: """It adds full support for cmap format 2, which is what the Adobe CJK fonts use for the Mac cmap subtable."""
jvr
2003-08-28 18:04:23 +00:00
ceb3449e2bwhoops, forgot to add the .pens subpacke to the distutils script :-( noticed by rroberts.
jvr
2003-08-28 17:59:52 +00:00
4162de350eIs the point inside or outside the outline?
jvr
2003-08-28 08:51:45 +00:00
bfadfe33db- Fixed ZeroDivisionError in solveCubic(). The solution is mathematically dubious (I don't think 0.0/0.0 == 0.0...) but the result seems to be correct. - Documented that soleCubic() and solveQuadratic() are not guaranteed to return the roots in order, and nor that they are guaranteed to not return duplicate roots.
jvr
2003-08-26 19:20:33 +00:00
d028b7be3cSet .width in _TTGlyph.__init__ after all: these are just this wrapper objects, _TTGlyphSet doesn't cache them, so setting .width in .draw() is confusing to say the least.
jvr
2003-08-26 19:00:38 +00:00
808c7885bdlots of stuff
jvr
2003-08-25 13:18:23 +00:00
8df8f6385eTTFont now has a getGlyphSet() method, which will return a generic GlyphSet. A GlyphSet is simply a dict-like object mapping glyph names to glyphs. The glyphs in a GlyphSet have a .draw(pen) method and a .width attribute. This provides a generic interface for drawing glyphs or extracting outlines, and works both for CFF-based fonts and TT fonts.
jvr
2003-08-25 13:15:50 +00:00
731ed49dbcadd some more dict-like stuff to the glyf table
jvr
2003-08-25 12:23:01 +00:00
489d76a340Refactored 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.
jvr
2003-08-24 19:56:16 +00:00
3d24a106badon't use macfs, it's deprecated
jvr
2003-08-24 19:52:03 +00:00
b47e3ba3aesome fixes from klchxbec
jvr
2003-08-22 20:21:08 +00:00
aa2723c559VORG support by rroberts.
jvr
2003-08-22 20:02:25 +00:00
ed10151701Lots of CID work by rroberts.
jvr
2003-08-22 19:53:32 +00:00
700df03131- attempted to sort tables in order recommended by spec. TODO: need to fix table dependency order to complete this. (Read: would you mind posting a bug report regarding this?)
jvr
2003-08-22 19:44:08 +00:00
f509c0f070support for CEF fonts: don't depend on the head table being available
jvr
2003-08-22 19:38:37 +00:00
07dd0e4504recalc numGlyphs upon writing
jvr
2003-08-22 19:34:48 +00:00
d407973545update macUtils to current day MacPython
jvr
2003-08-22 18:56:01 +00:00
5149e18031attempt to set the value for fRectWidth 'more correctly'
jvr
2003-08-22 18:53:29 +00:00
9e58c90401this module has been included in so many (in house) packages that it's time it gets a more central place.
jvr
2003-08-22 14:56:48 +00:00
efaae5245c- optimized a couple of invariant expressions - made sure solveCubic() also works when called with integer arguments
jvr
2003-06-29 19:25:05 +00:00
9524c7bdd3splitLine(): make sure the split is between the end points
jvr
2003-06-29 18:32:00 +00:00
182a7ba7betwo new functions
jvr
2003-06-29 18:18:54 +00:00
b19141e489avoid FSSpec on MacOS
jvr
2003-06-07 15:15:51 +00:00
5910f97146add default _attrs value so pickling AFM objects doesn't blow up
jvr
2003-05-24 12:50:47 +00:00
59afba7684updated for MacPython2.3
jvr
2003-05-24 12:34:11 +00:00
e73b8a53a5Fix for bug #691744; calc_mac_epoch_diff() was broken when the timezone was GMT (or perhaps other situations; it's not entirely clear).
jvr
2003-02-23 19:40:07 +00:00
924e4e274ecmap format 12 support, donated by rroberts: thanks!
jvr
2003-02-08 10:45:23 +00:00
a87cde236esecond try to work around bogus stringOffset value
jvr
2003-01-25 18:20:22 +00:00
b71d0f46f6renamed stringoffset to stringOffset as per spec
jvr
2003-01-25 11:15:42 +00:00
aabca6d793gracefully handle bogus stringOffset values (thanks to Anthony Fok)
jvr
2003-01-25 11:14:59 +00:00
1332d3e549clean up checkSumAdjustment XML output: suppress trialing 'L'
jvr
2003-01-10 22:34:13 +00:00
26fc63c854fix from Owen Taylor that fixes my previous patch; thanks!
jvr
2003-01-10 22:23:46 +00:00
130c1a0d9cmake two fields unsigned, to conform to the spec but also to suppress Python 2.3 warnings for hex(negativenumber).
jvr
2003-01-03 21:23:04 +00:00