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 202013 - Editor not coluring code correctly
Summary: Editor not coluring code correctly
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Hints (show other bugs)
Version: 7.1
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Jan Lahoda
URL:
Keywords:
: 204006 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-09-12 12:28 UTC by tim_sa
Modified: 2011-10-24 14:07 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
code colouring not consistant (8.36 KB, image/png)
2011-09-12 12:29 UTC, tim_sa
Details

Note You need to log in before you can comment on or make changes to this bug.
Description tim_sa 2011-09-12 12:28:52 UTC
[ BUILD # : 201109110600 ]
[ JDK VERSION : 1.7 ]

first line null is in blue text

All lines thereafter it is in grey text
Comment 1 tim_sa 2011-09-12 12:29:35 UTC
Created attachment 110664 [details]
code colouring not consistant
Comment 2 tim_sa 2011-09-12 12:30:16 UTC
This is in a .java file
Comment 3 Jan Lahoda 2011-09-12 12:45:47 UTC
Why P1?

The gray means the values from the assignment are unused (place a mouse over them and wait for a little while to verify). See Unused Assignment hint in Tools/Options/Editor/Hints/Java to disable it. The assignments for unused variables (like the first one) are not marked, as that was extremely annoying during coding.

Will probably need more visual clues for the user to realize this.
Comment 4 tim_sa 2011-09-13 07:17:24 UTC
(In reply to comment #3)
> Why P1?
> 
> The gray means the values from the assignment are unused (place a mouse over
> them and wait for a little while to verify). See Unused Assignment hint in
> Tools/Options/Editor/Hints/Java to disable it. The assignments for unused
> variables (like the first one) are not marked, as that was extremely annoying
> during coding.
> 
> Will probably need more visual clues for the user to realize this.

Apologies If I got the priority wrong, I thought it was a regression hence the P1.


If I change the unused import to show as an ERROR then I get a red line under the unused import.
If I change the unused Assignment to ERROR then I don't get any change in behavior from the editor.

Changing the Show As property doesn't seem to have a noticeable effect on the editor window for the Unused Assignment
Comment 5 Jan Lahoda 2011-10-20 13:29:11 UTC
I have changed the hint to adhere to hint standards:
http://hg.netbeans.org/jet-main/rev/fb2497f6e6b1
Comment 6 Jan Lahoda 2011-10-20 13:40:38 UTC
*** Bug 204006 has been marked as a duplicate of this bug. ***
Comment 7 Quality Engineering 2011-10-24 14:07:22 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/fb2497f6e6b1
User: Jan Lahoda <jlahoda@netbeans.org>
Log: #202013: changing the UnusedAssignmentOrBranch to work as an ordinary hint.