Bug 99333 - Spreadsheet saved in print preview mode opens with blank preview
Summary: Spreadsheet saved in print preview mode opens with blank preview
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
3.5.7.2 release
Hardware: All All
: medium normal
Assignee: Markus Mohrhard
URL:
Whiteboard: target:5.3.0
Keywords: bibisected, regression
Depends on:
Blocks:
 
Reported: 2016-04-15 16:42 UTC by Yousuf Philips (jay) (retired)
Modified: 2016-08-08 04:07 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
sample (7.63 KB, application/vnd.oasis.opendocument.spreadsheet)
2016-04-15 16:43 UTC, Yousuf Philips (jay) (retired)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yousuf Philips (jay) (retired) 2016-04-15 16:42:53 UTC
Steps:
1) Open attached file, which was saved while in print preview mode
2) Preview is blank with the text 'No Data' and the status bar says 'Page 1 / 0'
3) Click 'Close Preview' button
4) Re-enter print preview mode and preview is there and status bar says 'Page 1 / 3'

Regression as it works in 3.4.6.

Version: 5.2.0.0.alpha0+
Build ID: 92d7fef02574051826e46a3a7e3d33a1afa062d7
CPU Threads: 2; OS Version: Linux 4.2; UI Render: default; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2016-04-14_03:19:54
Locale: en-US (en_US.UTF-8)
Comment 1 Yousuf Philips (jay) (retired) 2016-04-15 16:43:36 UTC
Created attachment 124374 [details]
sample
Comment 2 raal 2016-04-15 18:05:03 UTC
git bisect log 
# bad: [423a84c4f7068853974887d98442bc2a2d0cc91b] source-hash-c15927f20d4727c3b8de68497b6949e72f9e6e9e
# good: [65fd30f5cb4cdd37995a33420ed8273c0a29bf00] source-hash-d6cde02dbce8c28c6af836e2dc1120f8a6ef9932
git bisect start 'latest' 'oldest'
# bad: [e02439a3d6297a1f5334fa558ddec5ef4212c574] source-hash-6b8393474974d2af7a2cb3c47b3d5c081b550bdb
git bisect bad e02439a3d6297a1f5334fa558ddec5ef4212c574
# bad: [8f4aeaad2f65d656328a451154142bb82efa4327] source-hash-1885266f274575327cdeee9852945a3e91f32f15
git bisect bad 8f4aeaad2f65d656328a451154142bb82efa4327
# bad: [369369915d3582924b3d01c9b01167268ed38f3b] source-hash-45295f3cdceb4c289553791071b5d7f4962d2ec4
git bisect bad 369369915d3582924b3d01c9b01167268ed38f3b
# bad: [351622aec2dff3cc3bbbb020ad0097c4322d2a21] source-hash-2c4537471c932b65e6f72e41881b505c4bbad12c
git bisect bad 351622aec2dff3cc3bbbb020ad0097c4322d2a21
# good: [035c276ec5a8da669e6043a3db6b0701dd3c2ade] source-hash-dc8249af103741415a074d9bbf8b1211f24a7c3f
git bisect good 035c276ec5a8da669e6043a3db6b0701dd3c2ade
# good: [035c276ec5a8da669e6043a3db6b0701dd3c2ade] source-hash-dc8249af103741415a074d9bbf8b1211f24a7c3f
git bisect good 035c276ec5a8da669e6043a3db6b0701dd3c2ade
# good: [035c276ec5a8da669e6043a3db6b0701dd3c2ade] source-hash-dc8249af103741415a074d9bbf8b1211f24a7c3f
git bisect good 035c276ec5a8da669e6043a3db6b0701dd3c2ade
# good: [035c276ec5a8da669e6043a3db6b0701dd3c2ade] source-hash-dc8249af103741415a074d9bbf8b1211f24a7c3f
git bisect good 035c276ec5a8da669e6043a3db6b0701dd3c2ade
# good: [d1cca78ab77d64482b6643bc643d29dbe2dd1442] source-hash-2d19e9bb07ccff3134f855812dddfda5c07b1fe4
git bisect good d1cca78ab77d64482b6643bc643d29dbe2dd1442
# good: [3a7ba13e401ac1314a63aede2dfb1f7168332d99] source-hash-ab63c12395ed3771b1df6822eaa8572c06db0765
git bisect good 3a7ba13e401ac1314a63aede2dfb1f7168332d99
# good: [9129c082f5b2d5de76f6492cc51def8c97397580] source-hash-ab407ad86610a0aba882b03075319e0b62b2c8d3
git bisect good 9129c082f5b2d5de76f6492cc51def8c97397580
# good: [6d96089d0712380f1a3a204f6e9ae6cd0ca47099] source-hash-ceb55cd688cebede8cef8408540019fe54528869
git bisect good 6d96089d0712380f1a3a204f6e9ae6cd0ca47099
# first bad commit: [351622aec2dff3cc3bbbb020ad0097c4322d2a21] source-hash-2c4537471c932b65e6f72e41881b505c4bbad12c

http://cgit.freedesktop.org/libreoffice/core/log/?qt=range&q=ceb55cd688cebede8cef8408540019fe54528869..2c4537471c932b65e6f72e41881b505c4bbad12c

Maybe this one: author	Kohei Yoshida <kohei.yoshida@suse.com>	2011-11-29 03:15:03 (GMT)
committer	Kohei Yoshida <kohei.yoshida@suse.com>	2011-11-29 05:04:23 (GMT)
commit 7a16f31752990abd1d0d4afc682259b67f24ea60 (patch)
tree d82c52250d305d715904ba55870d43577fa28a81
parent ffca779f3765f730cc9f4f416b728ecdf762931c (diff)
New UNO API to return currently selected sheets.
Both from the sheet view and preview modes.
Comment 3 Yousuf Philips (jay) (retired) 2016-04-16 15:15:40 UTC
@Eike: Do you think this is important enough to fix or should we just disable the activation of print preview mode on opening of a document saved in print preview mode?
Comment 4 Terrence Enger 2016-06-30 15:04:05 UTC
Funnily enough, this sounds like bug 48348, which was fixed in June, 2012.
Comment 5 Yousuf Philips (jay) (retired) 2016-07-01 07:38:58 UTC
(In reply to Terrence Enger from comment #4)
> Funnily enough, this sounds like bug 48348, which was fixed in June, 2012.

Yes it is the same issue but i dont think the fix is the correct thing, as files coming from AOO still show this problem if they are saved in print preview mode.
Comment 6 Commit Notification 2016-08-08 04:07:06 UTC
Markus Mohrhard committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=87ef2d8f2808a951c92387ba0582ea02a19f89e7

workaround missing SetSelectedSheet call for print preview, tdf#99333

It will be available in 5.3.0.

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

Affected users are encouraged to test the fix and report feedback.