Fix empty pages in print preview and lines printed twice

Authored by hoffmannrobert on Jun 29 2019, 12:52 PM.

Description

Fix empty pages in print preview and lines printed twice

Summary:
There were errors if a page's last line is too long and needs to be
wrapped into two or more lines:

  • The first line of the wrapped lines was printed correctly at the end of the page, but on the next page this first line was printed again.
  • In print preview the first wrapped line was shown correctly at the end of the page, but the next and following pages were empty.

Reasons:

  • remainder variable was always 0
  • clipping was not reset

BUG: 348598

Test Plan:
In Kate, open a text file that has long lines. Check lines at page ends
which are wrapped to the next page. Check printing and print preview.

Reviewers: Kate, KTextEditor, dhaumann

Reviewed By: Kate, KTextEditor, dhaumann

Subscribers: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel

Tags: Kate, Frameworks

Differential Revision: https://phabricator.kde.org/D21563

Details

Committed
dhaumannJun 29 2019, 8:26 PM
Reviewer
Kate
Differential Revision
D21563: Fix empty pages in print preview and lines printed twice
Parents
R39:deb27c1bb429: remove no longer used header
Branches
Unknown
Tags
Unknown