Aspose.PSD for .NET 22.4 - Release Notes

Key Summary Category
PSDNET-261 Rendering of Outer Glow Layer Effect Feature
PSDNET-1123 Add support of Sha256 License Enhancement
PSDNET-1107 Positioning multi-line text does not match the result in Photoshop Bug
PSDNET-1113 The issue with loading PSD file on text resource data parsing Bug
PSDNET-1129 Incorrect position of the custom pattern after saving as PSD Bug

Public API Changes

Added APIs:

  • T:Aspose.PSD.FileFormats.Psd.JustificationMode
  • F:Aspose.PSD.FileFormats.Psd.JustificationMode.Left
  • F:Aspose.PSD.FileFormats.Psd.JustificationMode.Right
  • F:Aspose.PSD.FileFormats.Psd.JustificationMode.Center
  • M:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.BlendingOptions.AddOuterGlow
  • T:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.FillColor
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.BlendMode
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.IsVisible
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Opacity
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Intensity
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.IsAntiAliasing
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Spread
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Size
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Noise
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.IsSoftBlend
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Range
  • P:Aspose.PSD.FileFormats.Psd.Layers.LayerEffects.OuterGlowEffect.Jitter

Removed APIs:

  • None

Usage examples:

PSDNET-261. Rendering of Outer Glow Layer Effect

string src = "GreenLayer.psd";
string output = "output261.png";

using (var image = (PsdImage)Image.Load(src))
{
    OuterGlowEffect effect = image.Layers[1].BlendingOptions.AddOuterGlow();
    effect.Range = 10;
    effect.Spread = 10;
    ((IColorFillSettings)effect.FillColor).Color = Color.Red;
    effect.Opacity = 128;
    effect.BlendMode = BlendMode.Normal;

    image.Save(output, new PngOptions());
}

PSDNET-1107. Positioning multi-line text does not match the result in Photoshop

string src = "source1107.psd";
string outputPsd = "output.psd";
string outputPng = "output.png";

using (var image = (PsdImage)Image.Load(src))
{ 
   var txtLayer = image.AddTextLayer("Text line1\rText line2\rText line3", new Rectangle(200, 200, 500, 500));
   var portions = txtLayer.TextData.Items;

   portions[0].Paragraph.Justification = JustificationMode.Left;
   portions[1].Paragraph.Justification = JustificationMode.Right;
   portions[2].Paragraph.Justification = JustificationMode.Center;

   txtLayer.TextData.UpdateLayerData();

   image.Save(outputPsd);
   image.Save(outputPng, new PngOptions());
}

PSDNET-1113. The issue with loading PSD file on text resource data parsing

string sourceFile = "input.psd";

using (PsdImage image = (PsdImage) Image.Load(sourceFile))
{
    // Loaded successfully.
}

PSDNET-1129. Incorrect position of the custom pattern after saving as PSD

string sourceFile = "input_1129.psd";
string outputPsd = "out_psdnet1129.psd";
string outputPng = "out_psdnet1129.png";

using (PsdImage image = (PsdImage) Image.Load(sourceFile))
{
    image.Save(outputPsd);
    image.Save(outputPng, new PngOptions());
}