Bug 134925 - Reset doesn't work properly for table column width
Summary: Reset doesn't work properly for table column width
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:7.1.0
Keywords:
: 132610 (view as bug list)
Depends on:
Blocks: Writer-Tables
  Show dependency treegraph
 
Reported: 2020-07-18 07:52 UTC by Telesto
Modified: 2020-08-22 19:54 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file (8.41 KB, application/vnd.oasis.opendocument.text)
2020-07-18 07:52 UTC, Telesto
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Telesto 2020-07-18 07:52:41 UTC
Description:
Reset doesn't work properly for table column width

Steps to Reproduce:
1. Open the attached file
2. Table -> Properties -> Column tab
3. Type 20 for column width column 1
4. Press Reset


Actual Results:
Not resetting properly

Expected Results:
Should reset


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 7.0.0.1
Build ID: 04ba7e3f1e51af6c5d653e543a620e36719083fd
CPU threads: 4; OS: Mac OS X 10.12.6; UI render: default; VCL: osx
Locale: nl-NL (nl_NL.UTF-8); UI: en-US
Calc: threaded
Comment 1 Telesto 2020-07-18 07:52:59 UTC
Created attachment 163229 [details]
Example file
Comment 2 Xisco Faulí 2020-08-03 16:19:54 UTC
Reproduced in

Version: 7.1.0.0.alpha0+
Build ID: 32090b018d9ff81659a4c9ed41c64109ebebe4fc
CPU threads: 4; OS: Linux 4.19; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

and

Version 4.1.0.0.alpha0+ (Build ID: efca6f15609322f62a35619619a6d5fe5c9bd5a)
Comment 3 Xisco Faulí 2020-08-03 16:20:31 UTC
@Caolán, I thought you might be interested in this issue
Comment 4 Caolán McNamara 2020-08-04 09:46:33 UTC
We seem to operate directly on the original table layout struct so changes to it in the dialog stick immediately and reset just resets to its current modified state. Presumably taking a copy and working on that and only overwriting the original on commit would do the right thing.
Comment 5 Commit Notification 2020-08-04 15:02:01 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/43ad29331c3f3cda4a0455545d83b7a9e2b2df4b

Related: tdf#134925 use std::vector

It will be available in 7.1.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 6 Commit Notification 2020-08-04 15:03:12 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/31c7f9c79d20afdd72de530b8bec22c10b472bf7

tdf#134925 operate on a copy of the original SwTableRep

It will be available in 7.1.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 Caolán McNamara 2020-08-04 20:00:51 UTC
no, that won't work as straightforward as that
Comment 8 Commit Notification 2020-08-05 12:45:50 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/3326a3a07d7567852486d7f1a2355f1499a33dda

tdf#134925 keep a copy of the original SwTableRep to Reset back to

It will be available in 7.1.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 9 Caolán McNamara 2020-08-05 12:46:34 UTC
instead take a copy of the original state and reset back to that on reset
Comment 10 Telesto 2020-08-22 19:51:25 UTC
*** Bug 132610 has been marked as a duplicate of this bug. ***