2017-11-26 22:19:42 +00:00
|
|
|
|
namespace UglyToad.Pdf.Graphics.Operations.PathConstruction
|
2017-11-22 18:41:34 +00:00
|
|
|
|
{
|
2017-11-30 23:47:24 +00:00
|
|
|
|
using Content;
|
2017-11-22 18:41:34 +00:00
|
|
|
|
using Geometry;
|
|
|
|
|
|
|
|
|
|
|
|
internal class AppendRectangle : IGraphicsStateOperation
|
|
|
|
|
|
{
|
|
|
|
|
|
public const string Symbol = "re";
|
|
|
|
|
|
|
|
|
|
|
|
public string Operator => Symbol;
|
|
|
|
|
|
|
|
|
|
|
|
public PdfPoint LowerLeft { get; }
|
|
|
|
|
|
|
|
|
|
|
|
public decimal Width { get; }
|
|
|
|
|
|
|
|
|
|
|
|
public decimal Height { get; }
|
|
|
|
|
|
|
|
|
|
|
|
public AppendRectangle(decimal x, decimal y, decimal width, decimal height)
|
|
|
|
|
|
{
|
|
|
|
|
|
LowerLeft = new PdfPoint(x, y);
|
|
|
|
|
|
|
|
|
|
|
|
Width = width;
|
|
|
|
|
|
Height = height;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2017-11-30 23:47:24 +00:00
|
|
|
|
public void Run(IOperationContext operationContext, IResourceStore resourceStore)
|
|
|
|
|
|
{
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2017-11-22 18:41:34 +00:00
|
|
|
|
public override string ToString()
|
|
|
|
|
|
{
|
|
|
|
|
|
return $"{LowerLeft.X} {LowerLeft.Y} {Width} {Height} {Symbol}";
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|