D9491: Sonnet: fix wrong language for suggestions in mixed-language texts

Dominik Haumann noreply at phabricator.kde.org
Sun Dec 24 11:59:35 UTC 2017


dhaumann accepted this revision.
dhaumann added a comment.


  Good enough :)

INLINE COMMENTS

> highlighter.cpp:487
> +    QStringList suggestions = d->spellchecker->suggest(word);
> +    if (max != -1 && suggestions.count() > max) {
> +        suggestions = suggestions.mid(0, max);

I am not a big fan of -1 in this use case. What about -2 etc, or even 0? So this API easily leads to unexpected results.

But ok, my comment is unrelated to your patch.

REPOSITORY
  R246 Sonnet

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D9491

To: dfaure, sandsmark, mlaurent, dhaumann
Cc: dhaumann, #kde_pim, #frameworks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20171224/e98a87cf/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list