I have been working on converting a program from Python to C# using PDFSharp, and this library has made it easy. However, I have been attempting to create a method to skew text. Basically, I want to slant the text by a given angle, such as 45 degrees.
Is there a function that allows this? It was straightforward in Python using the FPDF library, which has a .skew method as follows:
with pdfdoc.skew(angle, 0): pdfdoc.text(text=stemp, x=xp, y=yp)
Alternatively, can I access the graphics matrix? When using an old version of itextsharp (version 5), I could access the textmatrix and provide the appropriate adjustment where skewing you just applied TAN(angle) to the matrix.
[1 tan a tan b 1 0 0]
where a = angle of rise, b = angle of slope off vertical
Any help would be appreciated. Thanks Paul.
|