How can I enable auto complete support in Notepad++?

AutocompleteSyntax HighlightingNotepad++

Autocomplete Problem Overview


I am trying to add simple syntax highlighting and auto completion for a simple scripting language...

I added syntax highlighting using this article

Now I want to know how to enable auto completion with Notepad ++ for my custom language. Does anyone know how to do that?

Autocomplete Solutions


Solution 1 - Autocomplete

The link provided by Mark no longer works, but you can go to:

Notpad++ 6.6.9

  • Settings -> Preferences -> Auto-Completion -> Enable auto-completion on each input.

    I find it very annoying though, since a big autocomplete block is always coming up and I would just like to see autocomplete when I press tab or a key combination. I am fairly new to Notepad++ though. If you know of such a key combination, please feel free to reply. I found this question via Google, so we can always help others.enter image description here

Solution 2 - Autocomplete

For basic autocompletion, have a look at the files in %ProgramFiles%\Notepad++\plugins\APIs. It's basically just an XML file with keywords in. If you want calltips ("function parameters hint"), check out these instructions.

I've never found any more documentation, but cpp.xml has a calltip for fopen, while php.xml is quite complete.

Solution 3 - Autocomplete

Go to

> Settings -> Preferences -> Backup/Autocompletion

  • Check Enable auto-completion on each input. By default the radio button for Function completion gets checked, that will complete related function name as you type. But when you are editing something other than code, you can check for Word completion.

  • Check Function parameters hint on input, if you find it difficult to remember function parameters and their ordering.

Solution 4 - Autocomplete

Autocomplete in Notepad++ is as simple as hitting Ctrl + Enter or Ctrl + Space in the interface.

Ctrl + Enter - as simple as that!

This, for many people, will be better than autocompleting on everything.

Solution 5 - Autocomplete

Don't forget to add your libraries & check your versions. Good information is in Using Notepad Plus Plus as a script editor.

Solution 6 - Autocomplete

You can also add your own suggestion.

Open this path:

C:\Program Files\Notepad++\plugins\APIs

And open the XML file of the language, such as php.xml. Here suppose, you would like to add addcslashes, so just add this XML code.

<KeyWord name="addcslashes" func="yes">
    <Overload retVal="void">
        <Param name="void"/>
    </Overload>
</KeyWord>

Solution 7 - Autocomplete

It is very easy:

  1. Find the XML file with unity keywords
  2. Copy only lines with "< KeyWord name="......" / > "
  3. Go to C:\Program Files\Notepad++\plugins\APIs and find cs.xml for example
  4. Paste what you copied in 1., but be careful: Don't delete any line of it cs.xml
  5. Save the file and enjoy autocompleting :)

Solution 8 - Autocomplete

Open Notepad++ and Settings -> Preferences -> Auto-Completion -> Check the Auto-insert options you want. this link will help alot: http://docs.notepad-plus-plus.org/index.php/Auto_Completion

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionChathuranga ChandrasekaraView Question on Stackoverflow
Solution 1 - AutocompleteDennisView Answer on Stackoverflow
Solution 2 - AutocompleteMarkView Answer on Stackoverflow
Solution 3 - Autocompleteuser1680049View Answer on Stackoverflow
Solution 4 - AutocompleteDave HilditchView Answer on Stackoverflow
Solution 5 - AutocompleteBrady ChoateView Answer on Stackoverflow
Solution 6 - AutocompleteRinkuView Answer on Stackoverflow
Solution 7 - AutocompleteT. MollovView Answer on Stackoverflow
Solution 8 - AutocompleteAnojView Answer on Stackoverflow