A new feature of the VS Code extension arrives with 4D V20 R2: code formatting!
In this blog post, we will delve into the details of this new functionality, exploring how it simplifies your programming experience.
When using the VS Code to edit 4D methods or classes, you may have noticed that the code was not formatted like in 4D. Now you can format It the same way 4D does! And the VS Code extension behaves in the same way as other languages.
The first method is to format the entire edited method or class by right-clicking on the code pane and selecting the “Format document” menu item:
The second method consists in formatting a selected part of the code by right-clicking on the code pane and selecting the “Format Selection” menu item:
Code formatting concerns the character case of commands, keywords and constants, as well as indentation, separator spaces, and so on. Note that the indentation unit uses the related VS Code setting.
We constantly strive to provide our users with the best possible experience, and we encourage you to share your thoughts and feedback on the 4D forum. Your feedback helps us better understand your needs and continuously improve our products and services.