7

I want to auto indent my text using Notepad++. Is there a way to do this? Or do I have to install any plugin?

I have tried all I know in Notepad++, but it seems things are not working. I have even used the shortcut key Ctrl + F, but that works fine in Eclipse, but Notepad++ gives a find textbox instead.

1

4 Answers 4

5

I want to auto indent my text using Notepad++. Is there a way to do this?

You need to enable "Auto-indent".

Prior prior to v7.8.3:

  • "Settings" > "Preferences > "MISC." > tick "Auto-indent" then press "Close"

    enter image description here

Later versions:

  • Settings "Settings" > "Preferences > "Auto-Completion" > tick "Auto-indent" then press "Close"

    enter image description here

2
  • @ThinhNV It has moved to the Auto-Completion settings page
    – DavidPostill
    May 26, 2020 at 17:45
  • 1
    @Phlucious It has moved to the Auto-Completion settings page
    – DavidPostill
    May 26, 2020 at 17:45
2

You can use a plugin (IndentByFold).
You can either get it by going to

Plugins -> Plugins Admin

or from GitHub: IndentByFold.

0

I type some code, select it and then use:

menu TextFXTextFX EditReindent C++ code.

TextFX should be installed by default.

1
  • thanks very much, but I used Plugins > Indent By Fold > Reindent file. There was no need to select a particular portion. It indents the whole file. If notepad++ doesn't have this plugin by default, one will have to download it Jul 24, 2015 at 10:10
0

Auto-indent stopped working for a bit when I accidentally started recording a macro. I stopped it by clicking the "stop recording" button at the end of the toolbar.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .