Sign in Join
FPDoc Onlineexperiment

THTML2TextRenderer.Create constructor

Member of THTML2TextRendererpublicIn unit HTML2TextRender

Constructor for the class instance.

Declaration

pascal
constructor Create(const aHTML: string)
constructor Create(const Stream: TStream)

Description

Create is the overloaded constructor for the class instance. HTML content is passed as an argument to the method using either a String value or a TStream instance. The Stream-based variant reads the content in Stream into a String variable for processing. The position in the stream is not changed prior to or after reading its content.

Create stores the HTML content in aHTML to an internal member used when parsing and processing using methods in the class. A UTF-8 Byte Order Mark (BOM) at the start of the HTML content is removed prior to processing.

Create sets the default values for the following properties:

LineEndMark
Set to the value in the LineEnding constant for the platform or OS.
TitleMark
Set to the UTF-8 character '◈' (#9672 or #x25C8)
HorzLineMark
Set to the UTF-8 characters '——————————————————'.
LinkBeginMark
Set to the character '_'.
LinkEndMark
Set to the character '_'.
ListItemMark
Set to the UTF-8 characters '✶ ' (Hex #$2736).
MoreMark
Set to the characters '...' (Three Period characters - not an Ellipsis character).
IndentStep
Set to 2.

An experiment, built from Lazarus main 2dfa93c66e of 10-22-2026. Not the official Lazarus documentation.