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 245649

Summary: Editor recognizes Javascript property as function
Product: javascript Reporter: iluvtr
Component: EditorAssignee: Petr Pisl <ppisl>
Status: RESOLVED WONTFIX    
Severity: normal CC: vriha
Priority: P4    
Version: 8.0   
Hardware: PC   
OS: Windows 7   
Issue Type: DEFECT Exception Reporter:
Attachments: Detail of bug

Description iluvtr 2014-07-14 13:59:57 UTC
Created attachment 148038 [details]
Detail of bug

As you can see in the image the editor recognizes Javascript property as function (bold)
Comment 1 iluvtr 2014-07-14 14:03:31 UTC
This occurs when I create an object and to this object I attach a property referring to other object I mean:

var object = {
   name : 'Nestor',
   address : { city:'Lima', country:'PerĂº' } //This is when things break!
   salute : function() {
          return 'Hello';
    }
}
Comment 2 Vladimir Riha 2014-07-14 14:11:08 UTC
You can change it in Tools|Options|Fonts & Color -> Syntax, language JavaScript and Category "Class". Personally I like it as you can quickly recognize obj. literal...

Reproducible, but not a P2. The workaround is quite simple, adjust formatting.


Product Version: NetBeans IDE Dev (Build web-main-1023-on-20140714)
Java: 1.8.0_05; Java HotSpot(TM) Client VM 25.5-b02
Runtime: Java(TM) SE Runtime Environment 1.8.0_05-b13
System: Linux version 3.13.0-30-generic running on i386; UTF-8; en_US (nb)
Comment 3 Petr Pisl 2014-07-21 09:40:27 UTC
Vlada is true. It's not a function, it's a object literal (mapped to the class color). The class and function looks in the default theme in the same way. User can change.