Home Download Buy Blog Forum Support

Find and Replace special characters

Find and Replace special characters

Postby chodenode on Thu Feb 02, 2012 2:46 pm

Hi all,

How can I use the Find or Replace functions to replace tabs or carriage returns? I've searched through the forum and the documentation I could find but haven't found the answer I need. In other editors I've used, I can type "^t" to find tabs or "^p" to find carriage returns. What are the equivalents in Sublime? Are there similar strings to use for other control characters, as well?

While I'm at it, is there a plugin to do file comparisons to identify differences?

Thanks much.
chodenode
 
Posts: 2
Joined: Thu Feb 02, 2012 2:39 pm

Re: Find and Replace special characters

Postby facelessuser on Thu Feb 02, 2012 3:53 pm

Enable regex in the find panel.

Then you can use \t for tabs. \r for carriage returns. \n for newlines.
facelessuser
 
Posts: 1576
Joined: Tue Apr 05, 2011 7:38 pm

Re: Find and Replace special characters

Postby handycam on Thu Feb 02, 2012 3:53 pm

Mac OS 10.9.3
ST 3 (3059)
handycam
 
Posts: 271
Joined: Tue Jan 03, 2012 2:42 pm

Re: Find and Replace special characters

Postby chodenode on Thu Feb 02, 2012 3:56 pm

facelessuser wrote:Enable regex in the find panel.

Then you can use \t for tabs. \r for carriage returns. \n for newlines.

Right on, thank you.
chodenode
 
Posts: 2
Joined: Thu Feb 02, 2012 2:39 pm


Return to General Discussion

Who is online

Users browsing this forum: Google [Bot], Yahoo [Bot] and 20 guests