|
@@ -318,16 +318,16 @@ namespace ComPDFKit.Tool.DrawTool
|
|
crossLine.Clear();
|
|
crossLine.Clear();
|
|
rightLine.Clear();
|
|
rightLine.Clear();
|
|
CPDFDistanceMeasure LineMeasure = Annot.GetDistanceMeasure();
|
|
CPDFDistanceMeasure LineMeasure = Annot.GetDistanceMeasure();
|
|
- double LeadLength = LineMeasure.GetLeadLength() / 72D * 96D;
|
|
|
|
- double LeadOffset = LineMeasure.GetLeadOffset() / 72D * 96D;
|
|
|
|
- double LeadExtension = LineMeasure.GetLeadExtension() / 72D * 96D;
|
|
|
|
|
|
+ double LeadLength = LineMeasure.GetLeadLength() / 72D * 96D * annotData.CurrentZoom;
|
|
|
|
+ double LeadOffset = LineMeasure.GetLeadOffset() / 72D * 96D * annotData.CurrentZoom;
|
|
|
|
+ double LeadExtension = LineMeasure.GetLeadExtension() / 72D * 96D * annotData.CurrentZoom;
|
|
|
|
|
|
List<Point> orderPoints = activePoints.AsEnumerable().OrderBy(x => x.X).ToList();
|
|
List<Point> orderPoints = activePoints.AsEnumerable().OrderBy(x => x.X).ToList();
|
|
- Vector lineVector = (activePoints[1] - activePoints[0]) * annotData.CurrentZoom;
|
|
|
|
|
|
+ Vector lineVector = (activePoints[1] - activePoints[0]) ;
|
|
lineVector.Normalize();
|
|
lineVector.Normalize();
|
|
- Vector leadEndVector = lineVector * (Math.Abs(LeadLength) + Math.Abs(LeadOffset) + Math.Abs(LeadExtension) * annotData.CurrentZoom);
|
|
|
|
- Vector leadStartVector = lineVector * (Math.Abs(LeadOffset)) * annotData.CurrentZoom;
|
|
|
|
- Vector leadCrossVector = lineVector * (Math.Abs(LeadLength) * annotData.CurrentZoom + Math.Abs(LeadOffset));
|
|
|
|
|
|
+ Vector leadEndVector = lineVector * (Math.Abs(LeadLength) + Math.Abs(LeadOffset) + Math.Abs(LeadExtension));
|
|
|
|
+ Vector leadStartVector = lineVector * (Math.Abs(LeadOffset));
|
|
|
|
+ Vector leadCrossVector = lineVector * (Math.Abs(LeadLength) + Math.Abs(LeadOffset));
|
|
Matrix rotateMatrix = new Matrix();
|
|
Matrix rotateMatrix = new Matrix();
|
|
double angle = LeadLength < 0 ? 90 : -90;
|
|
double angle = LeadLength < 0 ? 90 : -90;
|
|
rotateMatrix.Rotate(angle);
|
|
rotateMatrix.Rotate(angle);
|