Seamlessly read, add, and export your Word documents as WEBP images by downloading the DLLs of the C# Word documents API version 24.4, benefiting from smaller file sizes and superior visual fidelity compared to traditional formats like JPEG. This functionality is available for .NET Framework 4.6.2 and above.
Elevate the visual appeal of the shapes and drawing objects in your documents by applying glow and reflection effects with ease. Customize the color, transparency, and size of these effects to achieve the desired visual impact using Aspose.Words for .NET 24.4 release. Please check the following C# code sample to learn to manipulate the glow effect:
// For complete examples and data files, please go to https://github.com/aspose-words/Aspose.Words-for-.NET.git.
Document doc = new Document(MyDir + "Various shapes.docx");
Shape shape = (Shape)doc.GetChild(NodeType.Shape, 0, true);
// Apply glow effect to the shape.
shape.Glow.Color = Color.Salmon;
shape.Glow.Radius = 30;
shape.Glow.Transparency = 0.15;
doc.Save(ArtifactsDir + "Shape.Glow.docx");
doc = new Document(ArtifactsDir + "Shape.Glow.docx");
shape = (Shape)doc.GetChild(NodeType.Shape, 0, true);
// Check glow effect attributes.
Assert.AreEqual(Color.FromArgb(217, 250, 128, 114).ToArgb(), shape.Glow.Color.ToArgb());
Assert.AreEqual(30, shape.Glow.Radius);
Assert.AreEqual(0.15d, shape.Glow.Transparency, 0.01d);
// Remove glow effect from the shape.
shape.Glow.Remove();
Assert.AreEqual(Color.Black.ToArgb(), shape.Glow.Color.ToArgb());
Assert.AreEqual(0, shape.Glow.Radius);
Assert.AreEqual(0, shape.Glow.Transparency);
Source*
Fonts Embedding Made Easy
Using this release, developers can easily embed fonts declared within @font-face rules while loading HTML documents with the help of the newly added HtmlLoadOptions.SupportFontFaceRules
public property. The provided C# code example showcases the functionality usage:
// For complete examples and data files, please go to https://github.com/aspose-words/Aspose.Words-for-.NET.git.
HtmlLoadOptions loadOptions = new HtmlLoadOptions();
loadOptions.SupportFontFaceRules = true;
Document doc = new Document(MyDir + "Html with FontFace.html", loadOptions);
Assert.AreEqual("Squarish Sans CT Regular", doc.FontInfos[0].Name);
Source*
Secure Your Documents with Digital Signatures
You can now sign your documents digitally for augmented security and integrity by leveraging the newly added DigitalSignatureDetails
class to specify signing options, as demonstrated in this C# code example:
// For complete examples and data files, please go to https://github.com/aspose-words/Aspose.Words-for-.NET.git.
Document doc = new Document(MyDir + "Document.docx");
CertificateHolder certificateHolder = CertificateHolder.Create(MyDir + "morzal.pfx", "aw");
OoxmlSaveOptions saveOptions = new OoxmlSaveOptions();
saveOptions.DigitalSignatureDetails = new DigitalSignatureDetails(
certificateHolder,
new SignOptions() { Comments = "Some comments", SignTime = DateTime.Now });
doc.Save(ArtifactsDir + "OoxmlSaveOptions.DigitalSignature.docx", saveOptions);
Source*
Develop C# document processing apps with extended chart formatting options and control the visual appearance of the charts with the introduction of public format properties for Chart
, ChartTitle
, ChartAxisTitle
, and ChartLegend
classes in version 24.4 of the .NET API. This C# code snippet shows how to set the background colors of these chart elements:
// For complete examples and data files, please go to https://github.com/aspose-words/Aspose.Words-for-.NET.git.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
Shape shape = builder.InsertChart(ChartType.Column, 432, 252);
Chart chart = shape.Chart;
// Delete series generated by default.
ChartSeriesCollection series = chart.Series;
series.Clear();
string[] categories = new string[] { "Category 1", "Category 2" };
series.Add("Series 1", categories, new double[] { 1, 2 });
series.Add("Series 2", categories, new double[] { 3, 4 });
// Format chart background.
chart.Format.Fill.Solid(Color.DarkSlateGray);
// Hide axis tick labels.
chart.AxisX.TickLabels.Position = AxisTickLabelPosition.None;
chart.AxisY.TickLabels.Position = AxisTickLabelPosition.None;
// Format chart title.
chart.Title.Format.Fill.Solid(Color.LightGoldenrodYellow);
// Format axis title.
chart.AxisX.Title.Show = true;
chart.AxisX.Title.Format.Fill.Solid(Color.LightGoldenrodYellow);
// Format legend.
chart.Legend.Format.Fill.Solid(Color.LightGoldenrodYellow);
doc.Save(ArtifactsDir + "Charts.ChartFormat.docx");
Source*
You can view the list of all new features, enhancements, and bug fixes introduced in this release by visiting Aspose.Words for .NET 24.4 Release Notes.