Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 472462 - Formmater indentation with "Tab size: 2"
Summary: Formmater indentation with "Tab size: 2"
Status: VERIFIED DUPLICATE of bug 467229
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 4.5   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: 4.5.1   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-13 04:50 EDT by Lucas Neiva CLA
Modified: 2015-08-21 03:04 EDT (History)
2 users (show)

See Also:


Attachments
Workspace with the described formatter settings (10.25 MB, application/zip)
2015-07-13 04:50 EDT, Lucas Neiva CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lucas Neiva CLA 2015-07-13 04:50:20 EDT
Created attachment 255143 [details]
Workspace with the described formatter settings

Migrating from Eclipse Luna to Eclipse Mars, previously working formatter settings with "Tab size" set to 2, now lose the first level of indentation.

Steps to reproduce:
- Clone the eclipse formatter settings.
- Edit the formatter settings.
- Set the "Tab policy" to "Tabs only", and the "Tab size" to "2".
- Run the formatter on a method body indented with using tabs.

I've attached a workspace, where Example.java shows this effect.
Comment 1 Mateusz Matela CLA 2015-07-13 16:30:16 EDT
Duplicate of bug 467229.
Workaround: change tab policy so that you can edit both tab size and indentation size, change both to desired value, switch tab policy back to tabs.
Comment 2 Lucas Neiva CLA 2015-07-14 04:01:22 EDT
Sorry. I was unable to find the previous bug report. Thanks Mateusz.

*** This bug has been marked as a duplicate of bug 467229 ***
Comment 3 Sasikanth Bharadwaj CLA 2015-08-21 03:04:48 EDT
Verified for 4.5.1 using M20150819-1000 build