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 189963 - User cannot change color of ID and CLASS attribute values in HTML code
Summary: User cannot change color of ID and CLASS attribute values in HTML code
Status: RESOLVED FIXED
Alias: None
Product: web
Classification: Unclassified
Component: HTML Editor (show other bugs)
Version: 6.x
Hardware: Macintosh (x86) Mac OS X
: P2 normal (vote)
Assignee: Marek Fukala
URL: http://img835.imageshack.us/i/screens...
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-28 20:49 UTC by kkathman
Modified: 2011-05-06 11:30 UTC (History)
1 user (show)

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 kkathman 2010-08-28 20:49:47 UTC
Using NetBeans IDE 6.9 (Build 201006101454) on an Intel iMac with Snow Leopard 10.6.4.

The color for HTML tag <div id="identifier"> is not consistent with all other tags.

On my system the content in the attribute quotes, 'identifier' is a background of light yellow with a green foreground.  This combination is not found anywhere in the system in the various syntax profiles OR highlighting.  All other HTML tag attribute content is a completely different color as specified by the syntax color setting. The <div> tag is the only exception.

A visualization of this can be seen at the following location:

http://img835.imageshack.us/i/screenshot20100828at225.png
Comment 1 kkathman 2010-08-28 22:53:41 UTC
Update - more information:

Apparently, NetBeans 6.9.1 does the same thing with regard to the inconsistency.  

I am coding in PHP/HTML and each time I have a <div id="value"> tag it colors the "value" in an unknown, unspecified foreground and background color than ALL the rest of the tags in my code.  It colors those with a yellowish white background and green foreground, which doesn't appear ANYWHERE in the HTML, PHP OR "All Languages" color profiles. 

Update:  It works the same if you have a <p class="value"> tag also.  The Value is in a different color than expected. When you type in a new line, it colors it differently.

This is the same no matter WHAT color profile you use. It ALWAYS shows in dark green on a yellow background, so that tells me it's a system default somewhere.  If you go to preferences and change the Attribute value to a different color scheme, the quotes will be in that color, but the value will always be something different.

When you first load the program these attribute values are normal. However as soon as you click anywhere on that line, it will automatically reverse, and stay that way.

This is obviously a bug.
Comment 2 David Strupl 2010-08-30 08:23:14 UTC
Trying to find the owner of HTML files ...
Comment 3 Marek Fukala 2010-10-04 12:25:56 UTC
Yes, it's a bug. AFAIR the color code is taken from css editor, resp. the css selector item.
Comment 4 Marek Fukala 2010-12-17 14:17:32 UTC
Works fine for me in latest 7.0 build. All the profiles works fine, if you set up your own colors, you need to modify the "CSS Embedded in HTML" coloring item for the HTML language. You can either use "inherit" or your own colors.

Just for your information the behavior you described after startup or file opening (colors switching) is caused by the semantic coloring being computed after scanning of the file finishes, which may take some time.
Comment 5 nehalem 2011-05-04 21:14:34 UTC
This still happens for me on 7 on a mac
Comment 6 Marek Fukala 2011-05-05 09:22:39 UTC
(In reply to comment #5)
> This still happens for me on 7 on a mac

Please describe the exact steps to reproduce your problem. As stated in the comment #4 the coloring works for me on my Mac.
Comment 7 nehalem 2011-05-05 17:45:46 UTC
Ok, did get it to change.  But with a difference:
1.  It was in cascading style sheets under selector
2.  I have to restart each time.
Comment 8 Marek Fukala 2011-05-06 11:30:00 UTC
(In reply to comment #7)
> Ok, did get it to change.  But with a difference:
> 1.  It was in cascading style sheets under selector
Yes, but this will change all the selectors coloring even in css. The "Css Embedded in HTML" color in the HTML coloring options is just for css in html code. Both works well for me.
> 2.  I have to restart each time.
You just need to reopen the file.