Export to images on non-Windows platforms

We have recently released new bug fixes for GemBox.Document, GemBox.Spreadsheet, and GemBox.Presentation components with support for export to images on non-Windows platforms.

Here are some of the details of this feature.

When using the GemBox component on a Windows operating system, the WPF is used for text layout, rasterizing content to a bitmap, and bitmap decoding and encoding.
This happens automatically if your application targets .NET Framework 3.5+ or .NET 6.0+ for Windows, in which case .NET Windows Desktop Runtime must be installed.

When using GemBox component on a non-Windows platform, such as Linux or macOS, the HarfBuzzSharp package is used for text layout, the SkiaSharp package is used for rasterizing content to a bitmap, and SkiaSharp or the SixLabors.ImageSharp packages are used for bitmap decoding and encoding.
This happens automatically if your application targets frameworks that implement .NET Standard 2.0+ other than .NET Framework 4.6.2+ and .NET 6.0+ for Windows, in which case your project should also reference an appropriate HarfBuzzSharp.NativeAssets.* and SkiaSharp.NativeAssets.* NuGet packages depending on the platform on which your application is running.
The SkiaSharp package is also automatically used when saving content to an SVG image because support for SVG output is currently supported only via SkiaSharp.

You can explicitly override the automatic behavior by setting the ImageSaveOptions.RenderingMode property.
This is useful in some cases, such as if the application renders content in multiple threads. Switching from WPF to Skia will avoid creating a WPF Dispatcher instance for each thread.

The following features are currently supported only on the Windows operating system:

These features currently have WPF dependencies, requiring a .NET Windows Desktop Runtime.

Soon, we plan to add the same feature to the GemBox.Pdf component.

If you have any questions, complaints, or suggestions, feel free to please get in touch with us.