Praveen
Praveen

Reputation: 91185

What is the Auto-Alignment Shortcut Key in Eclipse?

What is the auto-alignment shortcut key in Eclipse?

Upvotes: 172

Views: 288375

Answers (5)

Akitha_MJ
Akitha_MJ

Reputation: 4294

auto-alignment shortcut key Ctrl+Shift+F

to change the shortcut keys Goto Window > Preferences > Java > Editor > Save Actions

Upvotes: 0

djeikyb
djeikyb

Reputation: 4598

The answer that the OP accepted is wildly different from the question I thought was asked. I thought the OP wanted a way to auto-align = signs or + signs, similar to the tabularize plugin for vim.

For this task, I found the Columns4Eclipse plugin to be just what I needed.

Upvotes: 18

Peter Perháč
Peter Perháč

Reputation: 20792

Ctrl+Shift+F to invoke the Auto Formatter

Ctrl+I to indent the selected part (or all) of you code.

Upvotes: 318

jai
jai

Reputation: 21907

Want to format it automatically when you save the file???

then Goto Window > Preferences > Java > Editor > Save Actions

and configure your save actions.

Along with saving, you can format, Organize imports,add modifier ‘final’ where possible etc

Upvotes: 13

Joey
Joey

Reputation: 354774

Auto-alignment? Lawful good?

If you mean formatting, then Ctrl+Shift+F.

Upvotes: 36

Related Questions