Just want to say a BIG thank you to Mark Sarson et ali for their VS Code extension for Clarion.
I had some code that was very badly formatted, effectively making it unreadable and I spent some time with Claude and ChatGPT trying to get it formatted so I could make sense of it. The code was a couple of thousand lines, split across multiple embed points and both the AI tools barfed at the size.
Then I found the above extension and it formatted the code in less than a second!
I have an honest question - why would you want to use VS Code w/ Clarion instead of the integrated system of the IDE? It seems you would want as tight as a cou0ling of the editor and the IDE? - Just asking to see if I am missing something that would radically change how I use Clarion. Only about 10% of my work is hand-coding source (i.e. classes) the rest is using the IDE and embededitor.
Thank you for your question—your not the first to ask this question, some of my thoughts are below.
You’re right: for many Clarion developers, especially those who primarily use the AppGen and embed editor, the integrated IDE provides a streamlined and efficient workflow. If 90% of your work involves using the IDE and only 10% is hand-coding, it’s understandable that the existing tools meet your needs.
However, for developers who engage more extensively in hand-coding—such as writing classes, utility modules, or integrating with external systems—the traditional Clarion IDE can present some limitations. This is where the Clarion Extension for Visual Studio Code (VS Code) offers significant advantages:
Enhanced Navigation and Code Understanding
Improved “Go to Definition”: The extension provides advanced navigation capabilities, allowing you to jump directly to INCLUDE and MODULE references, even across redirected folders. This feature is particularly beneficial when working with large codebases or multiple modules.
Solution Tree View: You can view and explore your Clarion solution, including all .cwproj projects and source files, directly from the sidebar, making it easier to manage complex projects.
Modern Editing Features
Code Folding and Document Symbols: The extension offers structural code folding based on a Clarion-aware tokenizer, as well as improved navigation in the Outline and Breadcrumb bar, supporting classes, methods, procedures, and UI structures like WINDOW, MENUBAR, and TOOLBAR.
Hover Support and COLOR Inspector: Hovering over includes, modules, and other references provides contextual information, and the new COLOR inspector allows you to preview colors and view RGB/constant values interactively.
Integration with Modern Development Tools
Version Control: VS Code has built-in support for Git and other version control systems, enabling seamless integration into modern development workflows.
Extensibility: VS Code’s extensive marketplace allows you to customize your development environment with a wide range of extensions, enhancing productivity and enabling integration with various tools and services.
Cross-Platform and Performance Benefits
Lightweight and Fast: VS Code is known for its speed and responsiveness, providing a smooth editing experience even in large projects.
Cross-Platform Support: Unlike the traditional Clarion IDE, which is Windows-only, VS Code runs on Windows, macOS, and Linux, offering greater flexibility for diverse development environments. Although not providing abelites to compile projects or the solution in non windows environments
In summary, while the integrated Clarion IDE is well-suited for template-based development and embed editing, the Clarion Extension for VS Code brings modern editing capabilities, improved navigation, and integration with contemporary development tools. It’s particularly beneficial for developers who engage in significant hand-coding or manage large and complex codebases.
I hope this provides some insight into my opinion. Others will of course have their own preferences about using a modern editor—even without an extension like mine. Features like multiple cursors, powerful search across large codebases, split views, keyboard shortcuts, and flexible theming can make a big difference to some workflows, especially during heavy hand-coding or refactoring.
Watch this Clarion Live video to see Clarion code edited in VS Code and some of its features. What I liked was it sort of has its own local repository (timeline) making it easy to do a compare and see source code changes you made, then optionally roll them back.
The VS Code Timeline is a feature that provides a point-by-point history of changes to individual files inside your project. It allows developers to see when files were modified, committed, or saved, efficiently tracking the evolution of code over time.
Webinar 722 - Wengel Latham - Using Clarion with VS Code!
Watching the video is so much easier than reading about how it works.
At the time that episode was recorded, Wengle was using a much older version of the VS Code Clarion extension. Many of the features now available weren’t present in that version.
I have never edited templates or classes in the IDE. I have always used external editors for it, EditPlus for longer than I can remember, and more recently also VisualCode. The IDE editor does not have options like column selection that EP has done for 20 years or more. In fact, I often copy code out of the IDE embeds to work on them in EP and then paste back in.
Two things are important to me in the Clarion IDE editor. These are contextual help and snippets. My snippets consist of two parts. The first part is fixed, common to all projects. The second part is automatically generated when building the project based on the contents of the dictionary. In my project management application, there is a button on the toolbar, when clicked, the two parts are combined and can be used in the code editor. In the same way, we can switch snippets between different projects.