14 Commits

Author SHA1 Message Date
Cosimo Lupo
c2792f858b [ufo] when reverse_direction is True, we always want to modify the input glyphs
otherwise, the direction would only flipped if the glyph contains at least one cubic curve; whereas, we want to reverse the contour direction of all the glyphs in the font, even if they are just made of straight lines.
2016-10-06 15:14:44 +01:00
Cosimo Lupo
826b790147 [ufo] minor refactor 2016-09-19 13:10:57 +01:00
Cosimo Lupo
f2e962c78f [ufo] don't check glyph names in glyphs_to_quadratic 2016-08-12 16:00:20 +01:00
Cosimo Lupo
e7854e5039 [ufo] add glyph[s]_to_quadratic to convert (1+ compatible) glyphs
This was requested in https://github.com/googlei18n/cu2qu/issues/26

Plus:
- do not modify input glyphs unless they contain one cubic curve;
- make public functions return True/False to signal that the input
  was modified or not (eg. no curves, or all quadratic)
2016-08-12 15:30:51 +01:00
James Godfrey-Kittle
daaa1bd06f Report number of segments in result, not points (#41)
For some reason, I was subtracting 1 from the spline lengths in the
test report. Not sure why that is, so I've assumed it was wrong (and
now we subtract 2 to get the length in number of segments).
2016-08-01 14:08:26 -07:00
James Godfrey-Kittle
4d72a44d35 Remove unused code 2016-07-27 16:52:09 -07:00
James Godfrey-Kittle
039e35b212 No error returned from API, update tests 2016-07-27 13:21:47 -07:00
James Godfrey-Kittle
3307c5d62a Add reverse_direction argument
As described in
https://github.com/googlei18n/cu2qu/pull/20#issuecomment-213058410
2016-05-10 18:01:34 -07:00
James Godfrey-Kittle
7fe4fd0fe2 [ufo] Don't touch components or UFO2-style anchors 2016-04-05 10:41:48 -07:00
James Godfrey-Kittle
802bb813f5 [ufo] Changes for python 3 compatibility 2016-04-05 10:37:07 -07:00
James Godfrey-Kittle
983307d9cd [ufo] Allow input fonts with quadratic curves 2016-04-04 17:30:33 -07:00
James Godfrey-Kittle
0ec7495516 [ufo] Handle endPath 2016-04-04 16:08:15 -07:00
James Godfrey-Kittle
b8fa142bef [ufo] Clear existing contours when adding new ones 2016-04-04 15:30:39 -07:00
James Godfrey-Kittle
17e25e8ec9 Rename rf module to ufo 2016-04-04 15:18:27 -07:00