The pattern book
File
Charset
Section titled “Charset”charset = utf-8Selects the encoding used when DressSharp writes the file.
- Values:
latin1utf-8utf-8-bomutf-16beutf-16le - Default:
utf-8 - Applies to: File representation or shared layout settings.
- Guarantee: The configured value is applied by its owning formatter stage.
class Example{ string Text = "DressSharp";}Code unchanged.
Encoding utf-8 · Line endings CRLF · Final newline no
Code unchanged.
Encoding latin1 · Line endings CRLF · Final newline no
Code unchanged.
Encoding utf-8-bom · Line endings CRLF · Final newline no
Code unchanged.
Encoding utf-16be · Line endings CRLF · Final newline no
Code unchanged.
Encoding utf-16le · Line endings CRLF · Final newline no
End of line
Section titled “End of line”end_of_line = unsetSelects the line-ending sequence used when DressSharp writes the file.
- Values:
crlfcrlf - Default:
unset(the rule makes no change unless you set it) - Applies to: File representation or shared layout settings.
- Guarantee: The configured value is applied by its owning formatter stage.
class Example{ string Text = "DressSharp";}Code unchanged.
Encoding utf-8 · Line endings CR · Final newline no
Code unchanged.
Encoding utf-8 · Line endings LF · Final newline no
Code unchanged.
Encoding utf-8 · Line endings CRLF · Final newline no
Insert final newline
Section titled “Insert final newline”insert_final_newline = trueControls whether the written file ends with a newline.
- Values:
truefalse - Default:
true - Applies to: File representation or shared layout settings.
- Guarantee: The configured value is applied by its owning formatter stage.
class Example{ string Text = "DressSharp";}class Example{ string Text = "DressSharp";}
Encoding utf-8 · Line endings CRLF · Final newline yes
Code unchanged.
Encoding utf-8 · Line endings CRLF · Final newline no
Trim trailing whitespace
Section titled “Trim trailing whitespace”trim_trailing_whitespace = trueControls whether trailing line whitespace is removed.
- Values:
truefalse - Default:
true - Applies to: File representation or shared layout settings.
- Guarantee: The configured value is applied by its owning formatter stage.
class Example { }class Example { }class Example { }Encoding utf-8 · Line endings LF · Final newline yes
Code unchanged.
Encoding utf-8 · Line endings LF · Final newline yes