Open Hvishal88 opened 4 weeks ago
Hello, @Hvishal88 I started to research this custom rotation.
Hello, @Hvishal88
Could you probe my example with using of textStamp.RotateAngle = 45; instead of textStamp.Rotate = Rotation.on90; // Rotate 90 degrees clockwise to done your solution, seems it work:
// Create a new PDF document Document pdfDocument = new Document();
// Add a page to the document Page page = pdfDocument.Pages.Add();
// Create a TextStamp with the desired text TextStamp textStamp = new TextStamp("Sample Text");
// Set the text properties textStamp.TextState.Font = FontRepository.FindFont("Arial"); textStamp.TextState.FontSize = 72; textStamp.TextState.ForegroundColor = Aspose.Pdf.Color.FromRgb(System.Drawing.Color.Red);
// Set the rotation angle (in degrees) textStamp.RotateAngle = 45; // textStamp.Rotate = Rotation.on90; // Rotate 90 degrees clockwise
// Set the position of the stamp textStamp.XIndent = 100; textStamp.YIndent = 400;
// Add the TextStamp to the page page.AddStamp(textStamp);
// Save the PDF document pdfDocument.Save("output.pdf");
// Dispose of the document pdfDocument.Dispose();
I am trying to set TextStamp with 45 angle rotation but there is no such option available as a part of Rotation enum(Aspose.Pdf.Rotation)
is there any possibility to go for custom Rotation value?
I am using : Assembly Aspose.PDF, Version=24.7.0.0 for the .net