public void RotateAt() { var doc = new PortableDocument(); doc.AddPage(200, 200); doc.SaveState(); doc.SetColor(1, 0, 0); doc.RotateAt(50, 20, 30); doc.DrawRectangle(50, 20, 100, 15); doc.RestoreState(); doc.DrawRectangle(50, 20, 100, 15); doc.Save(Folder + "RotateAt.pdf"); }
public void DrawText_Rotated() { var doc = new PortableDocument(); doc.AddPage(200, 200); doc.SetFont("Arial", 12); for (int i = 0; i <= 360; i += 30) { doc.SaveState(); doc.RotateAt(100, 100, i); doc.DrawText(100, 100, "Hello world!"); doc.RestoreState(); } doc.Save(Folder + "DrawText_Rotated.pdf"); }