1
|
using System;
|
2
|
using System.Net;
|
3
|
using System.Windows;
|
4
|
using System.Windows.Controls;
|
5
|
using System.Windows.Documents;
|
6
|
using System.Windows.Ink;
|
7
|
using System.Windows.Input;
|
8
|
using System.Windows.Media;
|
9
|
using System.Windows.Media.Animation;
|
10
|
using System.Windows.Shapes;
|
11
|
using System.ComponentModel;
|
12
|
using System.Collections.Generic;
|
13
|
using MarkupToPDF.Controls.Common;
|
14
|
using MarkupToPDF.Common;
|
15
|
using MarkupToPDF.Serialize.Core;
|
16
|
using MarkupToPDF.Serialize.S_Control;
|
17
|
using System.Linq;
|
18
|
|
19
|
namespace MarkupToPDF.Controls.Shape
|
20
|
{
|
21
|
//[TemplatePart(Name = "PART_TriPath", Type = typeof(Path))]
|
22
|
public class TriControl : CommentUserInfo, IDisposable, INotifyPropertyChanged, IPath, IMarkupCommonData, IShapeControl, IDashControl
|
23
|
{
|
24
|
public Path Base_TriPath { get; set; }
|
25
|
//public enum PaintSet { None, Fill, Hatch };
|
26
|
private const string PART_TriPath = "PART_TriPath";
|
27
|
|
28
|
//public Path Base_TriPath = null;
|
29
|
|
30
|
static TriControl()
|
31
|
{
|
32
|
DefaultStyleKeyProperty.OverrideMetadata(typeof(TriControl), new FrameworkPropertyMetadata(typeof(TriControl)));
|
33
|
ResourceDictionary dictionary = new ResourceDictionary();
|
34
|
dictionary.Source = new Uri("/MarkupToPDF;component/themes/generic.xaml", UriKind.RelativeOrAbsolute);
|
35
|
Application.Current.Resources.MergedDictionaries.Add(dictionary);
|
36
|
}
|
37
|
|
38
|
#region Dependency Properties
|
39
|
|
40
|
public static readonly DependencyProperty OverViewPathDataProperty = DependencyProperty.Register(
|
41
|
"OverViewPathData", typeof(Geometry), typeof(TriControl), new PropertyMetadata(null));
|
42
|
|
43
|
public static readonly DependencyProperty IsSelectedProperty =
|
44
|
DependencyProperty.Register("IsSelected", typeof(bool), typeof(TriControl), new FrameworkPropertyMetadata(false, IsSelectedChanged));
|
45
|
|
46
|
public static readonly DependencyProperty ControlTypeProperty =
|
47
|
DependencyProperty.Register("ControlType", typeof(ControlType), typeof(TriControl), new FrameworkPropertyMetadata(ControlType.Triangle));
|
48
|
|
49
|
public static readonly DependencyProperty LineSizeProperty = DependencyProperty.Register(
|
50
|
"LineSize", typeof(double), typeof(TriControl), new PropertyMetadata((Double)3));
|
51
|
public static readonly DependencyProperty UserIDProperty = DependencyProperty.Register(
|
52
|
"UserID", typeof(string), typeof(TriControl), new PropertyMetadata(null));
|
53
|
//강인구 추가
|
54
|
public static readonly DependencyProperty DashSizeProperty = DependencyProperty.Register(
|
55
|
"DashSize", typeof(DoubleCollection), typeof(TriControl), new PropertyMetadata(new DoubleCollection { 1, 1 }, PointValueChanged));
|
56
|
public static readonly DependencyProperty PathDataProperty = DependencyProperty.Register(
|
57
|
"PathData", typeof(Geometry), typeof(TriControl), null);
|
58
|
public static readonly DependencyProperty StrokeColorProperty = DependencyProperty.Register(
|
59
|
"StrokeColor", typeof(SolidColorBrush), typeof(TriControl), new PropertyMetadata(new SolidColorBrush(Colors.Red)));
|
60
|
public static readonly DependencyProperty FillColorProperty = DependencyProperty.Register(
|
61
|
"FillColor", typeof(SolidColorBrush), typeof(TriControl), new PropertyMetadata(new SolidColorBrush(Colors.Red)));
|
62
|
public static readonly DependencyProperty EndPointProperty = DependencyProperty.Register(
|
63
|
"EndPoint", typeof(Point), typeof(TriControl), new PropertyMetadata(new Point(0, 0), PointValueChanged));
|
64
|
public static readonly DependencyProperty MidPointProperty = DependencyProperty.Register(
|
65
|
"MidPoint", typeof(Point), typeof(TriControl), new PropertyMetadata(new Point(0, 0), PointValueChanged));
|
66
|
public static readonly DependencyProperty StartPointProperty = DependencyProperty.Register(
|
67
|
"StartPoint", typeof(Point), typeof(TriControl), new PropertyMetadata(new Point(0, 0), PointValueChanged));
|
68
|
//강인구 추가
|
69
|
public static readonly DependencyProperty PaintProperty = DependencyProperty.Register(
|
70
|
"Paint", typeof(PaintSet), typeof(TriControl), new PropertyMetadata(PaintSet.None, PointValueChanged));
|
71
|
|
72
|
public static readonly DependencyProperty PointSetProperty = DependencyProperty.Register(
|
73
|
"PointSet", typeof(List<Point>), typeof(TriControl), new PropertyMetadata(new List<Point>(), PointValueChanged));
|
74
|
public static readonly DependencyProperty AngleProperty = DependencyProperty.Register("Angle", typeof(double), typeof(TriControl), new
|
75
|
PropertyMetadata((double)0.0, new PropertyChangedCallback(AngleValueChanged)));
|
76
|
public static readonly DependencyProperty CenterXProperty = DependencyProperty.Register("CenterX", typeof(double), typeof(TriControl),
|
77
|
new PropertyMetadata((double)0, OnCenterXYChanged));
|
78
|
|
79
|
public static readonly DependencyProperty CenterYProperty = DependencyProperty.Register("CenterY", typeof(double), typeof(TriControl),
|
80
|
new PropertyMetadata((double)0, OnCenterXYChanged));
|
81
|
|
82
|
#endregion
|
83
|
#region PropertyChanged Method
|
84
|
|
85
|
public static void IsSelectedChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
|
86
|
{
|
87
|
//var instance = (TriControl)sender;
|
88
|
|
89
|
//if (e.OldValue != e.NewValue && instance.Base_TriPath != null)
|
90
|
//{
|
91
|
|
92
|
// instance.SetValue(e.Property, e.NewValue);
|
93
|
|
94
|
// if (instance.IsSelected)
|
95
|
// {
|
96
|
// instance.Base_TriPath.Stroke = new SolidColorBrush(Colors.Blue);
|
97
|
// }
|
98
|
// else
|
99
|
// {
|
100
|
// instance.Base_TriPath.Stroke = new SolidColorBrush(Colors.Red);
|
101
|
// }
|
102
|
//}
|
103
|
}
|
104
|
|
105
|
public static void PointValueChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
|
106
|
{
|
107
|
var instance = (TriControl)sender;
|
108
|
|
109
|
if (e.OldValue != e.NewValue && instance.Base_TriPath != null)
|
110
|
{
|
111
|
instance.SetValue(e.Property, e.NewValue);
|
112
|
instance.SetTri();
|
113
|
}
|
114
|
}
|
115
|
|
116
|
|
117
|
public static void OnCenterXYChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
|
118
|
{
|
119
|
var instance = (TriControl)sender;
|
120
|
if (e.OldValue != e.NewValue && instance.Base_TriPath != null)
|
121
|
{
|
122
|
instance.SetValue(e.Property, e.NewValue);
|
123
|
instance.SetTri();
|
124
|
}
|
125
|
}
|
126
|
public static void AngleValueChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
|
127
|
{
|
128
|
var instance = (TriControl)sender;
|
129
|
if (e.OldValue != e.NewValue && instance.Base_TriPath != null)
|
130
|
{
|
131
|
instance.SetValue(e.Property, e.NewValue);
|
132
|
instance.SetTri();
|
133
|
}
|
134
|
}
|
135
|
#endregion
|
136
|
#region Properties
|
137
|
|
138
|
public Double LineSize
|
139
|
{
|
140
|
get { return (Double)GetValue(LineSizeProperty); }
|
141
|
set
|
142
|
{
|
143
|
if (this.LineSize != value)
|
144
|
{
|
145
|
SetValue(LineSizeProperty, value);
|
146
|
}
|
147
|
}
|
148
|
}
|
149
|
public string UserID
|
150
|
{
|
151
|
get { return (string)GetValue(UserIDProperty); }
|
152
|
set
|
153
|
{
|
154
|
if (this.UserID != value)
|
155
|
{
|
156
|
SetValue(UserIDProperty, value);
|
157
|
OnPropertyChanged("UserID");
|
158
|
}
|
159
|
}
|
160
|
}
|
161
|
public SolidColorBrush FillColor
|
162
|
{
|
163
|
get { return (SolidColorBrush)GetValue(FillColorProperty); }
|
164
|
set
|
165
|
{
|
166
|
if (this.FillColor != value)
|
167
|
{
|
168
|
SetValue(FillColorProperty, value);
|
169
|
}
|
170
|
}
|
171
|
}
|
172
|
public DoubleCollection DashSize
|
173
|
{
|
174
|
get { return (DoubleCollection)GetValue(DashSizeProperty); }
|
175
|
set
|
176
|
{
|
177
|
if (this.DashSize != value)
|
178
|
{
|
179
|
SetValue(DashSizeProperty, value);
|
180
|
}
|
181
|
}
|
182
|
}
|
183
|
public PaintSet Paint
|
184
|
{
|
185
|
get { return (PaintSet)GetValue(PaintProperty); }
|
186
|
set
|
187
|
{
|
188
|
if (this.Paint != value)
|
189
|
{
|
190
|
SetValue(PaintProperty, value);
|
191
|
}
|
192
|
}
|
193
|
}
|
194
|
|
195
|
|
196
|
public override SolidColorBrush StrokeColor
|
197
|
{
|
198
|
get { return (SolidColorBrush)GetValue(StrokeColorProperty); }
|
199
|
set
|
200
|
{
|
201
|
if (this.StrokeColor != value)
|
202
|
{
|
203
|
SetValue(StrokeColorProperty, value);
|
204
|
}
|
205
|
}
|
206
|
}
|
207
|
public Geometry OverViewPathData
|
208
|
{
|
209
|
get
|
210
|
{
|
211
|
return (Geometry)GetValue(OverViewPathDataProperty);
|
212
|
}
|
213
|
set
|
214
|
{
|
215
|
SetValue(OverViewPathDataProperty, value);
|
216
|
OnPropertyChanged("OverViewPathData");
|
217
|
}
|
218
|
}
|
219
|
public Geometry PathData
|
220
|
{
|
221
|
get { return (Geometry)GetValue(PathDataProperty); }
|
222
|
set { SetValue(PathDataProperty, value); }
|
223
|
}
|
224
|
public Point EndPoint
|
225
|
{
|
226
|
get { return (Point)GetValue(EndPointProperty); }
|
227
|
set { SetValue(EndPointProperty, value); }
|
228
|
}
|
229
|
public Point StartPoint
|
230
|
{
|
231
|
get { return (Point)GetValue(StartPointProperty); }
|
232
|
set { SetValue(StartPointProperty, value); }
|
233
|
}
|
234
|
public Point MidPoint
|
235
|
{
|
236
|
get { return (Point)GetValue(MidPointProperty); }
|
237
|
set { SetValue(MidPointProperty, value); }
|
238
|
}
|
239
|
public List<Point> PointSet
|
240
|
{
|
241
|
get { return (List<Point>)GetValue(PointSetProperty); }
|
242
|
set { SetValue(PointSetProperty, value); }
|
243
|
}
|
244
|
|
245
|
public override bool IsSelected
|
246
|
{
|
247
|
get
|
248
|
{
|
249
|
return (bool)GetValue(IsSelectedProperty);
|
250
|
}
|
251
|
set
|
252
|
{
|
253
|
SetValue(IsSelectedProperty, value);
|
254
|
}
|
255
|
}
|
256
|
|
257
|
public override ControlType ControlType
|
258
|
{
|
259
|
get
|
260
|
{
|
261
|
return (ControlType)GetValue(ControlTypeProperty);
|
262
|
}
|
263
|
set
|
264
|
{
|
265
|
SetValue(ControlTypeProperty, value);
|
266
|
}
|
267
|
}
|
268
|
|
269
|
|
270
|
public double Angle
|
271
|
{
|
272
|
get { return (double)GetValue(AngleProperty); }
|
273
|
set
|
274
|
{
|
275
|
if (this.Angle != value)
|
276
|
{
|
277
|
SetValue(AngleProperty, value);
|
278
|
}
|
279
|
}
|
280
|
}
|
281
|
public double CenterX
|
282
|
{
|
283
|
get { return (double)GetValue(CenterXProperty); }
|
284
|
set { SetValue(CenterXProperty, value); }
|
285
|
}
|
286
|
public double CenterY
|
287
|
{
|
288
|
get { return (double)GetValue(CenterYProperty); }
|
289
|
set { SetValue(CenterYProperty, value); }
|
290
|
}
|
291
|
#endregion
|
292
|
|
293
|
#region Dependency PropertyChanged
|
294
|
//public static void IsSelectedChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
|
295
|
//{
|
296
|
// var instance = (TriControl)sender;
|
297
|
|
298
|
// if (e.OldValue != e.NewValue && instance.Base_TriPath != null)
|
299
|
// {
|
300
|
|
301
|
// instance.SetValue(e.Property, e.NewValue);
|
302
|
|
303
|
// if (instance.IsSelected)
|
304
|
// {
|
305
|
// instance.Base_TriPath.Stroke = new SolidColorBrush(Colors.Blue);
|
306
|
// }
|
307
|
// else
|
308
|
// {
|
309
|
// instance.Base_TriPath.Stroke = new SolidColorBrush(Colors.Red);
|
310
|
// }
|
311
|
// }
|
312
|
//}
|
313
|
|
314
|
#endregion Dependency PropertyChanged
|
315
|
|
316
|
public override void OnApplyTemplate()
|
317
|
{
|
318
|
base.OnApplyTemplate();
|
319
|
Base_TriPath = GetTemplateChild(PART_TriPath) as Path;
|
320
|
|
321
|
if (Base_TriPath == null)
|
322
|
{
|
323
|
return;
|
324
|
}
|
325
|
|
326
|
this.SetTri();
|
327
|
}
|
328
|
|
329
|
private void SetTri()
|
330
|
{
|
331
|
this.ApplyTemplate();
|
332
|
Base_TriPath.StrokeDashArray.Clear();
|
333
|
foreach (var item in this.DashSize)
|
334
|
{
|
335
|
Base_TriPath.StrokeDashArray.Add(item);
|
336
|
}
|
337
|
Base_TriPath.StrokeDashCap = PenLineCap.Square;
|
338
|
PathFigure pathFigure = new PathFigure();
|
339
|
|
340
|
//this.FillColor = this.StrokeColor;
|
341
|
////Base_TriPath.Fill = this.FillColor;
|
342
|
//Base_TriPath.Fill = Brushes.Red;
|
343
|
//pathFigure.IsFilled = true;
|
344
|
|
345
|
switch (this.Paint)
|
346
|
{
|
347
|
case PaintSet.None:
|
348
|
this.FillColor = null;
|
349
|
pathFigure.IsFilled = false;
|
350
|
break;
|
351
|
case PaintSet.Fill:
|
352
|
this.FillColor = this.StrokeColor;
|
353
|
Base_TriPath.Fill = this.FillColor;
|
354
|
pathFigure.IsFilled = true;
|
355
|
break;
|
356
|
case PaintSet.Hatch:
|
357
|
Base_TriPath.Fill = HatchMake.CreateHatchBrush(this.StrokeColor);
|
358
|
pathFigure.IsFilled = true;
|
359
|
break;
|
360
|
default:
|
361
|
break;
|
362
|
}
|
363
|
pathFigure.StartPoint = this.StartPoint;
|
364
|
|
365
|
List<Point> points = new List<Point>() { this.StartPoint };
|
366
|
if (MidPoint.X != 0 && MidPoint.Y != 0) points.Add(this.MidPoint);
|
367
|
points.Add(this.EndPoint);
|
368
|
|
369
|
PolyLineSegment polyline = new PolyLineSegment(points , true);
|
370
|
pathFigure.Segments.Add(polyline);
|
371
|
|
372
|
PathGeometry pathGeometry = new PathGeometry();
|
373
|
pathGeometry.Figures = new PathFigureCollection();
|
374
|
pathFigure.IsClosed = true;
|
375
|
pathGeometry.Figures.Add(pathFigure);
|
376
|
|
377
|
this.PathData = pathGeometry;
|
378
|
ApplyOverViewData();
|
379
|
|
380
|
}
|
381
|
public void Dispose()
|
382
|
{
|
383
|
GC.Collect();
|
384
|
GC.SuppressFinalize(this);
|
385
|
}
|
386
|
public event PropertyChangedEventHandler PropertyChanged;
|
387
|
protected void OnPropertyChanged(string propName)
|
388
|
{
|
389
|
if (PropertyChanged != null)
|
390
|
PropertyChanged(this, new PropertyChangedEventArgs(propName));
|
391
|
}
|
392
|
|
393
|
public override void ApplyOverViewData()
|
394
|
{
|
395
|
this.OverViewPathData = this.PathData;
|
396
|
}
|
397
|
|
398
|
public void updateControl()
|
399
|
{
|
400
|
this.StartPoint = new Point(this.PointSet[0].X, this.PointSet[0].Y);
|
401
|
this.MidPoint = new Point(this.PointSet[1].X, this.PointSet[1].Y);
|
402
|
this.EndPoint = new Point(this.PointSet[2].X, this.PointSet[2].Y);
|
403
|
}
|
404
|
|
405
|
/// <summary>
|
406
|
/// call when mouse is moving while drawing control
|
407
|
/// </summary>
|
408
|
/// <param name="pt"></param>
|
409
|
/// <param name="bAxisLocked"></param>
|
410
|
public override void OnCreatingMouseMove(Point pt, bool bAxisLocked, bool bShiftKeyPressed)
|
411
|
{
|
412
|
this.EndPoint = pt;
|
413
|
|
414
|
if (bAxisLocked)
|
415
|
{
|
416
|
Point tmp = this.EndPoint;
|
417
|
string angle = MathSet.returnAngleString(this.StartPoint, ref tmp, true);
|
418
|
this.EndPoint = tmp;
|
419
|
}
|
420
|
|
421
|
if (bShiftKeyPressed)
|
422
|
{
|
423
|
List<Point> Points = this.GetRegularTrianglePoints(this.StartPoint, this.EndPoint);
|
424
|
if (2 == Points.Count())
|
425
|
{
|
426
|
this.MidPoint = Points[0];
|
427
|
this.EndPoint = Points[1];
|
428
|
}
|
429
|
}
|
430
|
|
431
|
this.PointSet = new List<Point>
|
432
|
{
|
433
|
this.StartPoint,
|
434
|
this.MidPoint,
|
435
|
this.EndPoint,
|
436
|
};
|
437
|
}
|
438
|
|
439
|
/// <summary>
|
440
|
/// return tricontrols' area
|
441
|
/// </summary>
|
442
|
/// <author>humkyung</author>
|
443
|
/// <date>2019.06.13</date>
|
444
|
public override Rect ItemRect
|
445
|
{
|
446
|
get
|
447
|
{
|
448
|
double dMinX = Math.Min(this.StartPoint.X, this.EndPoint.X);
|
449
|
dMinX = Math.Min(this.MidPoint.X, dMinX);
|
450
|
double dMinY = Math.Min(this.StartPoint.Y, this.EndPoint.Y);
|
451
|
dMinY = Math.Min(this.MidPoint.Y, dMinY);
|
452
|
double dMaxX = Math.Max(this.StartPoint.X, this.EndPoint.X);
|
453
|
dMaxX = Math.Max(this.MidPoint.X, dMaxX);
|
454
|
double dMaxY = Math.Max(this.StartPoint.Y, this.EndPoint.Y);
|
455
|
dMaxY = Math.Max(this.MidPoint.Y, dMaxY);
|
456
|
|
457
|
return new Rect(new Point(dMinX, dMinY), new Point(dMaxX, dMaxY));
|
458
|
}
|
459
|
}
|
460
|
|
461
|
/// <summary>
|
462
|
/// Serialize this
|
463
|
/// </summary>
|
464
|
/// <param name="sUserId"></param>
|
465
|
/// <returns></returns>
|
466
|
public override string Serialize()
|
467
|
{
|
468
|
using (S_TriControl STemp = new S_TriControl())
|
469
|
{
|
470
|
STemp.TransformPoint = "0|0";
|
471
|
STemp.Paint = this.Paint;
|
472
|
STemp.SizeSet = String.Format("{0}", this.LineSize);
|
473
|
//STemp.StrokeColor = "#FF00FF00";
|
474
|
STemp.StrokeColor = this.StrokeColor.Color.ToString();
|
475
|
if (this.FillColor != null)
|
476
|
{
|
477
|
STemp.FillColor = this.FillColor.Color.ToString();
|
478
|
}
|
479
|
STemp.StartPoint = this.StartPoint;
|
480
|
STemp.EndPoint = this.EndPoint;
|
481
|
STemp.MidPoint = this.MidPoint;
|
482
|
STemp.Opac = this.Opacity;
|
483
|
STemp.UserID = this.UserID;
|
484
|
STemp.PointSet = this.PointSet;
|
485
|
STemp.Angle = this.Angle;
|
486
|
STemp.DashSize = this.DashSize;
|
487
|
STemp.Name = this.GetType().Name.ToString();
|
488
|
///강인구 추가(2017.11.02)
|
489
|
///Memo 추가
|
490
|
STemp.Memo = this.Memo;
|
491
|
|
492
|
return "|DZ|" + JsonSerializerHelper.CompressString((STemp.JsonSerialize()));
|
493
|
}
|
494
|
}
|
495
|
|
496
|
/// <summary>
|
497
|
/// create a tricontrol from given string
|
498
|
/// </summary>
|
499
|
/// <param name="str"></param>
|
500
|
/// <returns></returns>
|
501
|
public static TriControl FromString(string str, SolidColorBrush brush, string sProjectNo)
|
502
|
{
|
503
|
using (S_TriControl s = JsonSerializerHelper.JsonDeserialize<S_TriControl>(str))
|
504
|
{
|
505
|
string[] data2 = s.SizeSet.Split(delimiterChars2, StringSplitOptions.RemoveEmptyEntries);
|
506
|
return new TriControl
|
507
|
{
|
508
|
LineSize = Convert.ToDouble(data2.First()),
|
509
|
MidPoint = s.MidPoint,
|
510
|
StartPoint = s.StartPoint,
|
511
|
Paint = s.Paint,
|
512
|
EndPoint = s.EndPoint,
|
513
|
Opacity = s.Opac,
|
514
|
Angle = s.Angle,
|
515
|
DashSize = s.DashSize,
|
516
|
PointSet = s.PointSet,
|
517
|
StrokeColor = brush,
|
518
|
UserID = s.UserID,
|
519
|
Memo = s.Memo
|
520
|
};
|
521
|
}
|
522
|
}
|
523
|
|
524
|
/// <summary>
|
525
|
/// 정삼각형을 그리기위한 두 포인트를 계산하여 넘겨줌
|
526
|
/// </summary>
|
527
|
/// <author>humkyung</author>
|
528
|
/// <date>2018.04.26</date>
|
529
|
/// <param name="StartP"></param>
|
530
|
/// <param name="EndP"></param>
|
531
|
/// <returns></returns>
|
532
|
/// <history>humkyung 2018.05.11 apply axis lock</history>
|
533
|
private List<Point> GetRegularTrianglePoints(Point StartP, Point EndP, bool bCheckAxis = false)
|
534
|
{
|
535
|
List<Point> res = new List<Point>();
|
536
|
|
537
|
double dx = EndP.X - StartP.X;
|
538
|
double dy = EndP.Y - StartP.Y;
|
539
|
double length = Math.Sqrt(dx * dx + dy * dy);
|
540
|
double baseLength = length * Math.Tan(30.0 * Math.PI / 180.0);
|
541
|
dx /= length;
|
542
|
dy /= length;
|
543
|
double tmp = dx;
|
544
|
dx = -dy; dy = tmp; /// rotate by 90 degree
|
545
|
|
546
|
res.Add(new Point(EndP.X + dx * baseLength, EndP.Y + dy * baseLength));
|
547
|
res.Add(new Point(EndP.X - dx * baseLength, EndP.Y - dy * baseLength));
|
548
|
|
549
|
return res;
|
550
|
}
|
551
|
}
|
552
|
}
|