Corrected pen stroke duplication issue (see below)

Presumably due to the change in how pen strokes were saved to file (commit
8ed2e24), pen strokes with pressure levels were badly saved. They were
converted to lines instead of polygons, meaning that every time a page
was saved or duplicated, the lines would look worse and worse -- and
artefacts would appear.

This should now be fixed.
preferencesAboutTextFull
Craig Watson 9 years ago
parent 024322c8d1
commit 6faeea9ddb
  1. 11
      src/adaptors/UBSvgSubsetAdaptor.cpp

@ -1145,11 +1145,15 @@ bool UBSvgSubsetAdaptor::UBSvgSubsetWriter::persistScene(int pageIndex)
}
}
if (polygonItem->isNominalLine())
polygonItemToSvgLine(polygonItem, groupHoldsInfo);
else
UBGraphicsStroke* stroke = dynamic_cast<UBGraphicsStroke* >(currentStroke);
if (stroke && stroke->hasPressure())
polygonItemToSvgPolygon(polygonItem, groupHoldsInfo);
else if (polygonItem->isNominalLine())
polygonItemToSvgLine(polygonItem, groupHoldsInfo);
continue;
}
@ -2100,7 +2104,6 @@ UBGraphicsMediaItem* UBSvgSubsetAdaptor::UBSvgSubsetReader::videoItemFromSvg()
void UBSvgSubsetAdaptor::UBSvgSubsetReader::graphicsItemFromSvg(QGraphicsItem* gItem)
{
// TODO: check position
QStringRef svgTransform = mXmlReader.attributes().value("transform");
QMatrix itemMatrix;

Loading…
Cancel
Save