D21563: Fix empty pages in print preview and lines printed twice

2020-01-10 Thread Robert Hoffmann
hoffmannrobert added a comment.


  In D21563#584484 , @hoffmannrobert 
wrote:
  
  > In D21563#584218 , @dhaumann 
wrote:
  >
  > > @hoffmannrobert: Are you maybe also interested in looking into 
https://bugs.kde.org/show_bug.cgi?id=415570 ? It's again about printing, this 
time about the very last line that seems to be wrong...
  >
  >
  > Yes, I can reproduce the bug. I'll look into it in about two weeks.
  
  
  See https://phabricator.kde.org/D26560

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
GB_2, domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-12-30 Thread Robert Hoffmann
hoffmannrobert added a comment.


  In D21563#584220 , @dhaumann wrote:
  
  > @hoffmannrobert: by the way, looking at your phabricator activity, you 
should get a KDE contributor account, if you don't have one already.
  
  
  I applied for one and added you as a supporter, thanks.

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
GB_2, domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-12-30 Thread Robert Hoffmann
hoffmannrobert added a comment.


  In D21563#584218 , @dhaumann wrote:
  
  > @hoffmannrobert: Are you maybe also interested in looking into 
https://bugs.kde.org/show_bug.cgi?id=415570 ? It's again about printing, this 
time about the very last line that seems to be wrong...
  
  
  Yes, I can reproduce the bug. I'll look into it in about two weeks.

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
GB_2, domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-12-29 Thread Dominik Haumann
dhaumann added a comment.


  @hoffmannrobert: by the way, looking at your phabricator activity, you should 
get a KDE contributor account, if you don't have one already.

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
GB_2, domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-12-29 Thread Dominik Haumann
dhaumann added a comment.


  @hoffmannrobert: Are you maybe also interested in looking into 
https://bugs.kde.org/show_bug.cgi?id=415570 ? It's again about printing, this 
time about the very last line that seems to be wrong...

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
GB_2, domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-29 Thread Dominik Haumann
dhaumann closed this revision.
dhaumann added a comment.


  Fixed for KF 5.60 with commit 6bbbe6aa51c0a293a58dbca6223e37a73ce32122, 
thanks for the patch - keep it coming!

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-29 Thread Dominik Haumann
dhaumann accepted this revision.
dhaumann added a comment.
This revision is now accepted and ready to land.


  I just tested kwrite from master with Qt 5.12.0, and printing was completely 
broken. It even printed on Letter even though I specified A4 paper. A Qt update 
to Qt 5.12.3 fixed this - good so far.
  
  Indeed I can reproduce the following: If I have a line that wraps to the next 
page, the line is printed twice. With this patch, it works!

REPOSITORY
  R39 KTextEditor

BRANCH
  fix_preview_and_printing

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

To: hoffmannrobert, #kate, #ktexteditor, dhaumann
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-28 Thread Robert Hoffmann
hoffmannrobert added a comment.


  In D21563#487947 , @cullmann wrote:
  
  > I tried to reproduce the issue with and without this fix but I somehow fail.
  >  Has somebody else more luck?
  
  
  Try with long log files like boot.log, dmesg.log or journalctl output. Open 
print preview and scroll down. After some pages there will be only blank pages 
or just one or two lines of text at the end of a page.

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-28 Thread Dominik Haumann
dhaumann added a comment.


  I will test tomorrow ;)

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-28 Thread Christoph Cullmann
cullmann added a comment.


  I tried to reproduce the issue with and without this fix but I somehow fail.
  Has somebody else more luck?

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor
Cc: cullmann, dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, 
domson, michaelh, bruns, demsking, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-23 Thread Nathaniel Graham
ngraham edited the summary of this revision.
ngraham added reviewers: Kate, KTextEditor.

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert, #kate, #ktexteditor
Cc: dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, domson, 
michaelh, bruns, demsking, cullmann, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-23 Thread Dominik Haumann
dhaumann added a comment.


  Many years ago I also stumbled over this bug, and I know for sure it never 
was fixed. If this fix really works then this would be really great! That said 
I have not yet tried the patch but am positive to get this in soon!

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert
Cc: dhaumann, ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, domson, 
michaelh, bruns, demsking, cullmann, sars


D21563: Fix empty pages in print preview and lines printed twice

2019-06-23 Thread Robert Hoffmann
hoffmannrobert added a comment.


  It fixes this bug: https://bugs.kde.org/show_bug.cgi?id=348598

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert
Cc: ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, domson, michaelh, 
bruns, demsking, cullmann, sars, dhaumann


D21563: Fix empty pages in print preview and lines printed twice

2019-06-23 Thread Robert Hoffmann
hoffmannrobert added a comment.


  In D21563#473734 , @ngraham wrote:
  
  > Fixes https://bugs.kde.org/show_bug.cgi?id=376270?
  
  
  No, that's something different. That is apparently a duplicate of 
https://bugs.kde.org/show_bug.cgi?id=391678 which is already fixed: 
https://phabricator.kde.org/D18163

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert
Cc: ngraham, kwrite-devel, kde-frameworks-devel, LeGast00n, domson, michaelh, 
bruns, demsking, cullmann, sars, dhaumann


D21563: Fix empty pages in print preview and lines printed twice

2019-06-03 Thread Nathaniel Graham
ngraham added a comment.


  Fixes https://bugs.kde.org/show_bug.cgi?id=376270?

REPOSITORY
  R39 KTextEditor

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

To: hoffmannrobert
Cc: ngraham, kwrite-devel, kde-frameworks-devel, domson, michaelh, bruns, 
demsking, cullmann, sars, dhaumann


D21563: Fix empty pages in print preview and lines printed twice

2019-06-03 Thread Robert Hoffmann
hoffmannrobert created this revision.
Herald added projects: Kate, Frameworks.
Herald added subscribers: kde-frameworks-devel, kwrite-devel.
hoffmannrobert requested review of this revision.

REVISION 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

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.

REPOSITORY
  R39 KTextEditor

BRANCH
  fix_preview_and_printing

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

AFFECTED FILES
  src/printing/printpainter.cpp

To: hoffmannrobert
Cc: kwrite-devel, kde-frameworks-devel, domson, michaelh, ngraham, bruns, 
demsking, cullmann, sars, dhaumann