Home Download Buy Blog Forum Support

Show All Characters

Show All Characters

Postby sherriman on Wed Oct 21, 2009 9:39 am

Is there an option to "show all characters" and/or "show end of line characters"? I often need to see unprintable characters.

Thanks,
Scott
sherriman
 
Posts: 2
Joined: Sat Oct 17, 2009 2:07 am

Re: Show All Characters

Postby rick on Wed Oct 21, 2009 12:54 pm

drawWhiteSpace doesn't seem to display end of line and carriage return characters etc... is there a way to get them to appear?

Also, I'd like to view a file as hex, is this possible?

I like the look of Sublime and wanna ditch PSPad :D
rick
 
Posts: 1
Joined: Wed Oct 21, 2009 12:48 pm

Re: Show All Characters

Postby jps on Wed Oct 21, 2009 8:21 pm

It doesn't display end of line characters, no - my feeling is that it's pretty clear where the end of line characters are, and drawing them explicitly just gets messy.

There's no hex editing mode in Sublime Text.
jps
Site Admin
 
Posts: 3071
Joined: Wed Mar 19, 2008 12:33 pm

Re: Show All Characters

Postby GreyWyvern on Mon Nov 09, 2009 5:13 pm

I have set the user option "drawWhiteSpace none", however, when I make a multi-line selection, I still see a single selected whitespace added to the end of each line for the newline and/or carriage-return character. To me, this looks like a space has been added to the end of every line when selecting.

Often I will do a Ctrl+A to perform a quick visual check for unnecessary white-space at the end of lines, and this extra selected byte makes things a bit more difficult to do that. Normally I would assume that the "drawWhiteSpace none" option would hide selected newlines and carriage returns, but maybe it is tangled up with a different option which I am overlooking? Any help would be appreciated.

Liking Sublime more and more every day :) Cheers!
GreyWyvern
 
Posts: 106
Joined: Fri Oct 23, 2009 7:08 pm
Location: Canadia

Re: Show All Characters

Postby jps on Mon Nov 09, 2009 8:56 pm

Yeah, that's a bit of a compromise - if it didn't do that, it would be impossible to tell if an empty line was selected or not
jps
Site Admin
 
Posts: 3071
Joined: Wed Mar 19, 2008 12:33 pm

Re: Show All Characters

Postby GreyWyvern on Mon Nov 09, 2009 9:35 pm

Understandable. However, there is something to be said for seeing exactly what printable characters have been selected, no? This is the way Notepad and Metapad handle selection, and I'm just whining because that's the way I'm used to. ;) I never had trouble knowing which empty lines were selected as long as they were bordered by selection on either side, or the cursor was on the line below.

However, I do realise that because of multi selection in Sublime Text there would be the possibility of confusion. For example, two selections that otherwise look identical could possibly be selecting a different number of empty lines. Not sure how big of a problem this would be in practice, though; I don't often multi-select but when I do, I am usually well-aware of the extent of what I've selected.

Wordpad and Notepad++ also highlight the newlines in selections as in Sublime Text and likewise offer no way to turn off that behaviour. :shrug: So I guess I still suggest it, but not if it's a major coding change for you. I can live with it :)
GreyWyvern
 
Posts: 106
Joined: Fri Oct 23, 2009 7:08 pm
Location: Canadia

Re: Show All Characters

Postby jheiss on Wed Nov 16, 2011 3:46 pm

+1 for me too, particularly regarding displaying end-of-line so that I can visually catch extraneous trailing whitespace. Textmate has Show/Hide Invisibles, which displays a subtle little gray character at the end of each line. I always have that turned on and don't find it distracting.
jheiss
 
Posts: 5
Joined: Wed Nov 02, 2011 1:51 pm

Re: Show All Characters

Postby bizoo on Wed Nov 16, 2011 4:02 pm

jheiss wrote:+1 for me too, particularly regarding displaying end-of-line so that I can visually catch extraneous trailing whitespace. Textmate has Show/Hide Invisibles, which displays a subtle little gray character at the end of each line. I always have that turned on and don't find it distracting.

Base File.sublime-settings:
Code: Select all
   // 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",

ST2 display space and tab chars but not end-of-line chars, and IMHO is the right thing to do.
bizoo
 
Posts: 886
Joined: Wed Dec 08, 2010 6:53 am
Location: Switzerland

Re: Show All Characters

Postby colinta on Thu Dec 22, 2011 1:01 am

All those space characters get really cluttered... I think the "less is better" approach is good here. Compare SublimeText2 w/ TextMate's "Show Invisibles":

Image

Image

(please excuse the horrible colors in TextMate 2, the alpha release is ignoring my beautiful zenburn theme)

For completeness, here is what I think just looks spiffy:

Image
colinta
 
Posts: 14
Joined: Wed Dec 21, 2011 9:43 pm

Re: Show All Characters

Postby adzenith on Thu Dec 22, 2011 1:13 am

colinta wrote:For completeness, here is what I think just looks spiffy:

Image

If this existed I would use it everywhere. Plus then when you have a selection that selects the newline character it's really obvious what's going on.
adzenith
 
Posts: 1217
Joined: Mon Oct 19, 2009 9:12 pm

Next

Return to Technical Support

Who is online

Users browsing this forum: Google [Bot] and 29 guests