Bug 138356 - CALC Hyperlink button text corrupted with part of an embedded graphic image
Summary: CALC Hyperlink button text corrupted with part of an embedded graphic image
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.0.3.1 release
Hardware: All Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Hyperlink-Calc
  Show dependency treegraph
 
Reported: 2020-11-20 05:55 UTC by Colin
Modified: 2023-05-05 15:13 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Spreadsheet with corrupted hyperlink buttons (462.90 KB, application/vnd.oasis.opendocument.spreadsheet)
2020-12-25 11:52 UTC, Colin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Colin 2020-11-20 05:55:49 UTC
Description:
Hi,
I need advice on how or even if to report an intermittent bug.
Established, reliable five sheet CALC document with Hyperlinks to online spreadsheets which are accessed, select copied and pasted (sometimes enforced special) to the target sheets.
Recently updated to 
Version: 7.0.3.1 (x64)
Build ID: d7547858d014d4cf69878db179d326fc3483e082
CPU threads: 4; OS: Windows 10.0 Build 19041; UI render: Skia/Raster; VCL: win
Locale: sv-SE (en_GB); UI: en-GB
Calc: threaded
Three of five hyperlinks have the button image corrupted "randomly" - the corruption is part of an embedded image on the second sheet which simply replaces the text on the affected buttons, although the control properties retain the original text definitions.
The corruption does not affect buttons "preceding" the image - only those in the subsequent sheets.
I now believe it may be a result of the start process although originally I noticed it following website access.
My perception has now changed because last night 21:30 it was saved in perfect condition. First access this morning it is corrupt with zero processing or web access.
The "repaired" file functioned normally over two days and about 30 "button" web accesses.
Are hyperlinks somehow "verified" on startup?
I previously wrote a highly detailed report with "clean" & "corrupted" example attachments together with detailed process instructions and then it failed to misbehave so I abandoned it as "not easily reproducible".
Today, just the simple process of opening it triggered button image corruption.
How should I proceed?
Should I submit clean and corrupt versions of the file for somebody to periodically open and inspect?
Are you able to monitor code execution with a debugger?
Whilst it's really only cosmetic, I feel it is symptomatic of something far more significant - Would you disagree?


Steps to Reproduce:
Refer to description

Actual Results:
Corrupted hyperlink button image

Expected Results:
Uncorrupted hyperlink button image


Reproducible: Always


User Profile Reset: No


OpenGL enabled: Yes

Additional Info:
[Information automatically included from LibreOffice]
Locale: en-GB
Module: SpreadsheetDocument
[Information guessed from browser]
OS: Windows (All)
OS is 64bit: no
Comment 1 Colin 2020-11-20 06:04:51 UTC
Just realised something significant.
Many of my CALCs contain hyperlinks but this is the only one with an embedded graphic image - the graphic image that appears on the rogue buttons.
My apologies, I was focused on the rogue file to the exclusion of the other successful files.
Comment 2 Colin 2020-11-20 08:20:42 UTC
Further investigation (Form design mode and "stretch" the button corner to "fill" the page) reveals that the corruption of the button face has incorporated the entire graphic - not just the first "line"
Comment 3 Colin 2020-12-25 11:51:32 UTC
Added Simple Spreadsheet demonstrating the effect of Graphics upon Hyperlink Buttons.

The reason it was originally defined as intermittent is that the corruption was only apparent when a graphic image was embedded "somewhere" in the sheet and not all files had such objects.
As demonstrated, Hyperlinks on sheets preceding the graphic are intact whereas those on subsequent sheets are corrupted by the image.
Comment 4 Colin 2020-12-25 11:52:52 UTC
Created attachment 168478 [details]
Spreadsheet with corrupted hyperlink buttons
Comment 5 Regina Henschel 2021-02-07 01:05:21 UTC
It seems to be a kind of refresh problem. Open toolbar "Form Control" and switch to design mode. Right-click the hyperlink-button and select item "Control Properties". On tab "General" scroll down till item "Graphics". Open its drop-down list and close it. OK. Close dialog. Now the button should be repaired.

I see, that something is wrong, therefore I set it to "new". But I have not yet tested, whether the file itself has an error.
Comment 6 Colin 2021-02-07 04:54:15 UTC
(In reply to Regina Henschel from comment #5)
> It seems to be a kind of refresh problem. Open toolbar "Form Control" and
> switch to design mode. Right-click the hyperlink-button and select item
> "Control Properties". On tab "General" scroll down till item "Graphics".
> Open its drop-down list and close it. OK. Close dialog. Now the button
> should be repaired.
> 
> I see, that something is wrong, therefore I set it to "new". But I have not
> yet tested, whether the file itself has an error.

Is there anything you need me to do to verify the file integrity?

I can confirm the image source was a "screengrab" pasted to Irfanview then cropped before insertion into the sheet.
Also, but probably not too significant, I use two monitors on this PC together with "Mouse without Borders" to control two more PCs each having only one attached monitor. MwB is not always active but as you've proven - the error occurs regardless of my configuration.
I can't verify whether the setup may have been active at the time the image was copied, thereby introducing a file error that persists across PCs
Also, I confirm that having stripped the image from the original sheet it has never malfunctioned since.
Comment 7 Regina Henschel 2021-02-07 13:05:32 UTC
I have now inspected the attached file: The formal structure of the file is OK. But the buttons on 3. and 4. sheet have the form attribute "form:image-data" which should not be there. This attribute belongs to an image button ("form:image" in file source). But these are simple push buttons ("form:button" in file source).

To investigate further we need a step-by-step description, which _reproducible_ creates such buttons. Only if a developer can reproduce it, it is possible to fix, that such attribute is added to a push button.
Comment 8 Regina Henschel 2021-02-07 13:57:13 UTC
(In reply to Regina Henschel from comment #7)
> form attribute "form:image-data" which should not be there.

I was not correct. A push button can have an "form:image-data" attribute. Then the image is shown in addition to the label text. But here this was not intended. So the question remains, how it was generated.
Comment 9 Colin 2021-02-07 14:10:43 UTC
(In reply to Regina Henschel from comment #7)
> I have now inspected the attached file: The formal structure of the file is
> OK. But the buttons on 3. and 4. sheet have the form attribute
> "form:image-data" which should not be there. This attribute belongs to an
> image button ("form:image" in file source). But these are simple push
> buttons ("form:button" in file source).
> 
> To investigate further we need a step-by-step description, which
> _reproducible_ creates such buttons. Only if a developer can reproduce it,
> it is possible to fix, that such attribute is added to a push button.

If it's feasible to utilise the existing file then it should be a simple matter to delete the three corrupt buttons and then simply recreate them using the normal procedure for creating a hyperlink button. It would be an advantage to note the existing links and re-use them.
If I remember correctly, the face text simply said "Source" which was entered into the appropriate parameter at creation. 
It's then just a matter of opening the links a few times - I actually used them to capture data which was then pasted into the appropriate places.
The corruption does not occur immediately and I can't define how many times I used the buttons to access the data prior to the corruption. As you can imagine, their physical location apprised me of their function so it was probably more "muscle memory" than sentient utilisation.
I accept the later verbose definition is simply a description of the operation for which I can provide a fully functional file and instructions on how to select the appropriate data from the "source" locations and distribute it accordingly but I suspect that's overkill. Bear in mind - that's what I was doing when the error manifested itself. I can possibly just produce a step by step procedure for creating five hyperlink buttons over five spreadsheet pages and then inserting a graphic image (also a web site "cut & paste") but I imagine the developers already know how to create five hyperlink buttons to anything and then "grab & paste" a screen image into a sheet half way through the file so they have the sequence:-
Sheet 1 create hyperlink button
Sheet 2 create hyperlink button
Sheet 3 leave blank
Sheet 4 create hyperlink button
Sheet 5 create hyperlink button
Screen grab anything from the internet
Crop it with Irfanview
Insert it anywhere into sheet 3
1 Cycle through activating the hyperlinks
2 Close and save the file
3 Open the file and cycle through activating the hyperlinks
4 Close and save the file
Repeat 3 & 4 until corruption occurs

At some stage the butttons will become corrupt but I'm unsure whether it coincides with activation of the Hyperlinks or closing and reopening.

The genuine sheet comprises five pages as does the example provided. The "source" buttons link to a collection of downloadable Excel sheets or CSVs which I simply identify, download and open with LO and paste to the appropriate locations. It's generally a paste special because the data is used to create a complex array with conditional fomatting, a pair of simple columnar arrays, three discrete columnar arrays with charts and conditional colour formatting "Temperature Charts". The final Source button links to a dynamic array on the website where I simply highlight the data array without the headers and paste special as unformatted text. I also have a "map" which picks up the simple vertical column of data produced from the website array and transposes selected data to columns which are then referred to from the first sheet.
All the data is "public domain". If desired I can provide the live file with or without the hyperlink buttons or the graphic for the developer to build the hyperlinks and insert a graphic.
For the record, my live file no longer includes the graphic but I can't remember if I removed it and it immediately remediated or whether I simply removed the hyperlinks and the graphic then recreated hyperlinks.
Even if my live file is utilised and modified to recreate the symptoms, it's more a case of "working" the sheet for its designed purpose and watch it fail.
Comment 10 Colin 2021-02-07 14:18:05 UTC
Clutching at straws, there are quite a few reports concerning general failings of the cutting & pasting functionality. Is it conceivable this just symptomatic of another facet of that issue?
Cut and paste from a website causing corruption to related hyperlinks
Comment 11 QA Administrators 2023-02-08 03:24:41 UTC Comment hidden (obsolete)
Comment 12 Colin 2023-02-08 06:44:58 UTC
(In reply to QA Administrators from comment #11)
> Dear Colin,
> 
> To make sure we're focusing on the bugs that affect our users today,
> LibreOffice QA is asking bug reporters and confirmers to retest open,
> confirmed bugs which have not been touched for over a year.

Still present in
 
Version: 7.4.5.1 (x64) / LibreOffice Community
Build ID: 9c0871452b3918c1019dde9bfac75448afc4b57f
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: sv-SE (en_GB); UI: en-GB
Calc: threaded