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 175218

Summary: Unwanted check marks in the menus
Product: platform Reporter: jsacha <jsacha>
Component: Window SystemAssignee: Stanislav Aubrecht <saubrecht>
Status: RESOLVED INVALID    
Severity: blocker    
Priority: P3    
Version: 6.x   
Hardware: PC   
OS: Windows Vista   
Issue Type: DEFECT Exception Reporter:
Attachments: Screen shot of menus with unwanted check marks
Mixture of correct and incorrect check marks
Check marks in NetBeans IDE
Simple code for reproducing the bug
swing app demonstrating the problem with JIDE

Description jsacha 2009-10-22 15:35:45 UTC
I encounter an intermittent but consistent problem with checkmarks showing up in all menu items, see attached image. The
problem is in an application created using NetBeans Platform 6.7.1, Java 1.6.0_16.

It is intermittent, is does not happen every time I use the application, but is quite frequent. Once the check masks
show up they stay around till I restart the application.

I did not find much information about it. Someone discussed a similar issue a while back:
http://www.nabble.com/Problem-with-Netbeans-Platform-Menu-Icons-tt19142938.html#a19142938
Comment 1 jsacha 2009-10-22 15:38:06 UTC
Created attachment 89924 [details]
Screen shot of menus with unwanted check marks
Comment 2 Stanislav Aubrecht 2009-10-23 11:29:00 UTC
looks like a jdk bug to me
i noticed the check marks have orange background. is that correct color according to your windows theme?
Comment 3 jsacha 2009-10-23 17:14:09 UTC
Created attachment 89991 [details]
Mixture of correct and incorrect check marks
Comment 4 jsacha 2009-10-23 17:26:23 UTC
In Excel 2007 check masks are shown on orange background. In NetBeans IDE check marks are on blue background (see
attached image), that is probably a separate issue.
When NetBeans Platform application starts the correct check marks are on blue background as in NetBeans IDE. When the
unwanted check masks show up (with orange background), the check masks that were before with blue background now show
'transparent' background and have different shape (see attached image).
Comment 5 jsacha 2009-10-23 17:27:05 UTC
Created attachment 89993 [details]
Check marks in NetBeans IDE
Comment 6 Stanislav Aubrecht 2009-10-26 15:41:34 UTC
can you reproduce this with a plain platform application (without any of your modules)?
does it happen when running your application with metal or nimbus look & feel as well?
Comment 7 jsacha 2009-12-17 08:52:45 UTC
Created attachment 92716 [details]
Simple code for reproducing the bug

Sample code that can reliably reproduce the problem. On startup menus look fine. To induce unwanted check marks select File > Directory Chooser (just close the dialog after it shows up).
Comment 8 jsacha 2009-12-17 08:55:37 UTC
The issue is not random. It can be reliably reproduced using the sample code.
Comment 9 Stanislav Aubrecht 2011-11-15 12:21:20 UTC
this is a bug in  JIDE library, i've reproduced the orange check marks in a plain swing app.
Comment 10 jsacha 2011-11-15 14:36:42 UTC
Can you attach a sample plain swing app to reproduce the problem. I will file bug report with JIDE Soft.
Comment 11 Stanislav Aubrecht 2011-11-15 14:40:31 UTC
Created attachment 113229 [details]
swing app demonstrating the problem with JIDE
Comment 12 jsacha 2011-11-16 17:35:10 UTC
I got information on workaround from JIDE support. You need to add

LookAndFeelFactory.installJideExtension(LookAndFeelFactory.VSNET_STYLE_WITHOUT_MENU)

After the Look and Feel was initialized to avoid check mark issue. For instance, the sample Swing code would need to be modified like this.

for(UIManager.LookAndFeelInfo info : UIManager.getInstalledLookAndFeels() ) {
  if( "Windows".equals( info.getName() ) ) {
     UIManager.setLookAndFeel( info.getClassName() );
     LookAndFeelFactory.installJideExtension(LookAndFeelFactory.VSNET_STYLE_WITHOUT_MENU);
    break;
  }
}

Any suggestion how this should be correctly done in a NetBeans platform application?
A custom ModuleInstall?
Comment 13 Stanislav Aubrecht 2011-11-16 19:13:08 UTC
try adding that to ModuleInstall.restored() method