Search code examples
visual-studio-codesyntax-highlighting

How can I make a plugin for Vscode to change colors of a file type?


for example .xlp is my file type and name is code.xlp I want to highlight some code.

or some colors ?

Somethings like this Inno Setup For VS code


Solution

  • In case you don't want to write custom extension, try manual configuration of 'file association' for '.xlp' files. This will tell VS Code to highlight content of '.xlp' files as language of your choice.

    For example, I set it to C# and it looks like this: enter image description here

    Steps for this configuration:

    1. Inside of '.xlp' file press ctrl + P to open navigation field,
    2. Search for >Change Language Mode,
    3. Choose Configure File Association for '.xlp',
    4. From dropdown list choose language you like.