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.
Summary: | SourceCache bug? [was:composite:facet and composite:insertFacet | ||
---|---|---|---|
Product: | editor | Reporter: | edburns <edburns> |
Component: | Parsing & Indexing | Assignee: | Tomas Zezula <tzezula> |
Status: | RESOLVED WONTFIX | ||
Severity: | blocker | CC: | ethermion, mfukala, pjiricka, sdedic |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | Macintosh | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
edburns
2009-09-07 03:27:14 UTC
That is a pity that the issue used to be hidden in the wrong category. I am affraid I am not allowed to implement any features to 6.8 now. It sounds like useful feature anyway. Well, it is probably too late for 7.2, but this would be a very nice enhancement. Seems to have been *lost* again. It would be awfully useful for those serious developers building composite component jar libraries. What Ed describes is supposed to work. fixed in web-main#5bed2d595dc7 Thanks! Against Build 201206140001 Not quite there. When you first type: <f:facet name="" and your cursor is inside the quotes for name, ctrl-space gives a menu of attributes of the tag - name, id, parent, rendered etc. If you cursor out of the quotes, then back in, then ctrl-space, it works. Would also be double great if the displayName and shortDescription attributes of the facet showed up. Again Build 201206140001 ctrl-space in facet name inside h:dataTable shows facet names from my custom component. It does not show facet names from h:dataTable. > Not quite there.
> When you first type:
> <f:facet name=""
>
> and your cursor is inside the quotes for name, ctrl-space gives a menu of
> attributes of the tag - name, id, parent, rendered etc.
Works fine for me all the time.
Any special steps to reproduce? Does it happen always for you?
> ctrl-space in facet name inside h:dataTable shows facet names from my custom
> component. It does not show facet names from h:dataTable.
Can you please put here a sample? What I did so far is the Ed's case only.
(In reply to comment #8) > > Not quite there. > > When you first type: > > <f:facet name="" > > > > and your cursor is inside the quotes for name, ctrl-space gives a menu of > > attributes of the tag - name, id, parent, rendered etc. > Works fine for me all the time. > > Any special steps to reproduce? Does it happen always for you? Actually I managed to reproduce it. The steps are: 1) put <f:facet | into a facelets document 2) invoke completion 3) complete "name" 4) !!! wait until the file gets parsed before continue !!! 5) invoke completion in the name="|" position => tag attributes are offered if one doesn't fulfill the #4 condition it works well. Seems to be caused by an incorrect parse tree. It looks like some issue in the parsing.api resp. in the SourceCache. The HtmlCompletionProvider runs an UserTask, then gets parser result by resultIterator.getParserResult(offset) However the returned parser result is not always the fresh one, sometimes an older result along with snapshot is returned: 1) typed <f:facet | : XhtmlElEmbeddingProvider.getEmbeddings() - created snapshot: Snapshot 27467691: newjsf1.xhtml( text/html 0-516) 2) invoked cc and completed "name" : completion got snapshot Snapshot 27467691: newjsf1.xhtml( text/html 0-516) XhtmlElEmbeddingProvider.getEmbeddings() - created snapshot: Snapshot 25011966: 3) invoked cc in the name="|" : completion got snapshot Snapshot 27467691: newjsf1.xhtml( text/html 0-516) completion got snapshot Snapshot 27467691: newjsf1.xhtml( text/html 0-516) => the older parser result/snapshot is still used so the completion sees a whitespace only (the state where there's just "<f:facet " text) and offers the attributes then. This doesn't seem to be always reproducible, but happens quite often when using the steps from my comment above. I remember Svate has been trying to solve some issue with code folding where there were similar symptoms. Is that true Svato? A potential duplicate is the issue #212014 This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue. Thanks for your cooperation, NetBeans IDE 8.2 Release Boss |