Fix Bug 734933: Do not remove empty path segments if stroke-linecap is round
This commit is contained in:
parent
cd42752cad
commit
6c50c78d99
3 changed files with 61 additions and 44 deletions
|
|
@ -544,6 +544,14 @@ class RemoveEmptyLineSegmentsFromPath(unittest.TestCase):
|
|||
self.assertEquals(path[4][0], 'z',
|
||||
'Did not remove an empty line segment from path' )
|
||||
|
||||
# Do not remove empty segments if round linecaps.
|
||||
class DoNotRemoveEmptySegmentsFromPathWithRoundLineCaps(unittest.TestCase):
|
||||
def runTest(self):
|
||||
doc = scour.scourXmlFile('unittests/path-with-caps.svg')
|
||||
path = svg_parser.parse(doc.getElementsByTagNameNS(SVGNS, 'path')[0].getAttribute('d'))
|
||||
self.assertEquals(len(path), 2,
|
||||
'Did not preserve empty segments when path had round linecaps' )
|
||||
|
||||
class ChangeLineToHorizontalLineSegmentInPath(unittest.TestCase):
|
||||
def runTest(self):
|
||||
doc = scour.scourXmlFile('unittests/path-line-optimize.svg')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue