Method GetFormattingEditsForRange
- Namespace
- Alternet.Syntax.Parsers.TypeScript.CodeCompletion
- Assembly
- Alternet.Syntax.Parsers.TypeScript.v9.dll
GetFormattingEditsForRange(int, int, bool, int, bool, out string)
Gets the text changes for the part of document accordingly to the formatting rules.
public virtual IEnumerable<TextChange> GetFormattingEditsForRange(int start, int end, bool useSpaces, int spacesInTab, bool applyChanges, out string newText)
Parameters
start
intStart position of code being formatted.
end
intEnd position of code being formatted.
useSpaces
boolIndicates whether indentation string should contain spaces or tabs.
spacesInTab
intSpecifies number of spaces in tab.
applyChanges
boolForces to apply found changes to the new text.
newText
stringReceives formatted code.
Returns
- IEnumerable<TextChange>
List of TextChange representing a difference between old and new text.