Sigillon 0.2.0
dotnet add package Sigillon --version 0.2.0
NuGet\Install-Package Sigillon -Version 0.2.0
<PackageReference Include="Sigillon" Version="0.2.0" />
<PackageVersion Include="Sigillon" Version="0.2.0" />
<PackageReference Include="Sigillon" />
paket add Sigillon --version 0.2.0
#r "nuget: Sigillon, 0.2.0"
#:package Sigillon@0.2.0
#addin nuget:?package=Sigillon&version=0.2.0
#tool nuget:?package=Sigillon&version=0.2.0
Sigillon
Sealed to the pixel.
Sigillon is an independent Microsoft Word layout and rendering engine for .NET. It parses OOXML, computes layout itself, and paints pages that match Word to the pixel — no Word install, no Office automation, Linux-first. Today it renders DOCX to PDF.
- No Word/Office automation: Runs natively on Linux, Windows, and macOS with .NET 10.
- High-fidelity layout: Full paragraph styling, table layout, borders, shading, headers/footers, numbering, complex fields (
PAGE,NUMPAGES), footnotes, shapes, and images. - Production rendering stack: Text shaping with HarfBuzz and PDF generation with SkiaSharp.
- Deterministic rendering: Consistent pixel-level rendering across platforms when supplied with the same font source.
Getting Started
Installation
Install the NuGet package:
dotnet add package Sigillon
Basic Usage
Render a DOCX file directly to PDF:
using Sigillon;
// Render by file path
Renderer.Render("input.docx", "output.pdf");
// Or render using streams
using var docxStream = File.OpenRead("input.docx");
using var pdfStream = File.Create("output.pdf");
Renderer.Render(docxStream, pdfStream);
Font Configuration
Production and Linux environments should provide explicit font directories for deterministic rendering across hosts:
using Sigillon;
var options = new RenderOptions
{
FontDirectories = new[] { "/opt/docx-fonts" },
UseSystemFonts = false,
};
Renderer.Render("input.docx", "output.pdf", options);
Note: Font resolution is initialized once per process. Reuse the same configuration for subsequent renders in that process.
Font Substitution Report
The face that answers a font is not always of the family the document names: a built-in alias renames a few legacy names (such as Helv to Arial), and a family no font source has is answered through the document's own alternate from its font table, a stand-in a font directory keeps (such as Liberation Sans for Arial), or the final fallback to Arial or Times New Roman. Every render returns a RenderResult whose Fonts report lists each font request, the face that answered it, and how:
var result = Renderer.Render("input.docx", "output.pdf", options);
foreach (var request in result.Fonts.Substitutions)
Console.WriteLine($"{request.RequestedFamily} -> {request.FaceFamily} ({request.Kind})");
A request is a substitution when the answering face's family name is not the requested family. A bold or italic the painter simulates is reported (IsStyleSimulated) but is not a substitution. The report carries family and face names only, never the document's text or file paths.
Strict Fonts
To refuse a render that would substitute a font, set StrictFonts. The render stops after layout, before any byte of the PDF is written, and throws FontSubstitutionRefusedException, whose Report names what would have been substituted:
var strict = new RenderOptions
{
FontDirectories = new[] { "/opt/docx-fonts" },
UseSystemFonts = false,
StrictFonts = true,
};
try
{
Renderer.Render("input.docx", "output.pdf", strict);
}
catch (FontSubstitutionRefusedException refused)
{
Console.Error.WriteLine(refused.Message); // families and counts, never the document's text
}
StrictFonts is chosen per render, so strict and lenient renders can share a process.
Upgrading from 0.1.x:
Rendernow returnsRenderResultinstead ofvoid. Recompile against 0.2.0; code compiled against 0.1.x fails withMissingMethodException. See the changelog.
CLI Tool
A command-line interface is available as a .NET global tool:
dotnet tool install --global Sigillon.Cli
sigillon render input.docx output.pdf
See the Sigillon.Cli package for more details.
Documentation & Repository
For complete documentation, roadmap, architecture details, and issue tracking, visit the Sigillon GitHub repository.
Licensing
Licensed under the GNU Affero General Public License v3 (AGPL-3.0-only).
Commercial licensing options are available for proprietary use; see COMMERCIAL.md.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- DocumentFormat.OpenXml (>= 3.3.0)
- HarfBuzzSharp (>= 14.2.1.2)
- HarfBuzzSharp.NativeAssets.Linux (>= 14.2.1.2)
- SkiaSharp (>= 4.150.1)
- SkiaSharp.NativeAssets.Linux.NoDependencies (>= 4.150.1)
- System.Drawing.Common (>= 9.0.8)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.