Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Aptana: find and replace tabs (with spaces)

I am belatedly setting up Aptana to use four spaces instead of tabs. I've made the necessary changes to the preferences so every new tab inserts four spaces.

All the existing tabs remain, however, and so I get Mixed spaces and tab errors. How can you do a Replace all to fix this? I've tried ^t, <TAB> etc but it just searches for these as normal strings. What are the correct ways to specify a space and a tab?

like image 400
Nick Avatar asked Jun 29 '12 22:06

Nick


People also ask

How do I search for tabs in eclipse?

Ctrl + H > File Search tab. Check "Regular expression" and type "\t" in the Search string field.


2 Answers

I've found myself in similar situation and copying whole source code and repasting it helped me out. Just do as follow on your source code Ctrl+A, Ctrl+C, then Del whole code and Ctrl+V it again. You will get only spaces if have set it in options like you mentioned above.

like image 79
scx Avatar answered Sep 28 '22 08:09

scx


There's an option in the refactor source menu to convert between tabs and space-tabs.

like image 45
Naddiseo Avatar answered Sep 28 '22 09:09

Naddiseo