TxtLoadOptions.DetectNumberingWithWhitespaces

TxtLoadOptions DetectNumberingWithWhitespaces property. Allows to specify how numbered list items are recognized when document is imported from plain text format. The default value is true.

TxtLoadOptions.DetectNumberingWithWhitespaces property

Allows to specify how numbered list items are recognized when document is imported from plain text format. The default value is true.

public bool DetectNumberingWithWhitespaces { get; set; }

Remarks

If this option is set to false, lists recognition algorithm detects list paragraphs, when list numbers ends with either dot, right bracket or bullet symbols (such as “•”, “*”, “-” or “o”).

If this option is set to true, whitespaces are also used as list number delimiters: list recognition algorithm for Arabic style numbering (1., 1.1.2.) uses both whitespaces and dot (".") symbols.

Examples

Shows how to disable detecting numbering with white spaces.

TxtLoadOptions txtLoadOptions = new TxtLoadOptions();
txtLoadOptions.DetectNumberingWithWhitespaces = false;

Converter.Create()
    .From(MyDir + "Simple.txt", txtLoadOptions)
    .To(ArtifactsDir + "TxtLoadOptions.DetectNumberingWithWhitespaces.docx")
    .Execute();

See Also