---
Product: Aspose.PDF
Platform: net
Page Type: reference
Canonical URL: https://reference.aspose.org/pdf/net/HtmlSaveOptions
---

# HtmlSaveOptions

## Overview

`HtmlSaveOptions` is a class in Aspose.PDF FOSS for .NET.
Inherits from: `UnifiedSaveOptions`.

Options for saving a PDF document as HTML.

This class provides 4 methods for working with HtmlSaveOptions objects in .NET programs.
Available methods include: `HtmlSaveOptions`.
All public members are accessible to any .NET application after installing the Aspose.PDF FOSS for .NET package.
Properties: `AdditionalMarginWidthInPoints`, `ApsIntermediateFileIfAny`, `BatchSize`, `CacheGlyphs`, `CloseResponse`, `CompressSvgGraphicsIfAny`, and 27 more.

## Properties

| Name | Type | Access | Description |
|------|------|--------|-------------|
| `AdditionalMarginWidthInPoints` | `int` | Read/Write | Extra width (PDF points) added to each page's right margin in the output HTML. |
| `BatchSize` | `int` | Read/Write | How many PDF pages are processed per output batch when SplitIntoPages is in effect. |
| `CompressSvgGraphicsIfAny` | `bool` | Read/Write | Compress SVG graphics if any are present. |
| `ConvertMarkedContentToLayers` | `bool` | Read/Write | Convert marked-content sections to HTML layers. |
| `DefaultFontName` | `string` | Read/Write | Default font name used when a glyph has no resolvable face. |
| `DocumentType` | `HtmlDocumentType` | Read/Write | HTML doc-type emitted by the writer. |
| `ExplicitListOfSavedPages` | `int[]` | Read/Write | 1-based page numbers to render. |
| `FixedLayout` | `bool` | Read/Write | Use fixed (absolute) layout when emitting text positions. |
| `FlowLayoutParagraphFullWidth` | `bool` | Read/Write | Make flow-layout paragraphs span the full page width. |
| `FontSources` | `Aspose.Pdf.Text.FontSourceCollection` | Read | Font sources consulted when embedding fonts in the HTML output. |
| `IgnoreResourceFontErrors` | `bool` | Read/Write | Suppress font-resource errors at conversion time and substitute. |
| `IgnoredTextFontSize` | `System.Nullable` | Read/Write | Glyphs whose font size is at or below this value are dropped from the output. |
| `ImageResolution` | `int` | Read/Write | DPI used when rasterising vector or font content. |
| `MinimalLineWidth` | `float` | Read/Write | Minimum stroke width below which lines are widened. |
| `PreventGlyphsGrouping` | `bool` | Read/Write | If true, glyphs are emitted individually rather than grouped into runs. |
| `RenderTextAsImage` | `bool` | Read/Write | Render text fragments as raster images instead of selectable text. |
| `SaveFullFont` | `bool` | Read/Write | Embed full font tables instead of subsetting. |
| `SimpleTextboxModeGrouping` | `bool` | Read/Write | Group adjacent glyphs into a single text-box for a cleaner DOM. |
| `SplitCssIntoPages` | `bool` | Read/Write | When SplitIntoPages is true, also split the CSS per page. |
| `SplitIntoPages` | `bool` | Read/Write | Emit one HTML file per page instead of a single concatenated document. |
| `Title` | `string` | Read/Write | HTML &lt;title&gt; element. |
| `PngIntermediateFileIfAny` | `string` | Read/Write | Path to a PNG intermediate file (debug artifact, parity with HtmlLoadOptions.ApsIntermediateFileIfAny / XpsIntermediateFileIfAny). |
| `XpsIntermediateFileIfAny` | `string` | Read/Write | Path to an XPS intermediate file (debug artifact). |
| `ApsIntermediateFileIfAny` | `string` | Read/Write | Path to an APS intermediate file (debug artifact). |
| `TryMergeFragments` | `bool` | Read/Write | Merge adjacent text fragments into a single run when possible. |
| `UseZOrder` | `bool` | Read/Write | Honour z-order of overlapping content when emitting HTML. |
| `ExtractOcrSublayerOnly` | `bool` | Read/Write | Gets or sets the extract ocr sublayer only. |
| `CloseResponse` | `bool` | Read/Write | Gets or sets the close response. |
| `SaveFullPath` | `bool` | Read/Write | Gets or sets the save full path. |
| `WarningHandler` | `IWarningCallback` | Read/Write | Warning handler invoked during serialisation. |
| `WarningHandlerName` | `string` | Read/Write | Legacy string-typed warning-handler hook. |
| `CacheGlyphs` | `bool` | Read/Write | Pre-cache rasterised glyphs to speed up repeated text emission. |
| `SaveFormat` | `SaveFormat` | Read | The save format that this options instance configures. |

## Methods

| Signature | Description |
|-----------|-------------|
| `HtmlSaveOptions()` | Calls HtmlSaveOptions on this HtmlSaveOptions instance. |
| `HtmlSaveOptions(fixedLayout: bool)` | Calls HtmlSaveOptions(fixedLayout) on this HtmlSaveOptions instance. |
| `HtmlSaveOptions(documentType: HtmlDocumentType)` | Calls HtmlSaveOptions(documentType) on this HtmlSaveOptions instance. |
| `HtmlSaveOptions(documentType: HtmlDocumentType, fixedLayout: bool)` | Calls HtmlSaveOptions(documentType, fixedLayout) on this HtmlSaveOptions instance. |

## See Also

- [Aspose.PDF for .NET — Enterprise API Reference](https://reference.aspose.com/pdf/net/)