This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 179241 - source format inserts spurious spaces in erb
Summary: source format inserts spurious spaces in erb
Alias: None
Product: ruby
Classification: Unclassified
Component: Editing (show other bugs)
Version: 6.x
Hardware: Macintosh Mac OS X
: P3 normal (vote)
Assignee: issues@ruby
Depends on:
Reported: 2010-01-06 03:42 UTC by fjan11
Modified: 2011-01-28 20:13 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:

java file that gets additional spaces when formatted (3.52 KB, text/plain)
2011-01-09 18:07 UTC, lolo_101

Note You need to log in before you can comment on or make changes to this bug.
Description fjan11 2010-01-06 03:42:50 UTC
Each time Source -> Format is selected on an erb file several spurious spaces get inserted. For example in this erb snippet:

   This sentence gets indented correctly by source format
<% if true %>
       This sentence only gets indented correctly the first time source format is selected
       This will shift on every subsequent invocation
<% end %>
Comment 1 Erno Mononen 2010-04-13 12:31:23 UTC
Seems to be fixed in 6.9 dev builds, please reopen if you can still reproduce this with 6.9 Beta or the latest daily. Thanks.
Comment 2 fjan11 2010-04-15 09:18:35 UTC
I found what the problem is: This bug ONLY happens if in the following setting is NOT checked: Preferences => Editor => Formatting => Language: RHTML => Expand tabs to spaces

The default setting is that tabs are converted to spaces so not many people will run into this, so I am mainly putting this here for reference.
Comment 3 lolo_101 2011-01-09 18:07:12 UTC
Created attachment 104826 [details]
java file that gets additional spaces when formatted

Every time the source is formatted with Alt-Shift-F, a space is added line 34 just before the '{'.
Comment 4 lolo_101 2011-01-09 18:08:29 UTC
I also have the same issue with NB 7.0 beta on windows XP and windows 7, with a java file (see attachement).