Serhioromano / vscode-st

Extension for VS Code to support Structured Text language.
https://marketplace.visualstudio.com/items?itemName=Serhioromano.vscode-st#overview
MIT License
141 stars 28 forks source link

Formatter adds spaces at the wrong places #46

Closed AndersHogqvist closed 1 year ago

AndersHogqvist commented 1 year ago

When formatting a file spaces are added where they shouldn't be added. A couple of examples:

Before a comment block (* bla bla *) becomes <space>(* bla bla *)

Before and after ':=' and ':' when they are surrounded by tabs as well as after comments at end of a line When you have something like this with tabs after the variable, :, type and :=: VARIABLE_X<tab>: DINT := 0; (* comment *) becomes VARIABLE_X<tab><space>: DINT := 0; (* comment *)<space>

Serhioromano commented 1 year ago

Thank you for report. I how treat tabs as spaces for all symbols. And I also trim the end of all lines. Please check new version 1.12.11