Download it now!
Bug 73487 - Fix cell border import from XLS / XLSX
Summary: Fix cell border import from XLS / XLSX
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.2.0.4 release
Hardware: Other All
: medium normal
Assignee: Kohei Yoshida
URL:
Whiteboard: target:4.3.0 target:4.2.1
Keywords: regression
: 34966 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-01-10 22:13 UTC by Kohei Yoshida
Modified: 2016-04-24 16:57 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Double line border (5.71 KB, image/png)
2014-01-19 15:07 UTC, Andras Timar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kohei Yoshida 2014-01-10 22:13:12 UTC
Summary.
Comment 1 Kohei Yoshida 2014-01-17 14:57:06 UTC
The problem becomes obvious especially with dashed borders and when they are printed on paper.  The thicknesses don't map correctly, patterned borders have wrong intervals etc.
Comment 2 Kohei Yoshida 2014-01-17 20:40:36 UTC
More details on this is in this blog post of mine: 

http://kohei.us/2014/01/17/the-art-of-drawing-border-lines/
Comment 3 Commit Notification 2014-01-18 05:53:07 UTC
Kohei Yoshida committed a patch related to this issue.
It has been pushed to "master":

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

fdo#73487: Write unit tests for this.



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.
Comment 4 Andras Timar 2014-01-19 15:07:47 UTC
Created attachment 92401 [details]
Double line border

Please look at a cells with double line border in Excel and in LibreOffice master on the attached screenshot. Line join at corners and line distance are different.
Comment 5 Kohei Yoshida 2014-01-20 17:05:13 UTC
How did you generate Calc's screenshot, at what zoom level?
Comment 6 Kohei Yoshida 2014-01-20 17:34:25 UTC
I changed it so that the aperture of the double lines stays the same at all zoom levels.  The line join difference is not something we can fix easily.  So, I'd like to leave that as a future TODO.
Comment 7 Commit Notification 2014-01-20 23:39:53 UTC
Kohei Yoshida committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=15974abe63f0d4fc88099634d5cd2ddb9760ec23

fdo#73487: Center thick border lines around cell grid.



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.
Comment 8 Kohei Yoshida 2014-01-21 00:12:24 UTC
One last change: align borderline in the middle with respect to the cell grid.  This reduces the amount of gap at line joins.  I think I'm done here.
Comment 9 Commit Notification 2014-01-29 22:34:05 UTC
Kohei Yoshida committed a patch related to this issue.
It has been pushed to "libreoffice-4-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=9a19e8d838753128504274e1885eb3ce8ec1dbb8&h=libreoffice-4-2

fdo#73487, fdo#73886: Overhaul cell borders to make them look sane.


It will be available in LibreOffice 4.2.1.

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.
Comment 10 Kohei Yoshida 2014-01-29 22:41:37 UTC
I'll mark it fixed.
Comment 11 Ashok 2014-02-16 10:54:14 UTC
Thanks Kohei Yoshida for your wonderful work.

However, the Hairline border (0.05pt thick) made with Calc 4.1.0 (to Calc 4.2.0) when opened with 4.2.1 RC1 shows as 0.75 thick,  but this is OK and not an issue at all

Another thing, in Excel the default border (thin line) translates to a single line border of 0.75 pt thick in Calc 4.2.1.  Whereas in Calc the default border is the hairline (0.05pt thick)  Can the default in Calc also be made to replicate that of Excel?
Comment 12 Kohei Yoshida 2014-02-17 15:31:44 UTC
(In reply to comment #11)

> Another thing, in Excel the default border (thin line) translates to a
> single line border of 0.75 pt thick in Calc 4.2.1.  Whereas in Calc the
> default border is the hairline (0.05pt thick)  Can the default in Calc also
> be made to replicate that of Excel?

Possible.  I'll probably come back to this and do some more work if time allows.  I'll keep this in the back of my head.
Comment 13 Kohei Yoshida 2014-02-24 03:13:35 UTC
*** Bug 34966 has been marked as a duplicate of this bug. ***
Comment 14 Jean-Baptiste Faure 2016-04-24 16:57:22 UTC
Version set from comment #2.

Best regards. JBF