Kaydet (Commit) 15a19d71 authored tarafından Radek Doulik's avatar Radek Doulik

pptx: custom shapes import, ignore close segment after moveto segment

üst e596df57
...@@ -1034,11 +1034,14 @@ Reference< XFastContextHandler > Path2DContext::createFastChildContext( sal_Int3 ...@@ -1034,11 +1034,14 @@ Reference< XFastContextHandler > Path2DContext::createFastChildContext( sal_Int3
{ {
case A_TOKEN( close ) : case A_TOKEN( close ) :
{ {
// ignore close after move to (ppt does seems to do the same, see accentCallout2 preset for example)
if ( mrSegments.empty() || ( mrSegments.back().Command != EnhancedCustomShapeSegmentCommand::MOVETO ) ) {
EnhancedCustomShapeSegment aNewSegment; EnhancedCustomShapeSegment aNewSegment;
aNewSegment.Command = EnhancedCustomShapeSegmentCommand::CLOSESUBPATH; aNewSegment.Command = EnhancedCustomShapeSegmentCommand::CLOSESUBPATH;
aNewSegment.Count = 0; aNewSegment.Count = 0;
mrSegments.push_back( aNewSegment ); mrSegments.push_back( aNewSegment );
} }
}
break; break;
case A_TOKEN( moveTo ) : case A_TOKEN( moveTo ) :
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment