PdfOutlineItem Class

An item of the document outline, a bookmark (ISO 32000-2, 12.3.3).

public sealed class PdfOutlineItem

Constructors

NameDescription
PdfOutlineItem(string, PdfDestination?)Initializes a new instance of the PdfOutlineItem class.

PdfOutlineItem(string, PdfDestination?)

PdfOutlineItem.cs

Initializes a new instance of the PdfOutlineItem class.

public PdfOutlineItem(string title, PdfDestination? destination = null)

Parameters

title string
The text of the item.
destination PdfDestination?
The destination, or null.

Properties

NameDescription
ChildrenGets the children of the item.
ColorGets or sets the color of the text (PDF 1.4), or null for black. It must be an RGB color.
DestinationGets or sets the destination, or null when the item has none or has an action of another kind.
IsBoldGets or sets a value indicating whether the text is bold (PDF 1.4).
IsItalicGets or sets a value indicating whether the text is italic (PDF 1.4).
IsOpenGets or sets a value indicating whether the children of the item are shown when the document is opened.
TitleGets or sets the text of the item.

Gets the children of the item.

public PdfOutlineCollection Children { get; }

Property value

PdfOutlineCollection

Gets or sets the color of the text (PDF 1.4), or null for black. It must be an RGB color.

public PdfColor? Color { get; set; }

Property value

PdfColor?

Exceptions

ArgumentException
The color is not an RGB color.

Gets or sets the destination, or null when the item has none or has an action of another kind.

public PdfDestination? Destination { get; set; }

Property value

PdfDestination?

Gets or sets a value indicating whether the text is bold (PDF 1.4).

public bool IsBold { get; set; }

Property value

bool

Gets or sets a value indicating whether the text is italic (PDF 1.4).

public bool IsItalic { get; set; }

Property value

bool

Gets or sets a value indicating whether the children of the item are shown when the document is opened.

public bool IsOpen { get; set; }

Property value

bool

Gets or sets the text of the item.

public string Title { get; set; }

Property value

string