<table><tr><td style="">ahmadsamir updated this revision to Diff 61881.<br />ahmadsamir retitled this revision from "Add a config to only show completions matching word beginning" to "With auto completion don't show completions that don't match from beginning of typed word".<br />ahmadsamir edited the summary of this revision. <a href="https://phabricator.kde.org/transactions/detail/PHID-XACT-DREV-ynejfuvknr5banm/">(Show Details)</a><br />ahmadsamir edited the test plan for this revision. <a href="https://phabricator.kde.org/transactions/detail/PHID-XACT-DREV-5ocsusc32jtn4te/">(Show Details)</a><br />ahmadsamir added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D22477">View Revision</a></tr></table><br /><div><div><p>Ver-bloody-batim</p></div></div><br /><div><strong>CHANGES TO REVISION SUMMARY</strong><div><div style="white-space: pre-wrap; color: #74777D;"><span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">This disables the current behaviour where if no match is found,</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">When invoking auto completion for a word, don't show the completions<br />
menu if the available matches don't match the beginning of the word<br />
typed by the user.<br />
<br />
Previously if no matches were found, the completions menu was invoked<br />
if there were completion items that "contained" the matched word (not<br />
at the beginning of the matches), if that word appeared at a word</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">completions that "contain" the word to-be-completed</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">beginning, which was marked by a capital letter or an underscore</span>, <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">and that are at</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">e.g.</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">a word beginning (marked by a capital letter or an underscore),</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">"Foo" would match "BarFoo" and "Bar_Foo".</span> <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">are added</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">The user can still maunally</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">to the list of completion items; e.g. Foo will match BarFoo and Bar_Foo</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">the menu.<br />
<br />
Use range for instead of foreach</span>.<div style="padding: 8px 0;">...</div></div></div></div><br /><div><strong>CHANGES TO TEST PLAN</strong><div><div style="white-space: pre-wrap; color: #74777D;"><div style="padding: 8px 0;">...</div>Bar_Foo<span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);"><br />
<br />
- Type: foo</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">- Enable the new config option and type Foo; check if BarFoo or Bar_Foo</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">- Check that the auto completions menu isn't shown</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);"> are offered as</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">- Check that manually invoking the menu, shows the</span> completions<span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);"> that</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">- Diable the config and repeat</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);"> "contain"</span> the <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">above step</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">typed word</span>.</div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R39 KTextEditor</div></div></div><br /><div><strong>CHANGES SINCE LAST UPDATE</strong><div><a href="https://phabricator.kde.org/D22477?vs=61879&id=61881">https://phabricator.kde.org/D22477?vs=61879&id=61881</a></div></div><br /><div><strong>BRANCH</strong><div><div>less-trigger-happy-completions (branched from master)</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D22477">https://phabricator.kde.org/D22477</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>src/completion/katecompletionmodel.cpp<br />
src/completion/katecompletionmodel.h</div></div></div><br /><div><strong>To: </strong>ahmadsamir, KTextEditor, cullmann, dhaumann, KDevelop, kossebau, mwolff, kfunk<br /><strong>Cc: </strong>brauch, kwrite-devel, kde-frameworks-devel, LeGast00n, sbergeron, domson, michaelh, ngraham, bruns, demsking, cullmann, sars, dhaumann<br /></div>