Issue 124886 - Tab position value modified after unit changed and back
Summary: Tab position value modified after unit changed and back
Status: UNCONFIRMED
Alias: None
Product: Writer
Classification: Application
Component: ui (show other issues)
Version: 4.0.1
Hardware: All All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-13 15:11 UTC by circulars
Modified: 2016-04-27 20:39 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description circulars 2014-05-13 15:11:55 UTC
There seems to be a rounding error causing the tab settings to be corrupted on changing units.

Replication 1

1. Open Preferences/writer/general.
2. Set units to centimetres
3. Set tabs to 1.00 cm.
4. Change units to inches.
5. Change units to centimetres. Value corrupts to 0.99.
6. Change units to millimetres. Value corrupts to 0.991.

Replication 2

1. Close and repeat 1-3 above using 0.89 as tab value.
2. Change units to millimetres. Value corrupts to 0.891. It should be 0.890.

Replication 3

1. Close and reopen.
3. Set units to points.
4. Set tabs to 25.0 points.
5. Change units to inches.
6. Change units back to points. Value corrupts to 25.2 points.
7. Et cetera.

Presumably this is because AOO is still working natively in inches and converting other values – but using insufficient significant figures when so doing.
Comment 1 Rainer Bielefeld 2014-05-13 15:27:52 UTC
That's nasty, but unfortunately more or less inevitable. Not a real bug, but effect of rounding errors.

This one is a DUP of an other one, I am pretty sure that we already discussed that in a different Issue report, but currently I can't find the other one.
Comment 2 Raminta 2016-04-16 16:41:11 UTC
I can still reproduce the above described issue. The results I am seeing is slightly different from the original report. Please find environment description and detailed replication steps below. Results were the same for both environments. 

Environment 1:
OS: Mac OS X, 
Open Office Writer: 4.1.2

Environment 2:
OS: Windows 10
Open Office Writer: 4.2.0

Replication 1
1. Open Preferences/Writer/General (OS X) or Options/Writer/General (Windows 10)
2. Set units to centimetres
3. Set tabs to 1.00 cm
4. Change units to inches
5. Change units to centimetres
Expected result: 1 cm
Actual result: 0.99 cm
6. Change units to millimetres
Expected result: 10.00 mm
Actual result: 9.91 mm

Replication 2
1. Close Preferences/Options window
2. Repeat steps 1-3 from Replication 1 using 0.89 as tab value
3. Change units to millimetres
Expected result: 8.90 mm
Actual result: 8.89 mm

Replication 3
1. Close Preferences/Options window
2. Open Preferences/Options window
3. Set units to points
4. Set tabs to 25.0 points
5. Change units to inches
6. Change units back to points
Expected result: 25.0 points
Actual result: 25.2 points

Replication 4 (please see attached screen recording - replication4.mov) 
1. Close Preferences/Options window
2. Open Preferences/Options window
3. Set units to millimetres
4. Set tabs to 60 mm
5. Hit Enter or press OK
6. Reopen Preferences/Options window 
7. Observe that tab value is changed to 60.01 mm
Comment 3 Raminta 2016-04-16 16:49:18 UTC
Attachment exceeded the maximum allowed size, so I am sharing a link to the file: https://www.dropbox.com/s/allhj1u8bbatceo/replication4.mov?dl=0
Comment 4 Theodore Matula 2016-04-27 20:39:10 UTC
(In reply to Rainer Bielefeld from comment #1)
> That's nasty, but unfortunately more or less inevitable. Not a real bug, but
> effect of rounding errors.
> 
> This one is a DUP of an other one, I am pretty sure that we already
> discussed that in a different Issue report, but currently I can't find the
> other one.

Do you remember how long ago that report was? What its status was?