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.
Created attachment 124132 [details] simple screencast with this issue Mark occurrences sometimes does not work and previously selected element remain highlighted while cursor is already inside another one. It's reproducible with this simple code: === CODE START var pes = 1; function sum(a, b) { pes++; return a + b + 1; } ==== CODE END Now try to (no heuristic here) click on "a", "sum" and "pes" and repeat it for a while. After a few attempts (sometimes on a first try), the occurences of "pes" are no longer highlighted and random repeating selects it again after a few attempts. Similar sometimes "pes" is still highlighted while cursor is inside "s|um" Product Version: NetBeans IDE Dev (Build 201209110001) Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 System: Linux version 3.2.0-29-generic-pae running on i386; UTF-8; en_US (nb)
the same with occurrences for values of class attribute in HTML, please evaluate Product Version: NetBeans IDE 7.3 Beta (Build 201209201306) Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 System: Linux version 3.2.0-30-generic-pae running on i386; UTF-8; en_US (nb)
Do you really think this defect is P1/beta stopper ?
I also think it may not be stopper, but it is used in J1 demo. Mariane, what do think?
CursorSensitiveScheduler and BreadcrumbsScheduler overwrite each other events; if Breadcrumbs wins, tasks scheduled by CursorSensitveScheduler (e.g occurences highlighter) will get null event as if the editor was not opened for the source. Moving to parsing API, which performs the event overwrite.
(In reply to comment #3) > I also think it may not be stopper, but it is used in J1 demo. Mariane, what do > think? Marking occurrences is a part of J1 demo script, so I think it should really work. Honza, do you think you will be able to fix it soon ?
Workaround: http://hg.netbeans.org/jet-main/rev/d598ba9a8efb It eliminates the extra Scheduler, and so the events should not be overwritten anymore. It introduces a bug into breadcrumbs: when the breadcrumbs bar is enabled, it is not refreshed automatically (caret location must be changed, or a reparse must be performed to refresh it).
Thanks for quick fix, I'll verify it asap so it could be backported to beta.
So should this be closed as fix? Anyway, seems to be fine, I tried HTML and JS files and all was fine. Please backport it to beta Product Version: NetBeans IDE Dev (Build 20120921-b879527c1535) - manually applied fix from jet-main Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 System: Linux version 3.2.0-30-generic-pae running on i386; UTF-8; en_US (nb)
(In reply to comment #8) > So should this be closed as fix? I am not sure - this patch is only a workaround, it causes other problems. > > > Anyway, seems to be fine, I tried HTML and JS files and all was fine. Please > backport it to beta http://hg.netbeans.org/releases/rev/008adf85c503 > > > Product Version: NetBeans IDE Dev (Build 20120921-b879527c1535) - manually > applied fix from jet-main > Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 > System: Linux version 3.2.0-30-generic-pae running on i386; UTF-8; en_US (nb)
Integrated into 'main-golden', will be available in build *201209230001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/d598ba9a8efb User: Jan Lahoda <jlahoda@netbeans.org> Log: #218095 (workaround): disabling the breadcrumbs' Scheduler to prevent clashes with CursorSensitiveScheduler.
I filled bug #218893 for the correct solution.
Thanks Honzo, verified in Beta Product Version: NetBeans IDE 7.3 Beta (Build 201209232010) Java: 1.7.0_07; Java HotSpot(TM) Client VM 23.3-b01 System: Linux version 3.2.0-30-generic-pae running on i386; UTF-8; en_US (nb)