Sublime Text 2 - View whitespace characters

imkost picture imkost · Apr 14, 2012 · Viewed 227.7k times · Source

How can Sublime Text show non printable characters (I'm interested in SPACEs and TABs)?

Answer

Andrew Barrett picture Andrew Barrett · Apr 14, 2012

To view whitespace the setting is:

// Set to "none" to turn off drawing white space, "selection" to draw only the
// white space within the selection, and "all" to draw all white space
"draw_white_space": "selection",

You can see it if you go into Preferences->Settings Default. If you edit your user settings (Preferences->Settings - User) and add the line as per below, you should get what you want:

{
    "color_scheme": "Packages/Color Scheme - Default/Slush & Poppies.tmTheme",
    "font_size": 10,
    "draw_white_space": "all"
}

Remember the settings are JSON so no trailing commas.