Skip to content

Commit

Permalink
Merge pull request #57 from simoncozens/rename-drawing
Browse files Browse the repository at this point in the history
Rename draw_glyph_to_pen to draw_glyph_with_pen
  • Loading branch information
khaledhosny authored Aug 21, 2020
2 parents fd9c8fa + d5926d9 commit ca0b2bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/uharfbuzz/_harfbuzz.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ cdef class Font:
packed = name
return packed.decode()

def draw_glyph_to_pen(self, gid: int, pen):
def draw_glyph_with_pen(self, gid: int, pen):
funcs = DrawFuncs()
def move_to(x,y,c):
c.moveTo((x,y))
Expand Down
2 changes: 1 addition & 1 deletion tests/test_uharfbuzz.py
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ def curveTo(self, *points):
def closePath(self):
self.value.append(('closePath', ()))
pen = TestPen()
opensans.draw_glyph_to_pen(1, pen)
opensans.draw_glyph_with_pen(1, pen)
assert pen.value == [('moveTo', ((1120, 0),)), ('lineTo', ((938, 465),)), ('lineTo', ((352, 465),)), ('lineTo', ((172, 0),)), ('lineTo', ((0, 0),)), ('lineTo', ((578, 1468),)), ('lineTo', ((721, 1468),)), ('lineTo', ((1296, 0),)), ('lineTo', ((1120, 0),)), ('closePath', ()), ('moveTo', ((885, 618),)), ('lineTo', ((715, 1071),)), ('qCurveTo', ((682, 1157), (647, 1282))), ('qCurveTo', ((625, 1186), (584, 1071))), ('lineTo', ((412, 618),)), ('lineTo', ((885, 618),)), ('closePath', ())]


Expand Down

0 comments on commit ca0b2bf

Please sign in to comment.