Reduce temporary allocations.

Review Request #123930 - Created May 28, 2015 and submitted

Information
Milian Wolff
sonnet
master
779a676...
Reviewers
kdeframeworks
dfaure, mlaurent, sandsmark, sars

Access setting's default language directly without constructing
temporary Speller objects, which is extremely costly with the
internal dictionary loading.

Also, don't create the speller object and then set the language
afterwards, pass it directly to the ctor. This removes a potential
pessimization when the language is not equal to the default language.

Use one central cache for the SpellerPlugins.

Creating these speller plugins is very expensive and the data
they operate on can / should be shared as much as possible.

This speeds up automatic spell checking immensely, especially
when automatic language detection is enabled.

REVIEW: 123930

ran katepart again - much quicker now, even with auto-language-detection enabled! unit test still work as well.

Kåre Särs
Milian Wolff
Milian Wolff
Laurent Montel
Milian Wolff
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit 779a676d46567df4db29445e689ff9ddb6368616 by Milian Wolff to branch master.
Loading...