Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

eclipse: changing the # of spaces to indent/unindent

How do I adjust the # of spaces added/removed by Eclipse when I hit Tab or Shift+Tab, for a given filetype? I am working on reStructuredText files (.rst) and want 2 spaces for those instead of 4.

like image 828
Jason S Avatar asked Jan 14 '10 18:01

Jason S


People also ask

How do I change the look of Eclipse?

Changing the Color Theme To change the color theme in your editor: Go to Window | Preferences | General | Appearance | Color Theme. The list of available Eclipse color themes is displayed.

How do I change my Eclipse theme to black?

If you want to join this club, simply type "Dark" into the Quick Access box and press enter. This brings you to the correct preference page. Select Dark, press Apply and Close (and restart your IDE to fully apply the theme).

How do I import a theme into Eclipse?

In Eclipse, to open the desired theme selection window go to Window > Preferences > DevStyle > Color Theme . In Extras section, click import and select dracula-theme.


1 Answers

From the Window menu, choose Preferences. Navigate down to General: Editors: Text Editors: Displayed tab width.

You may also want to check out the code style for some other types of editors, because they decide whether to use tabs or spaces, and the size of the tab stops.

Hint: In the top left of the preferences dialog, you can type "tab" where it says "type filter text", and it will show you all settings related to tabs.

like image 114
Don Kirkby Avatar answered Sep 19 '22 18:09

Don Kirkby