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 56617

Summary: "Print to HTML" for Java source code throws an Exception
Product: editor Reporter: jfosterjr <jfosterjr>
Component: -- Other --Assignee: issues@editor <issues>
Status: RESOLVED DUPLICATE    
Severity: blocker    
Priority: P3    
Version: 4.x   
Hardware: All   
OS: Windows XP   
Issue Type: DEFECT Exception Reporter:
Attachments: messages.log file under ${user.dir}/var/log

Description jfosterjr 2005-03-17 22:22:17 UTC
An exception is thrown when the "Print to HTML" menu option is selected while
editing a Java source file.  Preliminary investigation has shown this error to
occur when certain background color preferences for the Java Editor are set to
"inherit" rather the being set explicitly.  When all background colors are set
explicitly the "Print to HTML" works as expected.

The following is the stacktrace that is produced:

*********** Exception occurred ************ at 5:03 PM on Mar 17, 2005
Annotation: Exception occurred in Request Processor
java.lang.NullPointerException
	at
org.netbeans.modules.editor.HtmlPrintContainer.getHtmlColor(HtmlPrintContainer.java:258)
	at
org.netbeans.modules.editor.HtmlPrintContainer.createStyle(HtmlPrintContainer.java:227)
	at org.netbeans.modules.editor.HtmlPrintContainer.end(HtmlPrintContainer.java:124)
	at org.netbeans.modules.editor.ExportHtmlAction.export(ExportHtmlAction.java:205)
	at
org.netbeans.modules.editor.ExportHtmlAction.access$000(ExportHtmlAction.java:42)
	at org.netbeans.modules.editor.ExportHtmlAction$1.run(ExportHtmlAction.java:142)
	at org.openide.util.Task.run(Task.java:136)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330)
[catch] at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:686)
Comment 1 jfosterjr 2005-03-17 22:26:10 UTC
Created attachment 20932 [details]
messages.log file under ${user.dir}/var/log
Comment 2 Dusan Balek 2005-03-21 15:45:17 UTC
Already fixed. Thanks for the report.

*** This issue has been marked as a duplicate of 56039 ***