开发者

Autocompletion with qcompleter for fragments in the middle of a word [duplicate]

开发者 https://www.devze.com 2022-12-08 01:43 出处:网络
This question already has answers here: QCompleter Custom Completion Rules (8 answers) Closed 6 years ago.
This question already has answers here: QCompleter Custom Completion Rules (8 answers) Closed 6 years ago.

Is there an example available of a QCompleter subclass that will provide autocompletions for fragments that appear in the middle of words?

eg:

Suppose you have the wordlist { "apple", "pear", "banana" }. When the user types 'p', the suggested autocompletions should be "apple" and "pear", but not banana (because "apple" and "pear" both contain 'p'); The default autocompletion will only su开发者_StackOverflow中文版ggest "pear".


QtCreator 1.3 (that will be release soon) will have an extended completion that will allow to find a function by indicating only capital letter. See the video : http://www.youtube.com/watch?v=TyfO-7lvy_c&feature=player_embedded.

This is a behavior near to the one you want. Since QtCreator is open source you can have a look to its source code for a real example. For now I do not know the release date of this version so you will have to wait a little to see.

0

精彩评论

暂无评论...
验证码 换一张
取 消