Ubuntu: Auto indent and pretty code by notepadqq



Question:

Before, in Windows, I used notepad++ and it has an option TextFX->Edit->Reindent C++ code for reformatting code. Now I use Ubuntu 14.0.4 so I use notepadqq as alternative for notepad++. How I can achieve a similar result in notepadqq?


Solution:1

Notepadqq doesn't have a auto-formatting code feature like the one in Notepad++. I recommend using SublimeText instead as an alternative. You can download it from their website https://www.sublimetext.com/3

There are plugins for autoformatting. One such plugin is SublimeAStyleFormatter. Install the plugin (Here is a guide how to do that). Once installed, you can autoformat C/C++ code by pressing Ctrl+K, Ctrl,F key combo.


Solution:2

From top menu : Language -> C++ (or whatever language you like).

You can also change indentation width from Settings -> Preferences -> Languages.

Edit : It doesn't have auto indentation though.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »