OfficeIMO.Rtf.Pdf
3.4.5
Prefix Reserved
See the version list below for details.
dotnet add package OfficeIMO.Rtf.Pdf --version 3.4.5
NuGet\Install-Package OfficeIMO.Rtf.Pdf -Version 3.4.5
<PackageReference Include="OfficeIMO.Rtf.Pdf" Version="3.4.5" />
<PackageVersion Include="OfficeIMO.Rtf.Pdf" Version="3.4.5" />
<PackageReference Include="OfficeIMO.Rtf.Pdf" />
paket add OfficeIMO.Rtf.Pdf --version 3.4.5
#r "nuget: OfficeIMO.Rtf.Pdf, 3.4.5"
#:package OfficeIMO.Rtf.Pdf@3.4.5
#addin nuget:?package=OfficeIMO.Rtf.Pdf&version=3.4.5
#tool nuget:?package=OfficeIMO.Rtf.Pdf&version=3.4.5
OfficeIMO.Rtf.Pdf
First-party semantic RTF/PDF conversion for OfficeIMO.
This package converts between the semantic OfficeIMO.Rtf document model and the first-party OfficeIMO.Pdf document model. The RTF engine remains the lossless parse/edit/write layer; PDF export is a visual/content conversion to a fixed-layout format, while PDF import uses the first-party logical PDF reader to recover parser-supported metadata, pages, headings, grouped paragraphs, and list markers into an editable RTF document.
Supported export coverage includes semantic paragraphs, paragraph indentation/spacing/line-height/pagination controls, paragraph/style tab stops with supported alignment and leader mapping, section-owned blocks, section page breaks, page-starting section page setup, document and section page-border visual export, rich runs, list markers, document page setup, metadata, tables with horizontal and vertical merged-cell spans, repeating header rows, solid row/cell fills, cell padding, vertical alignment, side and diagonal cell borders, PNG/JPEG images, bookmarks, field result text, hidden text control, footnote/endnote/annotation bodies, and running header/footer text including first-page and even-page variants. RTF can model separate borders per page side; PDF export maps the first styled RTF page border to the first-party PDF engine's uniform page border decoration.
Supported import coverage includes PDF Info metadata, first-page paper size, logical headings, logical list items, grouped paragraphs, basic paragraph spacing, and page transitions as RTF page-break-before paragraphs. PDF is a fixed-layout format, so import is semantic text extraction rather than lossless visual reconstruction of arbitrary PDFs.
Page-starting sections inherit document page defaults and apply their own size, margins, orientation, page numbering, and header/footer declarations. First-page stories require DifferentFirstPageHeaderFooter; even-page stories require Settings.FacingPages. Odd/even selection follows the visible page number, while the first-page variant belongs to each section. Odd/even section breaks and facing-page numbering restarts insert a blank page when needed to align the physical pages. Document page-number starts continue across sections unless a section requests a restart.
Equal-width section columns flow through the shared PDF layout engine, including column gaps, separator lines, and explicit column and page breaks. Continuous sections can switch between single-column and equal-width column flow on the current page. Unequal or right-to-left columns produce SectionColumnsFlattened; changes to page geometry, numbering, or running stories inside a continuous section produce ContinuousSectionPageSettingsFlattened. Column-starting section breaks use a new page and produce ColumnSectionBreakFlattened when multiple columns are involved. The report identifies these limits while retaining the body content.
Import PDF with diagnostics
using OfficeIMO.Pdf;
using OfficeIMO.Rtf.Pdf;
PdfDocument pdf = PdfDocument.Load("source.pdf");
PdfRtfConversionResult result = pdf.ToRtfDocumentResult(new PdfToRtfOptions {
ReadOptions = new PdfReadOptions {
PageSelection = PdfPageSelection.Parse("1-10"),
Pipeline = new PdfUnderstandingPipelineOptions { MaxPages = 10 }
}
});
result.Value.Save("source.rtf");
foreach (var warning in result.Report.Warnings) {
Console.WriteLine($"{warning.Code}: {warning.Message}");
}
ReadOptions is the same canonical semantic configuration used by PdfDocument.Read(...), including page selection, Fast/Structured profile choice, layout settings, and resource budgets. It is ignored when converting an existing PdfDocumentReadResult.
The semantic importer preserves detected run color, font size, bold, and italic through shared logical PDF runs. Tables, images, links, and form widgets currently produce structured loss diagnostics instead of disappearing silently.
Export with diagnostics
using OfficeIMO.Rtf;
using OfficeIMO.Rtf.Pdf;
using OfficeIMO.Pdf;
RtfDocument rtf = RtfDocument.Load("input.rtf");
var options = new RtfToPdfOptions();
PdfDocumentConversionResult result = rtf.ToPdfDocumentResult(options);
result.Report.RequireNoErrorWarnings();
result.Save("output.pdf");
All PDF adapters expose the same PdfResourcePolicy. RTF conversion uses the balanced default: it may discover and embed installed fonts, but it does not allow arbitrary local-file or remote-resource reads. Use PdfResourcePolicy.CreatePortableDeterministic() when conversion must not inspect host fonts. RTF reads document content only from the typed model, so CreateTrustedHost() adds no access unless a format-specific resolver is explicitly configured.
For raw RTF strings, bytes, or streams, use source-explicit APIs such as ToPdfFromRtf(), ToPdfDocumentFromRtf(), and SaveAsPdfFromRtf(). Typed RtfDocument instances use the standard ToPdfBytes(), ToPdfDocument(), and destination-only SaveAsPdf() names.
PNG, JPEG, and supported DIB images use the shared managed drawing layer. Set RtfToPdfOptions.ImageConverter when WMF/EMF content must be rasterized; a null or invalid callback result is reported rather than silently treated as an image.
Dependency footprint
- External: None by default. Applications may provide an optional WMF/EMF rasterization callback.
- OfficeIMO:
OfficeIMO.Rtf,OfficeIMO.Pdf, andOfficeIMO.Coreown semantic mapping, rendering, logical import, and reports.
See the complete OfficeIMO package map for related formats and conversion paths.
Generated capability summary
This table is generated from the package-neutral OfficeIMO operation catalog. The detailed source contracts remain authoritative for feature-level behavior and limitations.
| Operation | Supported | Partial | Preserved | Rejected | Unsupported | Not applicable |
|---|---|---|---|---|---|---|
| Convert | 1 | 1 | 0 | 0 | 0 | 0 |
The complete rows for OfficeIMO.Rtf.Pdf are published in the generated operation contract.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. 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. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 is compatible. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETFramework 4.7.2
- OfficeIMO.Core (>= 3.4.5)
- OfficeIMO.Pdf (>= 3.4.5)
- OfficeIMO.Rtf (>= 3.4.5)
-
.NETStandard 2.0
- OfficeIMO.Core (>= 3.4.5)
- OfficeIMO.Pdf (>= 3.4.5)
- OfficeIMO.Rtf (>= 3.4.5)
-
net10.0
- OfficeIMO.Core (>= 3.4.5)
- OfficeIMO.Pdf (>= 3.4.5)
- OfficeIMO.Rtf (>= 3.4.5)
-
net8.0
- OfficeIMO.Core (>= 3.4.5)
- OfficeIMO.Pdf (>= 3.4.5)
- OfficeIMO.Rtf (>= 3.4.5)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on OfficeIMO.Rtf.Pdf:
| Package | Downloads |
|---|---|
|
OfficeIMO.Workflows
Typed local document workflows that compose first-party OfficeIMO conversion, PDF, and provenance capabilities. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.5.1 | 0 | 10/16/2026 |
| 3.4.5 | 592 | 10/10/2026 |
| 3.4.4 | 273 | 9/27/2026 |
| 3.4.3 | 267 | 9/12/2026 |
| 3.4.2 | 184 | 9/9/2026 |
| 3.4.1 | 177 | 9/7/2026 |
| 3.4.0 | 124 | 9/6/2026 |
| 3.3.0 | 35,144 | 9/2/2026 |
| 3.2.7 | 2,591 | 8/29/2026 |
| 3.2.6 | 214 | 8/22/2026 |
| 3.2.5 | 206 | 8/21/2026 |
| 3.2.4 | 203 | 8/19/2026 |
| 3.2.3 | 122 | 8/17/2026 |
| 3.2.2 | 323 | 8/13/2026 |
| 3.2.1 | 253 | 8/11/2026 |
| 3.2.0 | 409 | 8/7/2026 |
| 3.1.1 | 142 | 8/7/2026 |
| 3.1.0 | 112 | 8/6/2026 |
| 3.0.3 | 152 | 7/27/2026 |
| 3.0.2 | 114 | 7/26/2026 |