Associate file extensions to language in Notepad++

Software:
Notepad++ 7.8.6

If your writing code in languages that are based on a common language but their files names have an uncommon extension, for example, the 3D shading languages OSL, and HLSL, which are written in C syntax but have .osl and .hlsl, or .fx as file name extensions,
Notepad++ wont automatically recognize that the code in these files is actually C language and present their syntax properly.

To set Notepad++ to recognize specific file associations with a wanted language:

  1. Goto:
    Settings > Style Configurator:
    Annotation 2020-06-18 132154
  2. In the Style Configurator window:
    Select the wanted language in the language list on the left,
    And in the User ext. field, type a list of file extensions separated by spaces:
    These file extensions will be interpreted as the selected language.
    Annotation 2020-06-18 132359

 

Related:
Setup a GitHub to associate file extension with a  language
Display tabs in Notepad++

Notepad++ – Show White Space and TAB

Software:
Notepad++ 7.5.9

A lot of Python debugging frustration can be avoided by activating the ‘Show White Space and TAB’ option from the View > Show Symbol menu.

This view option displays yellow dots for White Spaces and yellow arrows for TAB indents in the script, and can save precious time locating places where the indentation is wrong.

Untitled-1.jpg