Fix insane delay in report items creation
Summary:
Fix insane delay in report items creation by not instantiating hi-resolution QPrinter object for each item.
To be honest I am not understanding the whole word-wrapping algorithm used here.
Test Plan:
Approach 1: Run KEXI and create report with large number of pages. Use at
least one text element.
Before the fix there's noticeable O(N) delay.
Approach 2: Also if we enter static value for the text item the kreportexample
app, there is noticeable delay on each key press before this fix.
Expected: all is smooth after the fix.
Reviewers: piggz
Reviewed By: piggz
Subscribers: Kexi-Devel-list
Tags: KReport
Differential Revision: https://phabricator.kde.org/D25108