Bug 118842 - Pasting text from webpage then cancelling, lines are not reset to default size
Summary: Pasting text from webpage then cancelling, lines are not reset to default size
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Undo-Redo
  Show dependency treegraph
 
Reported: 2018-07-19 09:01 UTC by Julien ROPE
Modified: 2023-11-01 03:14 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Example of text pasted then cancelled (7.93 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-07-19 09:01 UTC, Julien ROPE
Details
Force an AdjustRowHeight call after the undo (531 bytes, patch)
2018-07-26 08:04 UTC, Julien ROPE
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Julien ROPE 2018-07-19 09:01:36 UTC
Created attachment 143636 [details]
Example of text pasted then cancelled

The problem occurs when copying formatted text from a webpage.
 When pasting it, the lines height is modified.
 When you use Ctrl+Z (or click the corresponding menu), the text is removed, but the lines height is unmodified.

 Forcing the height to "auto" on the faulty lines resolves the problem.

 If you copy content from another libreoffice component, the problem doesn't happen.
 The copy must be done on formatted text - plain text won't trigger the bug.

 Attaching a file containing two tabs: one with the text I used (from this very bug file creation webpage), the other with the result of a "ctrl+z" executed after the paste.
Comment 1 Julien ROPE 2018-07-19 09:05:14 UTC
 
 Found with v5.4.7.2 on Windows
 Reproduced with v6.0.3.2 on Linux
Comment 2 V Stuart Foote 2018-07-19 12:29:17 UTC
Confirmed on Windows 10 Home 64-bit en-US with
a current master/6.2.0

Version: 6.2.0.0.alpha0+ (x64)
Build ID: daafe79c55cd53decbeac2367f298d79371dcf3d
CPU threads: 4; OS: Windows 10.0; UI render: GL; 
TinderBox: Win-x86_64@42, Branch:master, Time: 2018-07-18_02:59:18
Locale: en-US (en_US); Calc: CL

reopening the example document has reset the optimal height for the cleared cells, but the Paste -> Ctrl+Z (or the Undo) of insert of formatted text into several rows is leaving behind the direct formatting applied to cells on undo.
Comment 3 V Stuart Foote 2018-07-19 13:54:01 UTC
@Julien, assigning the bug to yourself implies you are taking the issue and will provide patch in source code to correct the issue. 

If that is the case, fine. Otherwise, suggest you remove yourself as assignee.
Comment 4 Julien ROPE 2018-07-19 14:59:31 UTC
 @Stuart, I am working on it, and hopefully will find the bug and fix it.
 Whether or not I succeed is another question of course :-/

 Should I wait to have a fix to assign the bug to myself ?
Comment 5 V Stuart Foote 2018-07-19 16:57:52 UTC
(In reply to Julien ROPE from comment #4)
>  @Stuart, I am working on it, and hopefully will find the bug and fix it.
>  Whether or not I succeed is another question of course :-/
> 
>  Should I wait to have a fix to assign the bug to myself ?

No, keep it assigned and have at it...

If you get stuck ask for help on the Dev ML, and should you throw in the towel, just remove yourself as assignee.
Comment 6 Julien ROPE 2018-07-26 08:04:54 UTC
Created attachment 143769 [details]
Force an AdjustRowHeight call after the undo


 I could work around the issue by forcing an "AdjustRowHeight()" call after the undo, making sure the modified range's rows are restored.
 Now I'm not sure that is the proper way of fixing it, as it doesn't address the root cause (which still eludes me).

 Any comment/suggestion is welcome.
Comment 7 Xisco Faulí 2018-10-30 13:20:52 UTC
Dear Julien ROPE,
This bug has been in ASSIGNED status for more than 3 months without any
activity. Resetting it to NEW.
Please assigned it back to yourself if you're still working on this.
Comment 8 QA Administrators 2019-10-31 03:35:50 UTC Comment hidden (obsolete)
Comment 9 QA Administrators 2021-10-31 04:01:48 UTC Comment hidden (obsolete)
Comment 10 QA Administrators 2023-11-01 03:14:10 UTC
Dear Julien ROPE,

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.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the information from Help - About LibreOffice.
 
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice.

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)


If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to 'inherited from OOo';
4b. If the bug was not present in 3.3 - add 'regression' to keyword


Feel free to come ask questions or to say hello in our QA chat: https://web.libera.chat/?settings=#libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team

MassPing-UntouchedBug