getVariants() -- how are the matching candidates found Follow
I got this working most time by return PsiElement or Strings.
But still the internal matchign algorithm is hidden.
Having an reference I return both, a member field and a constant.
public String field1;
public static final String constant1="";
in getVariants() I return both fields.
But the popup for auto-completion only shows the members. So the
static stuff is somehow filtered out.
Same applies to static methods.
So how do I get this working?
Please sign in to leave a comment.
What is the prefix for the completion?
Sven Steiniger wrote:
--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"
Empty string.
Maxim Mossienko schrieb:
>> I got this working most time by return PsiElement or Strings.
>> But still the internal matchign algorithm is hidden.
>> Having an reference I return both, a member field and a constant.
>> public String field1;
>> public static final String constant1="";
>> in getVariants() I return both fields.
>> But the popup for auto-completion only shows the members. So the
>> static stuff is somehow filtered out.
>> Same applies to static methods.
>>
>> So how do I get this working?
Any comments?
I have installed an own CompletionData which derives from
HtmlCompletionData. So from debugging I know that
findPrefix() returns "".
Sven Steiniger schrieb:
>> What is the prefix for the completion?
>>
>> Sven Steiniger wrote:
>>
>>> I got this working most time by return PsiElement or Strings.
>>> But still the internal matchign algorithm is hidden.
>>> Having an reference I return both, a member field and a constant.
>>> public String field1;
>>> public static final String constant1="";
>>> in getVariants() I return both fields.
>>> But the popup for auto-completion only shows the members. So the
>>> static stuff is somehow filtered out.
>>> Same applies to static methods.
>>>
>>> So how do I get this working?
>>
>>
>>
>>
Hi,
Maybe your settings have not set 'Show statics after instance'
completion option and completion filters it out then (pretty weird side
effect for custom completion data).
Sven Steiniger wrote:
>> Empty string.
>>
>> Maxim Mossienko schrieb:
>>
>>> What is the prefix for the completion?
>>>
>>> Sven Steiniger wrote:
>>>
>>>> I got this working most time by return PsiElement or Strings.
>>>> But still the internal matchign algorithm is hidden.
>>>> Having an reference I return both, a member field and a constant.
>>>> public String field1;
>>>> public static final String constant1="";
>>>> in getVariants() I return both fields.
>>>> But the popup for auto-completion only shows the members. So the
>>>> static stuff is somehow filtered out.
>>>> Same applies to static methods.
>>>>
>>>> So how do I get this working?
>>>
>>>
>>>
>>>
>>>
--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"
Yes, that's it. But why is it applied? It always occurs, no matter
if there is a dot in front of it or if the previous expression just
resolves to PsiClass.
How can I change this behaviour?
I remember having seen some event somewhere. But don't remember where
and don't know how to fire.
Maxim Mossienko schrieb:
>> Any comments?
>> I have installed an own CompletionData which derives from
>> HtmlCompletionData. So from debugging I know that
>> findPrefix() returns "".
>>
>> Sven Steiniger schrieb:
>>
>>> Empty string.
>>>
>>> Maxim Mossienko schrieb:
>>>
>>>> What is the prefix for the completion?
>>>>
>>>> Sven Steiniger wrote:
>>>>
>>>>> I got this working most time by return PsiElement or Strings.
>>>>> But still the internal matchign algorithm is hidden.
>>>>> Having an reference I return both, a member field and a constant.
>>>>> public String field1;
>>>>> public static final String constant1="";
>>>>> in getVariants() I return both fields.
>>>>> But the popup for auto-completion only shows the members. So the
>>>>> static stuff is somehow filtered out.
>>>>> Same applies to static methods.
>>>>>
>>>>> So how do I get this working?
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
Field http://www.jetbrains.net/jira/browse/IDEA-5554
Sven Steiniger schrieb:
>> Hi,
>>
>> Maybe your settings have not set 'Show statics after instance'
>> completion option and completion filters it out then (pretty weird
>> side effect for custom completion data).