Adding 'TextDirection.Rotate180'

This commit is contained in:
BobLd
2019-04-23 21:49:29 +01:00
parent 70852c2855
commit afd9cb9f26
2 changed files with 10 additions and 5 deletions

View File

@@ -87,6 +87,10 @@
{
if (System.Math.Abs(StartBaseLine.Y - EndBaseLine.Y) < 10e-5m)
{
if (StartBaseLine.X > EndBaseLine.X)
{
return TextDirection.Rotate180;
}
return TextDirection.Horizontal;
}
else if (System.Math.Abs(StartBaseLine.X - EndBaseLine.X) < 10e-5m)

View File

@@ -1,8 +1,4 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace UglyToad.PdfPig.Content
namespace UglyToad.PdfPig.Content
{
/// <summary>
/// Direction of the text.
@@ -19,6 +15,11 @@ namespace UglyToad.PdfPig.Content
/// </summary>
Horizontal,
/// <summary>
/// Horizontal text, upside down.
/// </summary>
Rotate180,
/// <summary>
/// Rotated text going down.
/// </summary>