Notepad ++ stopped the color coding of my source code ... How to fix it?

For no apparent reason, he just stopped. More color coding. Is there a secret setting that I accidentally turned off?

+10
notepad ++ ide
source share
17 answers

I had the same problem, and I found that this was because I turned on the global foreground color in the Global Styles section.

+23
source share

Try the following:

  • Select a language manually in the Languages ​​menu.
  • In Settings / Preferences, check file associations.
  • In the worst case, reinstall.
+9
source share

From the Language menu, select the appropriate language. For example H and then html

+7
source share

The solution for me was to enter the styles configurator, select "Global styles" in the language selection window and uncheck "Enable global foreground color". I'm not sure why this was checked, but all the paint of the code worked after unchecking the box. Thanks Richard!

+5
source share

Look in the settings β†’ Style Configurator. Maybe your styles are somehow messed up. You can try to change the selected style to find out does not matter.

I think that the saved styles are stored in the themes directory in the Notepad ++ installation directory, so you can also check that the files are somehow not corrupted.

+3
source share

I had the same problem (I Googled "notepad ++ file coloring quit" to find this discussion.) In my case, the coloring completes in the middle of the file in one file. Finally, I realized that adjacent string literals with one of these macros trick Notepad ++. My code that interrupted it read: Write_Supplemental_Configuration (privateData-> new_config, FTP_ROOT_DIR "/lists.csv"); and the fix was to add a space after the macro: Write_Supplemental_Configuration (privateData-> new_config, FTP_ROOT_DIR "/lists.csv");

I tried replacing the FTP_ROOT_DIR macro with "foo" and the problem disappeared.

So, in my case, it was a macro that fooled the coloring of Notepad ++.

+1
source share

keep track of the only quote you copy from the internet. if you get one of these "upper commas" instead of the tic character, this will confuse the code and kill the coloring (in SQL). just remove and replace.

+1
source share

Make sure that when you save the file, it is saved as .html instead of .txt . This matters because .html allows you to see different color codes, while .txt does not work.

0
source share
  • Check if you saved documents as .HTML and not as .txt
  • in the menu, select "Settings"> "Style Configurator" ... and in the list in the left pane, select html, check if colors for different tags are displayed in color blocks. if so, try the font and then save and exit.

  • Check only after saving the document in .html, regardless of whether it works or not.

0
source share

Setting the language solved the problem for (all) 3 Javascript files (.js) that suffered from it, which previously were all correctly recognized as Javascript. For some reason, he forgot that they were Javascript files, apparently !?

0
source share

First enter any thing and save the file in any format that you work with (i.e.; .cpp if C ++ ,. js if JavaScript .... etc)

And make sure the global foreground color is off.

And it should work fine.

0
source share

File> Save As> Format Type = Structured Query Language> Name the file using * * .sql. THIS SHOULD RECEIVE ALL COLOR CODES ..... differentiate your code and make it beautiful. J

0
source share

If you want to display text in SQL format, select "Language => S => SQL from the menu

0
source share

It just happened to me the same thing. The only way to fix this is to rename the file (I just added one character). Then open it with notepad ++. The code was painted again. Then rename the file back to its original name and it is still colored.

Since then, I have found that if I close notepad ++ without first closing the file, this will happen. Try closing the file first, then closing notepad ++, and then opening the file again.

0
source share

Go to Settings β†’ Style Settings and uncheck the global style box.

Setting

0
source share

If the coloring stops working for only one file, you should check your file extension. You may have accidentally saved the file as .txt

-one
source share

A few years later, but I'm sure you open the ".txt" files containing your source code. Since there is no language extension in the file, Notepad ++ cannot determine how by its color code. You will need to select the language on the "Language" tab.

-one
source share

All Articles