![]() |
VOOZH | about |
dotnet add package MigraDocXML --version 3.0.0
NuGet\Install-Package MigraDocXML -Version 3.0.0
<PackageReference Include="MigraDocXML" Version="3.0.0" />
<PackageVersion Include="MigraDocXML" Version="3.0.0" />Directory.Packages.props
<PackageReference Include="MigraDocXML" />Project file
paket add MigraDocXML --version 3.0.0
#r "nuget: MigraDocXML, 3.0.0"
#:package MigraDocXML@3.0.0
#addin nuget:?package=MigraDocXML&version=3.0.0Install as a Cake Addin
#tool nuget:?package=MigraDocXML&version=3.0.0Install as a Cake Tool
From having to do a fair amount of work producing PDFs, I found MigraDoc is currently the only really viable open source .NET option available. It includes some excellent features that give a lot of control over creating PDFs, while still staying high level enough to be easy to understand.
However, the way document designs are written does also present some major drawbacks:
MigraDocXML aims to solve these problems, while still keeping as much flexibility as possible. Below are some of its features:
Below is a demonstration of a layout file which takes in a json file to produce .
json:
{
"Name": "MigraDocXML",
"Positives": [
"Simple to learn",
"Easily readable design layouts",
"Full cascading style system",
"Support for PDFSharp graphics",
"Includes a powerful lightweight expression evaluator",
"Regular updates"
],
"Negatives": [
]
}
xml:
<?xml version="1.0"?>
<Document xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="https://gitlab.com/jamescoyle/MigraDocXML/raw/master/MigraDocXML/schema.xsd">
<Style Target="p">
<Setters Format.Font.Name="Calibri" Format.SpaceBefore="2mm" Format.SpaceAfter="2mm"/>
</Style>
<Style Target="p" Name="Heading">
<Setters Format.Font.Bold="true" Format.Font.Underline="Single"/>
</Style>
<Section>
<p Style="Heading" Format.Font.Size="15" Format.Alignment="Center">Reasons you should use {Model.Name}</p>
<p Style="Heading">Positives:</p>
<ForEach Var="positive" In="Model.Positives.OrderByDesc(x => x.Length)">
<p>{positive}</p>
</ForEach>
<p Style="Heading">Negatives:</p>
<ForEach Var="negative" In="Model.Negatives">
<p>{negative}</p>
</ForEach>
</Section>
</Document>
MigraDocXML also includes a small WPF app for easily previewing the effect of changes to the layout or data on your output PDF. You can use the incredibly basic text editors included in the app, or, use whichever one you normally do. Either way, each time you save changes to your documents, the PDF will automatically get regenerated.
Part of the development of MigraDocXML is kindly sponsored by:
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 net5.0 was computed. net5.0-windows net5.0-windows was computed. net6.0 net6.0 is compatible. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 was computed. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 was computed. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 netcoreapp2.0 was computed. netcoreapp2.1 netcoreapp2.1 was computed. netcoreapp2.2 netcoreapp2.2 was computed. netcoreapp3.0 netcoreapp3.0 was computed. netcoreapp3.1 netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 netstandard2.0 is compatible. netstandard2.1 netstandard2.1 was computed. |
| .NET Framework | net461 net461 was computed. net462 net462 was computed. net463 net463 was computed. net47 net47 was computed. net471 net471 was computed. net472 net472 was computed. net48 net48 was computed. net481 net481 was computed. |
| MonoAndroid | monoandroid monoandroid was computed. |
| MonoMac | monomac monomac was computed. |
| MonoTouch | monotouch monotouch was computed. |
| Tizen | tizen40 tizen40 was computed. tizen60 tizen60 was computed. |
| Xamarin.iOS | xamarinios xamarinios was computed. |
| Xamarin.Mac | xamarinmac xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos xamarinwatchos was computed. |
Showing the top 1 NuGet packages that depend on MigraDocXML:
| Package | Downloads |
|---|---|
|
MigraDocXML-ZXing
An extension library for MigraDocXML, adding barcode support using ZXing.NET (https://github.com/micjahn/ZXing.Net). |
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0 | 7,291 | 9/2/2024 |
| 2.9.3 | 19,252 | 3/3/2023 |
| 2.9.2 | 7,095 | 2/28/2023 |
| 2.9.1 | 3,847 | 2/20/2023 |
| 2.9.0 | 8,971 | 2/6/2022 |
| 2.8.0 | 3,676 | 12/11/2021 |
| 2.7.2 | 4,941 | 10/21/2021 |
| 2.7.1 | 3,891 | 9/29/2021 |
| 2.7.0 | 3,841 | 9/7/2021 |
| 2.6.11 | 5,721 | 10/11/2020 |
| 2.6.10 | 4,031 | 8/29/2020 |
| 2.6.9 | 4,098 | 5/9/2020 |
| 2.6.6 | 5,344 | 3/30/2020 |
| 2.6.5 | 4,613 | 10/7/2019 |
| 2.6.3 | 9,432 | 7/14/2019 |
| 2.6.2 | 5,438 | 7/8/2019 |
| 2.6.1 | 4,372 | 7/5/2019 |
| 2.6.0 | 4,429 | 7/5/2019 |
| 2.5.0 | 4,421 | 6/5/2019 |
Added support for annotations