mirror of
https://github.com/UglyToad/PdfPig.git
synced 2025-10-14 02:44:58 +08:00
Check if current path is null for path construction operators
This commit is contained in:
@@ -56,6 +56,8 @@
|
||||
/// <inheritdoc />
|
||||
public void Run(IOperationContext operationContext)
|
||||
{
|
||||
if (operationContext.CurrentSubpath == null) return;
|
||||
|
||||
var controlPoint1 = operationContext.CurrentTransformationMatrix.Transform(new PdfPoint(X1, Y1));
|
||||
var end = operationContext.CurrentTransformationMatrix.Transform(new PdfPoint(X3, Y3));
|
||||
operationContext.CurrentSubpath.BezierCurveTo(controlPoint1.X, controlPoint1.Y, end.X, end.Y, end.X, end.Y);
|
||||
|
Reference in New Issue
Block a user