Details
-
Bug
-
Resolution: Incomplete
-
Not Evaluated
-
None
-
4.7.4, 4.8.1, 4.8.2
-
None
-
Windows 7 64bit MSVC 2008, Mac OSX 10.7
Description
We have an application where pressing an alpha-numeric character brings up a sub-dialog with a single QLineEdit. The QLineEdit has a completer and when the sub-dialog is show()n, we want completions to start immediately.
Attached is a bare bones example of what we're doing. The application event loop is filtered and when an alpha-numeric key is pressed, the modal dialog is show()n. The text of the key press is added to the sub dialog's line edit and complete() is manually called on the completer for the line edit to begin completions immediately.
This works as expected when the completion mode is NOT QCompleter::InlineCompletion. Eg. if you comment out the line in dialogs.cpp that sets that mode, so that the default completer mode is used, then the sub-dialog shows the correct completion if there is a match, or no completion if there is not one. Eg. if you type 'f' then when the sub-dialog is shown you see 'flyingFox' as the offered completion.
However if QCompleter::InlineCompletion is set, for any key press, 'abc123' is always shown as the initial match. If you type 'f' at the main dialog again, this time the sub-dialog pops up with 'f' as the first character and then 'bc123' as the offered completion. This is incorrect.