Preferences Keys

Formatting preferences are serialized as key-value pairs, by default under $HOME/.config/Code/User/settings.json.

Preference Name

Details

Preference Key

Default Value

Capitalization

Attributes

Controls the attributes capitalization: Leave as is (1), All upper case (2), All lower case (3).

DVT.textEditor.vHDL.formatting.capitalization.attributes

“Leave as is”

Data Types

Controls the data types capitalization: Leave as is, All upper case, All lower case.

DVT.textEditor.vHDL.formatting.capitalization.dataTypes

“Leave as is”

Keywords

Controls the keywords capitalization: Leave as is, All upper case, All lower case.

DVT.textEditor.vHDL.formatting.capitalization.keywords

“Leave as is”

Whitespace

Add Whitespace After

List of tokens after which whitespace will be added.

DVT.textEditor.vHDL.formatting.whitespace.addWhitespaceAfter

[]

Add Whitespace Before

List of tokens before which whitespace will be added.

DVT.textEditor.vHDL.formatting.whitespace.addWhitespaceBefore

[]

Compact Whitespace Groups

Controls whether to compact consecutive whitespace characters.

DVT.textEditor.vHDL.formatting.whitespace.compactWhitespaceGroups

false

Compact Consecutive Empty Lines

Controls whether to compact consecutive empty lines.

DVT.textEditor.vHDL.formatting.whitespace.compactConsecutiveEmptyLines

false

Maximum Number Of Consecutive Empty Lines

Maximum number of consecutive empty lines that can appear in a file.

DVT.textEditor.vHDL.formatting.whitespace.maximumNumberOfConsecutiveEmptyLines

1

Insert spaces

Insert spaces when pressing tab.

editor.insertSpaces

true

Tab width

Controls the size of a tab in spaces.

editor.tabSize

4

Trim End of Line Whitespace

Controls whether to trim end of line whitespaces.

DVT.textEditor.vHDL.formatting.whitespace.trimEndOfLineWhitespace

true

Trim Whitespace Lines

Controls whether to trim lines containing only whitespaces.

DVT.textEditor.vHDL.formatting.whitespace.trimWhitespaceLines

true

Indentation

Do Not Indent Single Line Comments At Beginning Of Line

Controls whether to indent single line comments starting at the beginning of a line.

DVT.textEditor.vHDL.formatting.indentation.doNotIndentSingleLineCommentsAtBeginningOfLine

true

Enable More Parameters Per Line If Less Than

Controls whether to place parameters on the same line when their number does not exceed a certain value and the Parameters preference is set to One per line (open parenthesis on the same line) or One per line (open parenthesis on the next line).

DVT.textEditor.vHDL.formatting.indentation.enableMoreParametersPerLineIfLessThan

false

Indent Multi Line Comments

Controls whether to indent multi-line comments.

DVT.textEditor.vHDL.formatting.indentation.indentMultiLineComments

true

Ignore Lines Starting With

List of line prefixes matching lines that will be ignored while indenting.

DVT.textEditor.vHDL.formatting.indentation.ignoreLinesStartingWith

[]

More Parameters Per Line If Less Than

Maximum number of parameters that can appear on a line when Enable More Parameters Per Line If Less Than is enabled.

DVT.textEditor.vHDL.formatting.indentation.moreParametersPerLineIfLessThan

5

No Indent Keywords

Selection of language keywords that will not increase indentation.

DVT.textEditor.vHDL.formatting.indentation.noIndentKeywords

{
  "architecture": false,
  "block": false,
  "case": false,
  "component": false,
  "configuration": false,
  "entity": false,
  "for": false,
  "function": false,
  "generate": false,
  "loop": false,
  "package": false,
  "process": false,
  "protected": false,
  "record": false
}

Parameters

Controls the placement of port, generic, map, function and procedure elements: Leave as is, One per line (open parenthesis on the same line), One per line (open parenthesis on the next line), More per line.

DVT.textEditor.vHDL.formatting.indentation.parameters

“Leave as is”

Then

Controls the placement of then: Leave as is, On a new line, On the same line.

DVT.textEditor.vHDL.formatting.indentation.then

“Leave as is”

Vertical Alignment

Enable Vertical Align

Controls whether to enable vertical alignment.

DVT.textEditor.vHDL.formatting.verticalAlignment.enableVerticalAlignment

false

Only Consecutive Lines

When enabled, only consecutive lines (lines that follow each other or are separated by comment lines) are vertically aligned.

DVT.textEditor.vHDL.formatting.verticalAlignment.onlyConsecutiveLines

false

Vertical Align Patterns

Vertically align code using patterns: Constant Declarations, Port Declarations, Record Declarations, Signal Declarations, Variable Declarations, Variable, Signal, Constant Declarations.

DVT.textEditor.vHDL.formatting.verticalAlignment.verticalAlignPatterns

{
  "Constant Declarations": false,
  "Port Declarations": false,
  "Record Declarations": false,
  "Signal Declarations": false,
  "Variable Declarations": false,
  "Variable, Signal, Constant Declarations": false
}

Vertical Align Single Line Comments

Controls whether single line comments are vertically aligned.

DVT.textEditor.vHDL.formatting.verticalAlignment.verticalAlignSingleLineComments

false

Vertical Align To Open Parenthesis

Controls whether to vertically align relative to open parenthesis.

DVT.textEditor.vHDL.formatting.verticalAlignment.verticalAlignToOpenParenthesis

false

Vertical Alignment Tokens

List of tokens used for splitting lines in the same scope in vertically aligned columns.

DVT.textEditor.vHDL.formatting.verticalAlignment.verticalAlignTokens

[":=", "<=", "=>"]

Line Wrapping

Enable Line Wrapping

Controls whether to enable line wrapping.

DVT.textEditor.vHDL.formatting.lineWrapping.enableLineWrapping

false

Line Width

Number of characters on a line after wrapping the line.

DVT.textEditor.vHDL.formatting.lineWrapping.lineWidth

80

Wrap Multi Line Comments

Controls whether multi-line comments are wrapped.

DVT.textEditor.vHDL.formatting.lineWrapping.wrapMultiLineComments

false

Wrap Single Line Comments

Controls whether single line comments are wrapped and moved above the code.

DVT.textEditor.vHDL.formatting.lineWrapping.wrapSingleLineComments

false