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 245047

Summary: Wrong indentation in gernerated code blocks
Product: guibuilder Reporter: ulfzibis <ulfzibis>
Component: CodeAssignee: issues@guibuilder <issues>
Status: NEW ---    
Severity: normal    
Priority: P3    
Version: 8.0   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:

Description ulfzibis 2014-06-13 23:42:05 UTC
[ JDK VERSION : 1.7.0_45 ]

STEPS:
   * Customize indentation values for a project like:
auxiliary.org-netbeans-modules-editor-indent.text.x-java.CodeStyle.project.conti
nuationIndentSize=4
auxiliary.org-netbeans-modules-editor-indent.text.x-java.CodeStyle.project.inden
t-shift-width=2
auxiliary.org-netbeans-modules-editor-indent.text.x-java.CodeStyle.project.space
s-per-tab=2
auxiliary.org-netbeans-modules-editor-indent.text.x-java.CodeStyle.project.tab-s
ize=4

   * Edit some java class with Matisse GUI designer.

ACTUAL:
   In the generated java code blocks indentation is still according the general
indentation values, mostly 4/8.

EXPECTED:
   In the generated java code blocks indentation should be 2/4 spaces.

WORKAROUND:
   * Aditionally customize:
auxiliary.org-netbeans-modules-editor-indent.CodeStyle.project.indent-shift-widt
h=2
auxiliary.org-netbeans-modules-editor-indent.CodeStyle.project.spaces-per-tab=2
auxiliary.org-netbeans-modules-editor-indent.CodeStyle.project.tab-size=4
Comment 1 ulfzibis 2014-06-16 14:29:59 UTC
In following scenario, the workaround doesn't help:
- Open java+form file from very old project (<Form version="1.0" ...>).
- Resize frame in GUI-Editor (to force update to <Form version="1.2" ...>).
- Save.