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 139375 - constructor without access modifier is treated as an Indetifier
Summary: constructor without access modifier is treated as an Indetifier
Status: RESOLVED WONTFIX
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 6.x
Hardware: All Windows XP
: P4 blocker (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-09 11:34 UTC by gautammalik
Modified: 2016-07-07 07:18 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gautammalik 2008-07-09 11:34:03 UTC
Open a Java class having a constructor without access modifier e.g.

1: public class XYZ(){
2:  int a;
3:  public XYZ() {
4:  }
5: 
6: XYZ(int a){
7:  this.a = a;
8: }
9:}

Go to Tools->Options ->Fonts & Colors
Select Syntax tab and select Java as the Language.
Click on "Constructor declaration" and assign a unique color (lets say Purple)
Click on "Indentifier" and assign a unique color (lets say Orange)
Save settings and go back to the class.

Bug:-
We will see constructor at line number 4 (Constructor with access modifier) will be in Purple but the constructor at
line number 6 (Constructor without access modifier) will be in Orange. The moment we add an access modifier the
constructor (at line 6) the color changes to Purple.

A related issue is -
Go to Tools->Options ->Fonts & Colors
Select Syntax tab and select Java as the Language.
We see a sample code.
When we click on the 'method' in the sample code, it takes us to modify the color of 'Identifier'. It should take us to
modify the 'Method Declaration' color.
Similarly, When we click on the 'String' in the sample code, it takes us to modify the properties of 'Identifier'. It
should take us to modify the 'Class Use' color.
Similarly, When we click on the 'param' in the sample code, it takes us to modify the properties of 'Identifier'. It
should take us to modify the 'Parameter declaration' color.
Comment 1 Jiri Prox 2008-07-09 12:20:54 UTC
reproducible 
Comment 2 Jan Becicka 2008-07-24 16:34:28 UTC
P4 imo.
Comment 3 Rastislav Komara 2009-02-03 10:51:58 UTC
Overtake.
Comment 4 Jan Lahoda 2009-08-20 09:57:47 UTC
Reassigning all moonko's java/source bugs to myself.
Comment 5 Martin Balin 2016-07-07 07:18:02 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss