Bug 128672 - Print dialog's N-Up preview doesn't update properly (non-gtk3)
Summary: Print dialog's N-Up preview doesn't update properly (non-gtk3)
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.4.0
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Print-Dialog
  Show dependency treegraph
 
Reported: 2019-11-08 12:36 UTC by Michael Weghorn
Modified: 2019-11-08 16:19 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Screencast showing the issue (2.66 MB, video/webm)
2019-11-08 12:36 UTC, Michael Weghorn
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Weghorn 2019-11-08 12:36:58 UTC
Created attachment 155636 [details]
Screencast showing the issue

Steps to reproduce:

0) use the "gen" or "kf5" VCL plugin
1) open a new Writer document
2) press Ctrl+P to open print dialog
3) set value for "Pages per sheet" to 4
4) set value for "Pages per sheet" to 4

Actual result: The numbers for the pages are added to the n-up-preview, but the previous ones are not cleared, so the display is messed up (s. attached screencast).

Expected result: Only the numbers for the new arrangement should be shown.

Notes: Works as expected when using the gtk3 VCL plugin.

Version: 6.4.0.0.alpha0+
Build ID: bab77fcf8b80594fb49561254dfbaea381da8934
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: kf5; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: threaded
Comment 1 Michael Weghorn 2019-11-08 12:39:14 UTC
This happens since the dialog was welded in

commit bab77fcf8b80594fb49561254dfbaea381da8934
Author: Caolán McNamara <caolanm@redhat.com>
Date:   Tue Oct 1 10:20:29 2019 +0100

    weld PrintDialog
    
    Change-Id: Id4adbe484f88be74f45dab8e7ef426c66e5cbc8b
    Reviewed-on: https://gerrit.libreoffice.org/80002
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm@redhat.com>
    Tested-by: Caolán McNamara <caolanm@redhat.com>

Adding CC: to Caolán McNamara <caolanm@redhat.com>
Comment 2 Xisco Faulí 2019-11-08 13:12:35 UTC
Reproduced in

Version: 6.4.0.0.alpha1+
Build ID: 498c2d3944b666c2f016b65903001920db2cb2a4
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: x11; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded
Comment 3 Julien Nabet 2019-11-08 13:14:56 UTC
On Win10 with master sources updated today, I could reproduce this.
Comment 4 Julien Nabet 2019-11-08 13:39:03 UTC
Taking a look to https://cgit.freedesktop.org/libreoffice/core/commit/?id=bab77fcf8b80594fb49561254dfbaea381da8934, it seems "mxPreviewWindow" is not really used.
Indeed, we've got only:
- std::unique_ptr<weld::CustomWeld> mxPreviewWindow;
- mxPreviewWindow(new weld::CustomWeld(*m_xBuilder, "preview", *mxPreview))
Comment 5 Caolán McNamara 2019-11-08 13:47:02 UTC
its a pretty cool looking effect though
Comment 6 Commit Notification 2019-11-08 14:52:39 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/7719b7fb93d42d9ff524c869ba9e347ff040025c

Resolves: tdf128672 nup missing erase of old content

It will be available in 6.4.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Michael Weghorn 2019-11-08 16:19:42 UTC
(In reply to Caolán McNamara from comment #5)
> its a pretty cool looking effect though

True, let's hope nobody complains about it being gone now.

Thanks for the super-quick fix, verified with

Version: 6.4.0.0.alpha1+
Build ID: 76762b4c9899787a32d71bf5ed7695e22eccbc4c
CPU threads: 4; OS: Linux 5.2; UI render: default; VCL: kf5; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: threaded