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.
Build: NetBeans IDE Dev (Build 201111140600) VM: Java HotSpot(TM) Client VM, 21.1-b02, Java(TM) SE Runtime Environment, 1.7.0_01-b08 OS: Windows Vista User Comments: MackSix: Changed the layout several times on a form. Was using the Undo button to change back to orignal form layout when this happened. Stacktrace: java.lang.NullPointerException at org.netbeans.modules.form.layoutdesign.LayoutUtils.getSizesOfDefaultGap(LayoutUtils.java:356) at org.netbeans.modules.form.layoutdesign.LayoutUtils.getSizeOfDefaultGap(LayoutUtils.java:279) at org.netbeans.modules.form.layoutdesign.LayoutDesigner.updateCurrentSpaceOfGroups(LayoutDesigner.java:351) at org.netbeans.modules.form.layoutdesign.LayoutDesigner.updateCurrentSpaceOfGroups(LayoutDesigner.java:365) at org.netbeans.modules.form.layoutdesign.LayoutDesigner.updateContainerAfterBuild(LayoutDesigner.java:3960) at org.netbeans.modules.form.layoutdesign.LayoutDesigner.updateCurrentState(LayoutDesigner.java:264)
Created attachment 113217 [details] stacktrace
Created attachment 113218 [details] Project that exhibits the error. 1) Open project in NetBeans. 2) Open Antenna.java file. 3) Click on Design button to put editor in design mode. 4) In Navigator, right click on [JFrame] node and set layout to Absolute Layout. 5) Continue step 4 for each Layout listed until the end of the list (Null Layout). 6) In Navigator, right click on [JFrame] node and set layout to Free Design. 7) Now click the Undo button (Ctrl+Z) to undo layouts back to Free Design again. This NullPointerException occurs.
Notice Issue 199259 looks the same as this.
It's enough to switch the JFrame just to null layout and then to Free Design. Fixed: http://hg.netbeans.org/jet-main/rev/9371bebc986b