def test_issue_243(self):
"""Issue Y: trailing space ignored in boundary calculation"""
# Issue #243: For a string with trailing spaces, freetype ignores the
# last space in boundary calculations
#
font = self._TEST_FONTS['fixed']
r1 = font.get_rect(" ", size=64)
self.assertTrue(r1.width > 1)
r2 = font.get_rect(" ", size=64)
self.assertEqual(r2.width, 2 * r1.width)
评论列表
文章目录