CompletionItem not shown if autoCompletePreText is different from text

SyntaxEditor for WPF Forum

Posted 12 years ago by Matt Yaeger
Version: 12.1.0562
Platform: .NET 4.0
Environment: Windows 7 (64-bit)
Avatar

I have the following two CompletionItems that are added to a CompletionSession when the letter 'f' is typed but  only one item is shown (the one that the text and pretext match is shown).  If I press backspace to clear the 'f' (but session is still open) then both items are visible.  Is this expected?  If so, how do I get both completion items to be displayed initially?  Also, the match options set on the session are IsCaseSensitive and UseAcronyms.  No filters are enabled.

 

CompletionItem("foobar", imageProvider, new DirectContentProvider("desc"), "foobar", null)

CompletionItem("foobar2", imageProvider, new DirectContentProvider("desc"), "baz", null)

 

Thanks,

 

Matt Yaeger

Comments (2)

Answer - Posted 12 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Matt,

It sounds like you have the CanFilterUnmatchedItems feature on your session.  That will shrink the list down to only the things that match what is being typed.  There is info on that in the documentation.

Also matches by default work against the pre-text.  If you want it to match based on the displayed text instead, you'd want to set the CompletionMatchOptions.TargetsDisplayText option.


Actipro Software Support

Posted 12 years ago by Matt Yaeger
Avatar

Achh, that's my fault. I missed the CompletionMatchOptions.TargetsDisplayText option.  Thanks.

The latest build of this product (v24.1.3) was released 26 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.