Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>TOPAS Diffraction Language SupportNew to Visual Studio Code? Get it now.
TOPAS Diffraction Language Support

TOPAS Diffraction Language Support

Dayton Kizzire

|
40 installs
| (0) | Free
TOPAS Language Support
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

TOPAS Language Support for VS Code

This extension provides syntax highlighting, language support, and basic features for the TOPAS language, commonly used in crystallography and material science, directly within Visual Studio Code.

Features

  • Syntax highlighting for .inp, .out, .inc, and .str files.
  • Highlighting support for:
    • Keywords
    • Functions
    • Variables
    • Operators
    • Comments
    • Local Macros

File Types Supported

  • .inp: Input files for TOPAS
  • .out: Output files generated by TOPAS
  • .inc: Include files for additional macros
  • .str: TOPAS structure files

Future Updates - Works in Progress

  • Snippets: insertable common code blocks for constructing TOPAS input files, similar to the old JEdit Xinsert plugin.
  • Import CIF: parse CIF files and format data for running in TOPAS
  • Send to TOPAS: Launch TOPAS from VS Code and load active .inp file for refinement.

Installation

  1. Download and install the extension from the Visual Studio Code Marketplace.
  2. Once installed, the extension will automatically apply to .inp, .out, and .inc files.

Usage

Syntax Highlighting

Open any .inp, .out, .inc, or .str file to see the syntax highlighting applied. The following elements are highlighted:

  • Comments: Block and line comments are highlighted.
  • Keywords: Common TOPAS control keywords are supported, such as prm, local, global, etc.
  • Functions: Functions like Abs, Sin, Cos, etc., are highlighted.
  • Operators: All mathematical and logical operators are supported.
  • Macros: Macros defined with the macro keyword will be highlighted.

Contributing

Feel free to contribute by reporting issues or suggesting features. You can clone the repository and submit a pull request on GitHub.

Release Notes

1.2.0

  • Initial release with syntax highlighting for .inp, .out, .inc, and .str files.

Enjoy using TOPAS Language Support in VS Code!

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft