Update Text Color
Updates text color of PSD image and saves to PDF file.
Сode Snippet
var psdProcessor = new PsdProcessor();
var psName = psdProcessor.FontResolver.FontRegistry.Add("ARIALUNI.TTF");
psdProcessor.FontResolver.FontRegistry.FallbackFonts.Add(psName);
psdProcessor.TextCallback = (processor, textFrame, textString) =>
{
var text = processor.ProcessText(textFrame);
text.String = textString;
if (textFrame.Name == "Name")
{
text.Brush = new SolidBrush(RgbColor.Red);
}
return text;
};
psdProcessor.Render("BusinessCard.psd", "UpdateTextColor.pdf");
Input
BusinessCard.psd
DownloadOutput
UpdateTextColor.pdf
DownloadUpdateTextColor.png
For AI-assisted development: Download Graphics Mill Code Samples XML Catalog