We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b59b310 commit d533912Copy full SHA for d533912
lib/matplotlib/path.py
@@ -337,12 +337,11 @@ def make_compound_path(cls, *args):
337
codes = np.empty(len(vertices), dtype=cls.code_type)
338
i = 0
339
for path in args:
340
- codes = path.codes
341
- if codes is None:
342
- codes = np.full(len(path.vertices), Path.LINETO,
343
- dtype=Path.code_type)
344
- codes[0] = Path.MOVETO # so concatenated strokes stay separate
345
- codes[i:i + len(path.codes)] = codes
+ if path.codes is None:
+ codes[i] = cls.MOVETO
+ codes[i + 1:i + len(codes)] = cls.LINETO
+ else:
+ codes[i:i + len(path.codes)] = path.codes
346
i += len(path.vertices)
347
# remove STOP's, since internal STOPs are a bug
348
not_stop_mask = codes != cls.STOP
0 commit comments