Using Notepad Plus Plus as a script editor

From Unify Community Wiki
Revision as of 05:46, 8 July 2011 by Igorrafael (Talk | contribs)

Jump to: navigation, search

Notepad++ is a powerful text editor based on Scintilla (which is where UniSciTE is also based from). It is available only in Windows.


  • it can manage more than ten text files opened simultaneously
  • customizable color scheme
Notepad++ editing a Unityscript file
Notepad++ editing a Unityscript file.



  1. Notepad++ can be found in Download and install.
  2. Change your External Script Editor to Notepad++ (In Unity, Edit> Preferences > General)
  3. Unity should now open Notepad++ whenever you double-click a script (or any text file actually).

How to add searching of Unity Documentation within Notepad++

  1. Download the Language Help Plugin via the Plugin Manager: Plugins > Plugin Manager > Show Plugin Manager. Then choose "Language Help" from the list, and click Install.
  2. Go to Plugins > Language Help > Options...
  3. Click Add and put these values
Name: Unity
Extension List: "js" (and/or "cs" if you're using C#)
Extended help file path:$word$

Now whenever you press ctrl+f1 while your cursor is on a word, it will search that word in the Unity documentation. (You can change the key binding via Settings > Shortcut Mapper)

How to enable highlighting of unity "keywords" within N++

  1. Open "C:\Program Files\Unity\Editor\Data\Tools\UniSciTE\" This text file contains all the unity keywords.
  2. In Notepad++ go to Settings > Style Configurator...
  3. In the "Language:" list, select your appropriate language.
  4. In the "Style:" list, select Keyword (or Instruction Word).
  5. Add the keywords from the file (the big block of text) into the "User-Defined Keywords" box.
  6. Save & Close. Close and open Notepad++. Voila.

How to enable highlighting of unity "keywords" manually

  1. Open "C:\Program Files\Unity\Editor\Data\Tools\UniSciTE\" This text file contains all the unity keywords.
  2. Open "C:\Program Files\Notepad++\stylers.xml" (If you're using a custom theme, open C:\Program Files\Notepad++\themes and open the theme XML file you are using instead.) NOTE: For Windows 7 the file is located in \users\yourusername\AppData\Roaming\Notepad++\stylers.xml
  3. In stylers.xml (or your theme's XML file), find: <LexerType name="javascript" desc="Javascript" ext="">
  4. Find the coressponding: <WordsStyle name="KEYWORD" styleID="47" fgColor="000080" bgColor="F2F4FF" fontName="" fontStyle="3" fontSize="" keywordClass="instre1">
  5. Insert all the unity keywords (found from the you opened earlier) inside that <WordsStyle name="KEYWORD"> tag
  6. Save it. Close and open Notepad++. It should highlight the Unity keywords now.

How to add Intellisense (called Auto-Completion in Notepad++) for Unityscript

  1. Turn on Auto-Completion by going to: Settings > Preferences > Backup/Auto-Completion. Check "Function parameters hint on input"
  2. Open "C:\Program Files\Notepad++\plugins\APIs\javascript.xml"
  3. Copy and paste contents of to anywhere inside the <AutoComplete> tags of the "javascript.xml" file. If you have trouble saving try running Notepad++ as an administrator.
  4. Close and open Notepad++. A function tooltip should now appear whenever you type in an open parenthesis after a Unity function.
  5. As of 3.3, the Javascript and C# api are the same so adding the same data to "cs.xml" should also work.

Note: UnityAPI_JS.xml is created from the file found as "C:\Program Files\Unity\Editor\Data\Tools\UniSciTE\UnityJS.api", using a program made by anomalous_underdog ( If ever the UnityJS.api changes again (in case of a Unity update), just run the python script.

How to make Notepad++ jump to the correct line number from the error console

  1. Back up the original UniSciTE.exe file
  2. Download the Windows Redirector For Notepad++ (Located at )
  3. Extract both files from the Zip file in #2 into the UniSciTE directory (Windows: C:\Program Files(86)\Unity\Editor\Data\Tools\UniSciTE )
  4. Set Unity3D to use the BUILT-IN Editor.
  5. Unity will now launch Notepad++ and jump to the correct line number when clicking an error message inside the Unity3D error console.
  • Also you most likely would need to change path from C:\Program Files(86)\Unity\Editor\Data\Tools\UniSciTE to C:\Program Files\Unity\Editor\Data\Tools\UniSciTE in wrapper.ini, that comes with UniSciTE redirecter for Notepad++ zip file.
Personal tools