This forum contains outdated content and is available for reading only. Please contact technical support if you have any questions.

Notification

Icon
Error

Options
Go to last post Go to first unread
Duy Nguyen  
#1 Posted : Thursday, June 17, 2021 10:04:14 AM(UTC)
Duy Nguyen

Rank: Newbie

Groups: Guest
Joined: 6/17/2021(UTC)
Posts: 1

Hi,

I want to change the Font for PsdTextFrame in psd file. Can you please give me advise.

I try to use code as beblow but I can't

var textFrame = (PsdTextFrame)frame;

textFrame.Font = Aurigma.GraphicsMill.Drawing.Font("Arial", 1);

If I use graphics to raw new string with new font , I don't know how to add a new bitmap to current PSD.

using (var graphics = bitMap.GetAdvancedGraphics())

{

var font = FontRegistry.Installed.CreateFont("Arial", textFrame.FontSize, graphics.DpiX, graphics.DpiY);

var text = new PlainText("MODESTO SR", font);

int y = textFrame.Y - (int)text.GetBlackBox().Top;

text.Position = new System.Drawing.PointF(textFrame.X, y);

graphics.DrawText(text);

}

--> 2 ways above can't have me change Font. Please help me to check.

Thanks,

Duy

Eugene Kosmin  
#2 Posted : Tuesday, July 6, 2021 5:15:09 PM(UTC)
Eugene Kosmin

Rank: Advanced Member

Groups: Guest
Joined: 9/19/2006(UTC)
Posts: 505

Was thanked: 41 time(s) in 41 post(s)
Best regards,

Eugene Kosmin

The Aurigma Development Team

Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.