Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
495b7b7a07 | ||
|
|
8b39c4d250 | ||
|
|
49e8cdd7df |
@@ -17,7 +17,3 @@
|
|||||||
## [2026.6.100]
|
## [2026.6.100]
|
||||||
|
|
||||||
- Fix several bugs
|
- Fix several bugs
|
||||||
|
|
||||||
## [2026.6.200]
|
|
||||||
|
|
||||||
- Fix foramtting bug
|
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@
|
|||||||
"name": "nx-post-support",
|
"name": "nx-post-support",
|
||||||
"displayName": "NX Postprocessor Support",
|
"displayName": "NX Postprocessor Support",
|
||||||
"description": "VS Code extension for NX CAM postprocessor development with syntax highlighting, formatting, linting, and auto-completion for CDL, TCL, and DEF files",
|
"description": "VS Code extension for NX CAM postprocessor development with syntax highlighting, formatting, linting, and auto-completion for CDL, TCL, and DEF files",
|
||||||
"version": "2025.9.200",
|
"version": "2026.6.0",
|
||||||
"publisher": "Christoph",
|
"publisher": "Christoph",
|
||||||
"icon": "images/nx-1.png",
|
"icon": "images/nx-1.png",
|
||||||
"extensionDependencies": [
|
"extensionDependencies": [
|
||||||
|
|||||||
@@ -98,12 +98,8 @@ class TclLanguageServer(server.LanguageServer):
|
|||||||
FormatterOpts(
|
FormatterOpts(
|
||||||
indent=indent,
|
indent=indent,
|
||||||
spaces_in_braces=False,
|
spaces_in_braces=False,
|
||||||
balanced_spaces_in_braces=False,
|
|
||||||
max_blank_lines=500,
|
max_blank_lines=500,
|
||||||
indent_namespace_eval=True,
|
indent_namespace_eval=True,
|
||||||
indent_mixed_tab_size=0,
|
|
||||||
emacs=False,
|
|
||||||
debug_whitespace=False,
|
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -26,8 +26,6 @@ class NxFormatter(BaseFormatter):
|
|||||||
formatted += [line]
|
formatted += [line]
|
||||||
|
|
||||||
if expr.pos[0] == expr.end_pos[0]:
|
if expr.pos[0] == expr.end_pos[0]:
|
||||||
space_before = expr.children[0].pos[1] - expr.pos[1] - 1
|
return self._brace(formatted)
|
||||||
space_after = expr.end_pos[1] - expr.children[-1].end_pos[1] - 1
|
|
||||||
return self._brace(formatted, (space_before, space_after))
|
|
||||||
|
|
||||||
return ["{"] + self._indent(formatted, self.opts.indent) + ["}"]
|
return ["{"] + self._indent(formatted, self.opts.indent) + ["}"]
|
||||||
|
|||||||
Reference in New Issue
Block a user