개정판 91efe37a
issue #534: Add ItemRect property to all of controls
Change-Id: Id0d640b9fd9959615758b5e55b499f97d6f38dae
MarkupToPDF/Controls/Etc/ImgControl.cs | ||
---|---|---|
346 | 346 |
public Geometry PathData { get; set; } |
347 | 347 |
|
348 | 348 |
/// <summary> |
349 |
/// return ImgControl's area |
|
350 |
/// </summary> |
|
351 |
/// <author>humkyung</author> |
|
352 |
/// <date>2019.06.13</date> |
|
353 |
public override Rect ItemRect |
|
354 |
{ |
|
355 |
get |
|
356 |
{ |
|
357 |
double dMinX = Math.Min(this.StartPoint.X, this.EndPoint.X); |
|
358 |
double dMinY = Math.Min(this.StartPoint.Y, this.EndPoint.Y); |
|
359 |
double dMaxX = Math.Max(this.StartPoint.X, this.EndPoint.X); |
|
360 |
double dMaxY = Math.Max(this.StartPoint.Y, this.EndPoint.Y); |
|
361 |
|
|
362 |
return new Rect(new Point(dMinX, dMinY), new Point(dMaxX, dMaxY)); |
|
363 |
} |
|
364 |
} |
|
365 |
|
|
366 |
/// <summary> |
|
349 | 367 |
/// Serialize this |
350 | 368 |
/// </summary> |
351 | 369 |
/// <param name="sUserId"></param> |
내보내기 Unified diff