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 121097

Summary: CC accomplished at midle of a word
Product: javaee Reporter: Martin Schovanek <mschovanek>
Component: JSPAssignee: issues@javaee <issues>
Status: REOPENED ---    
Severity: blocker    
Priority: P2    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:

Description Martin Schovanek 2007-11-04 12:20:54 UTC
[2007110262308, jdk1.5.0]

to reproduce:
-------------
1) type in a .jsp:
<h|2>
NOTE: the | char represents cursor
2) invoke CC and choose <head>
ERROR: CC expands to invalid: '<head>2>' I would expect: '<head>'

For case like '<h|2 lang="en">' we should produce: <head lang="en">

Reproducible in CSS and JavaScript as well.
Comment 1 Marek Fukala 2007-11-04 17:19:26 UTC
The current behaviour is correct, consistent with java btw. I would personally didn't like if the completion deleted the
content behing the cursor. The only think which should work is that the completion shouldn't duplicate the same text if
it already exists behind the cursor: <he|ad> => <head>, not <head>ad>
Comment 2 Martin Schovanek 2007-11-05 06:17:01 UTC
Do you have a case where this behavior is wrong?
Comment 3 Marek Fukala 2007-11-05 10:46:19 UTC
<div on|mousehover="..."/> & complete onclick - do you really think we should replace the mousehover by mouseclick? Why
java doesn't do that as well? If you have some reasonable basis why we should do that I will reconsider. For now it
seems to me not to be a good idea.
Comment 4 Martin Schovanek 2007-11-05 14:24:30 UTC
Spoken with Java guys and they track it as regular issue #108168. Reopening to be consistent with Java.
Comment 5 Marek Fukala 2007-11-05 14:39:26 UTC
Ok, if hie claims we should have this... I just a stupid coder.