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 130644 - Cannot change indentation and numb. of spaces per indent
Summary: Cannot change indentation and numb. of spaces per indent
Status: RESOLVED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: Options (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker with 1 vote (vote)
Assignee: Max Sauer
URL:
Keywords:
: 131190 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-03-20 14:29 UTC by tkellerer
Modified: 2008-04-24 08:10 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tkellerer 2008-03-20 14:29:29 UTC
I downloaded the -ruby ZIP-distribution of the daily builds and started NetBeans with an empty UserDir.
When I change the settings for Tools -> Options -> Editor -> Indention select "Expand tabs to spaces" and reduce the tab
size to 2 characters, the settings are not stored. After closing and then re-opening the options window, "Expand tabs to
spaces" is de-selected and the tab size is 4 as before. 

Btw: I think especially for the Ruby package it should be possible to configure these settings per editor type. A YML
file may not contain any tab characters (it will fail to load) but I might want to have tabs in my .rb files...
The same is true for the "regular" distribution. I would love to see the "Expand tabs" and "tab size" settings on a per
file type basis (as it was possible before the "Extended properties" were crippled)
Comment 1 tkellerer 2008-03-20 14:53:26 UTC
Sorry that should be "Number of spaces per indent" instead of the "Tab Size" property. 
The tab size property seems to be the only one that is saved.
Comment 2 Torbjorn Norbye 2008-03-20 15:42:58 UTC
Is the bug that the actual option value in the options dialog isn't stored, or is the case that the Ruby editor ignores it?

Ruby has its own indent settings in the Ruby options category. This was necessary because having a single IDE wide
setting wasn't appropriate; the default for Ruby is 2. The proper solution is for the indent settings to perhaps have
associated mime types - that's tracked in another issue for the editor I believe.
Comment 3 tkellerer 2008-03-20 15:48:51 UTC
The indention size in the ruby section is ignored as well. 
Especially the "Expand tabs to spaces" is only available in the general options and if not disabled will break yml files.
Comment 4 Torbjorn Norbye 2008-03-21 05:06:25 UTC
Persistence in the editor options dialog is handled by the editor module; reassigning
Comment 5 Max Sauer 2008-03-21 11:51:04 UTC
Confirmed. We should fix this in 6.1.
Comment 6 Max Sauer 2008-03-25 14:01:13 UTC
Fixed.
---
http://hg.netbeans.org/main/rev/dd8b4771e3de

Comment 7 Max Sauer 2008-03-27 09:51:32 UTC
*** Issue 131190 has been marked as a duplicate of this issue. ***
Comment 8 velodiver 2008-04-23 20:10:35 UTC
Not all of this issue was fixed: 

JSP pages do not retain spaces/tab settings.

See 132772.
Comment 9 Jiri Prox 2008-04-24 08:10:51 UTC
If I understand it correctly, all the problems are now tracked be issue 132772. There is no need to have two issues
opened for the same problem -> closing as fixed again