Hello,
I try to adjust automatically the font size of the watermark text in order to fill the whole page. How can I accomplish this ? Any ideas ?
Cordially,
Kakone.
Automatic watermark font size
Automatic watermark font size
Please place following code in BeforePrintEvent of page:
Thank you.
Code: Select all
StiText text = new StiText();
text.ClientRectangle = Page1.ClientRectangle;
text.Text.Value = Page1.Watermark.Text;
text.Angle = Page1.Watermark.Angle;
text.Page = Page1;
text.Font = new Font(Page1.Watermark.Font.FontFamily, 1020);
Page1.Watermark.Font = text.GetActualFont(Page1.Watermark.Text);
Automatic watermark font size
It's perfect !
Thanks a lot.
Thanks a lot.