0

If I open a text file in Notepad++ it defaults to formatting some elements such as numbers, text between apostrophes, backslashes etc.

How to I tell N++ to display .txt files with none of this formatting?

2
  • *text files (not test files as originally titled)
    – pelms
    May 12, 2016 at 15:12
  • Hmm. For me .txt files open without any special formatting ...
    – DavidPostill
    May 12, 2016 at 17:08

2 Answers 2

1

Run it from the command-line as such:

notepad++ -ltext [filename]

Or from the menu: Language, N, Normal Text.

That's lower-case L in "-ltext" by the way.

Update: To make it work by double-clicking on the file in Windows Explorer, put the above in a batch file as such (call the file, say, C:\OpenTxt.bat):

C:\full\path\to\notepad++ -ltext %1

Then in Windows Explorer, right-click on any .txt file, choose Open With then Choose default program, Browse, choose your C:\OpenTxt.bat and check Always use the selected program to open this kind of file. Then OK.

1
  • Thanks @JimB. I was really looking for a way to set the styling for all .txt files when they're opened with a double click without having to run a command each time though
    – pelms
    May 12, 2016 at 15:14
0

I think you are like me, prefer to view txt files as a plain text even if they have some codes in them. IF so, then I think I will tell you what I did and it might be what you need.

The only thing I did was overriding the format style under the Style Configurator, and used Global override settings to override the style settings on any file type that is not assigned to the Notepad++ along with text files. Thus, these files will always opened in Notepad++ as plain text with no formatting.

Here is the instructions :

  • Open Notepad++
  • Go to Settings and choose Style Configurator.
  • Under Global Styles: Global override, set the Colour Style, Font Style that you want.
  • Tick Enable global foreground colour. (This is the font color)
  • Tick Enable global background colour. (This is the page color).
  • Tick Enable global font.
  • Tick Enable global font size.
  • Tick Enable global bold font style.
  • Tick Enable global italic font style.
  • Tick Enable global underline font style.
  • When you're finished, click Save & Close.

Background color is optional, but if you use a customized theme, you can use the background color if you want to. I use Obsidian theme, and I changed the background color from blackish color to white. This will make all plain text with a white background, while other files with blackish color.

NOTE: if you use a customized theme or change your theme, you have to repeat the same steps above on the new theme.

You must log in to answer this question.

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