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 107460 - [Fonts&Colors] Deleting a F&C profile breaks coloring and gutter, NPE
Summary: [Fonts&Colors] Deleting a F&C profile breaks coloring and gutter, NPE
Status: VERIFIED FIXED
Alias: None
Product: utilities
Classification: Unclassified
Component: Diff (show other bugs)
Version: 6.x
Hardware: PC Linux
: P2 blocker (vote)
Assignee: diff-issues@utilities
URL:
Keywords:
Depends on:
Blocks: 106361
  Show dependency tree
 
Reported: 2007-06-20 15:40 UTC by Max Sauer
Modified: 2007-06-25 10:23 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
NPE stack trace (952 bytes, text/plain)
2007-06-20 15:41 UTC, Max Sauer
Details
proposed screenshot (35.52 KB, image/png)
2007-06-20 15:42 UTC, Max Sauer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Max Sauer 2007-06-20 15:40:43 UTC
Deleting of a duplicated F&C profile breaks source code coloring and removes gutter. Following NPE is thrown:

java.lang.NullPointerException
	at org.netbeans.modules.diff.options.DiffColorsPanel.applyChanges(DiffColorsPanel.java:118)
	at org.netbeans.modules.options.colors.FontAndColorsPanel.applyChanges(FontAndColorsPanel.java:209)
	at org.netbeans.modules.options.colors.FontAndColorsPanelController.applyChanges(FontAndColorsPanelController.java:68)
	at org.netbeans.modules.options.CategoryModel$Category.applyChanges(CategoryModel.java:342)
...
(whole stack trace attached)

Steps to reproduce:
-------------------
1) Open a j2se project
2) Switch to ie. 'Norway Today' profile inside Options|F&C, confirm OD
3) Re-invoke OD, duplicate 'Norway Today' profile to ie 'Norway Today2', confirm OD
4) Re-invoke OD, delete the duplicated profile, confirm OD
=> NPE
=> See screenshot

---
Product Version: NetBeans IDE Dev (Build 070620) 
Java: 1.6.0_02-ea; Java HotSpot(TM) Client VM 1.6.0_02-ea-b02 
System: Linux version 2.6.12-1.1390_FC4smp running on i386; 
UTF-8; en_US (nb) Userdir: /home/ms159439/testUserdir0
Comment 1 Max Sauer 2007-06-20 15:41:04 UTC
Created attachment 44071 [details]
NPE stack trace
Comment 2 Max Sauer 2007-06-20 15:42:39 UTC
Created attachment 44072 [details]
proposed screenshot
Comment 3 Max Sauer 2007-06-20 15:43:58 UTC
Please reassign to diff module if necessary.
Comment 4 Max Sauer 2007-06-20 15:54:27 UTC
M10 stopper. IDE has to be restarted to get coloring & gutter back.
Comment 5 Vitezslav Stejskal 2007-06-21 04:48:33 UTC
Most likely in the new Diff panel.
Comment 6 Maros Sandor 2007-06-21 10:22:24 UTC
Cleaned up the code.

/shared/data/ccvs/repository/diff/src/org/netbeans/modules/diff/options/DiffColorsPanel.java,v  <--  DiffColorsPanel.java
new revision: 1.3; previous revision: 1.2
/shared/data/ccvs/repository/diff/src/org/netbeans/modules/diff/options/Bundle.properties,v  <--  Bundle.properties
new revision: 1.2; previous revision: 1.1
/shared/data/ccvs/repository/diff/src/org/netbeans/modules/diff/options/ColorComboBox.java,v  <--  ColorComboBox.java
new revision: 1.2; previous revision: 1.1
Comment 7 Max Sauer 2007-06-25 10:23:32 UTC
Verified.
---
Product Version: NetBeans IDE Dev (Build 200706230000) 
Java: 1.5.0_12; Java HotSpot(TM) 64-Bit Server VM 1.5.0_12-b04 
System: SunOS version 5.10 running on sparcv9; 
ISO646-US; en (nb) Userdir: /usr/space/test000