Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 55357 - templates do not appear in content assist when expected
Summary: templates do not appear in content assist when expected
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Ant (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.1 M3   Edit
Assignee: Kevin Barnes CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on: 74506
Blocks:
  Show dependency tree
 
Reported: 2004-03-19 08:24 EST by John-Mason P. Shackelford CLA
Modified: 2004-10-25 14:14 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John-Mason P. Shackelford CLA 2004-03-19 08:24:55 EST
Occasionally the fileset template does not appear in the content assist when 
expected. Sometimes it reappears after a short delay.
Comment 1 John-Mason P. Shackelford CLA 2004-03-27 22:58:05 EST
Template proposals are presented immediately after CTRL-SPACE, however once the
user begins typing additional text and the type-ahead feature kicks in, the
template proposals disappear. Another CTRL-SPACE brings them back.
Comment 2 Darin Swanson CLA 2004-04-07 13:24:33 EDT
This is because TemplateProposal returns false for 
ICompletionProposalExtension2#validate(IDocument, int, Document).

The same happens for templates in the Java Editor.

Tom, do you know the plans here?
Comment 3 Tom Hofmann CLA 2004-04-08 03:17:50 EDT
Darin, you're right. This is really a dup of bug 41750, I'll add some comments
there.

*** This bug has been marked as a duplicate of 41750 ***
Comment 4 John-Mason P. Shackelford CLA 2004-04-23 18:20:10 EDT
I would recommend reopening this bug and fixing it in the ant editor ASAP (I am 
volunteering) since it is marked as 3.0 p2, unless Tom thinks that there is a 
very high probability that this going to make it in before the end of M9.
Comment 5 Darin Swanson CLA 2004-04-23 18:27:17 EDT
Sure...see what you can do.
Comment 6 John-Mason P. Shackelford CLA 2004-05-10 01:50:07 EDT
With the latest changes from text I believe that the issue described in my
original bug report has been corrected, thought it might be worthwhile to have
another set of eyes on this.
Comment 7 John-Mason P. Shackelford CLA 2004-05-11 09:42:27 EDT
This works for me on both 0504 & 0511 but it appears to have regressed in HEAD,
though I still haven't found files in HEAD more recent than 0511 to blame it on.
Ideas?
Comment 8 Darin Swanson CLA 2004-05-11 21:17:05 EDT
I am still seeing trouble here.
I type in 
<prop
CTRL+Space
type 'e'
the property template disappears.
Comment 9 Darin Swanson CLA 2004-06-02 14:57:58 EDT
Nothing more planned for 3.0
Comment 10 Darin Swanson CLA 2004-08-19 12:21:03 EDT
Reopening
Comment 11 Darin Swanson CLA 2004-08-19 12:21:43 EDT
We can investigate using the support added via bug 41750.
Comment 12 Darin Swanson CLA 2004-08-24 19:58:13 EDT
The remaining problem we have in Ant is that we want to validate on both
prop and <prop.
I could achieve this by overriding validate(IDocument, int, DocumentEvent) but 
then I would need protected access to the fTemplate and getReplaceOffset.

Another proposal would be to provide a protected method such as 
getValidationString() that TemplateProposal would implement as 
fTemplate.getName() and we could override as needed (would still need access 
to fTemplate).
Comments from Tom?
Comment 13 Tom Hofmann CLA 2004-09-22 05:24:15 EDT
I favor the first proposal of comment 12: the CompletionProposal's template and
the getReplace{Offset,EndOffset} methods should be made accessible for subclasses.

I filed bug 74506 against platform-text to track that request. 
Comment 14 Darin Swanson CLA 2004-10-22 20:36:40 EDT
Changes to AntTemplateProposal and AntEditorCompletionProcessor.
Comment 15 Darin Swanson CLA 2004-10-23 19:02:19 EDT
Comment #8 contains the test case.
This fix currently depends on the latest code from jface text.
Comment 16 Darin Swanson CLA 2004-10-23 19:02:32 EDT
Please verify Kevin.
Comment 17 Kevin Barnes CLA 2004-10-25 14:08:02 EDT
verified
Comment 18 Darin Swanson CLA 2004-10-25 14:14:53 EDT
Thanks build notes updated.