Class FormatOptions
FormatOptions for Lino notation formatting. Provides configuration options for controlling how Link objects are formatted.
Inherited Members
Namespace: Link.Foundation.Links.Notation
Assembly: Link.Foundation.Links.Notation.dll
Syntax
public class FormatOptions
Properties
| Edit this page View SourceGroupConsecutive
If true, group consecutive links with same ID (default: false)
Declaration
public bool GroupConsecutive { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
IndentLongLines
If true, indent lines exceeding MaxLineLength (default: false)
Declaration
public bool IndentLongLines { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
IndentString
String to use for indentation (default: " " = two spaces)
Declaration
public string IndentString { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
LessParentheses
If true, omit parentheses where safe (default: false)
Declaration
public bool LessParentheses { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
MaxInlineRefs
Maximum number of references before auto-indenting (default: null = unlimited)
Declaration
public int? MaxInlineRefs { get; set; }
Property Value
| Type | Description |
|---|---|
| int? |
MaxLineLength
Maximum line length before auto-indenting (default: 80)
Declaration
public int MaxLineLength { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
PreferInline
If true, prefer inline format when under thresholds (default: true)
Declaration
public bool PreferInline { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
Methods
| Edit this page View SourceShouldIndentByLength(string)
Check if line should be indented based on length
Declaration
public bool ShouldIndentByLength(string line)
Parameters
| Type | Name | Description |
|---|---|---|
| string | line | The line to check |
Returns
| Type | Description |
|---|---|
| bool | True if line should be indented based on length threshold |
ShouldIndentByRefCount(int)
Check if link should be indented based on reference count
Declaration
public bool ShouldIndentByRefCount(int refCount)
Parameters
| Type | Name | Description |
|---|---|---|
| int | refCount | Number of references in the link |
Returns
| Type | Description |
|---|---|
| bool | True if link should be indented based on reference count threshold |