Issue 123876 - Conversion ODS => XLS make wrong column width when is made in -headless mode
Summary: Conversion ODS => XLS make wrong column width when is made in -headless mode
Status: CLOSED IRREPRODUCIBLE
Alias: None
Product: Calc
Classification: Application
Component: save-export (show other issues)
Version: 4.0.1
Hardware: All Linux, all
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: needmoreinfo
Depends on:
Blocks:
 
Reported: 2013-12-18 11:19 UTC by Dmitriy Samborskiy
Modified: 2017-05-20 09:57 UTC (History)
2 users (show)

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


Attachments
this is a test script and all the files needed to reproduce the issue (18.28 KB, application/zip)
2013-12-18 11:19 UTC, Dmitriy Samborskiy
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Dmitriy Samborskiy 2013-12-18 11:19:49 UTC
Created attachment 82132 [details]
this is a test script and all the files needed to reproduce the issue

I observe an erroneous ODS => XLS (MS Excel 97) format conversion:
column sizes are increased for some ODS files.

It only happens when:

1. ODS file contains styles with 'Times New Roman Cyr' or 'Arial Cyr' fonts (Linux *does* have Microsoft 'Times New Roman' & 'Arial' TTF fonts, but not the legacy cyrillic fonts with 'Cyr' suffix)

2. Conversion is made in a headless mode (i.e. executed with a command like 'DISPLAY="" soffice -headles ...')

See the attached ZIP file for the sample file.ods test file, test scipt, Module1.xba and the resulted file.xls which has wrong size of its first column
(4.04", not 3.53").

My test environment is following:

$ uname -a
Linux ... 2.6.32-358.18.1.el6.x86_64 #1 SMP Wed Aug 28 17:19:38 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

OpenOffice version: Apache OpenOffice 4.0.1, AOO401m5(Build:9714)  -  Rev. 1524958 2013-09-20 11:54 - Linux x86_64

There were a couple related issues (#50210, #59234) reported earlier, but now I think I have 100% reproducable behaviour which is tested in OO v.3.1.1, v.3.3, and v.4.01.
Comment 1 Edwin Sharp 2013-12-18 12:15:20 UTC
./test.sh gives:
No protocol specified
No protocol specified
/opt/openoffice4/program/soffice.bin X11 error: Can't open display: 
   Set DISPLAY environment variable, use -display option
   or check permissions of your X-Server
   (See "man X" resp. "man xhost" for details)

What is Module1.xba?
Comment 2 Dmitriy Samborskiy 2013-12-18 14:00:35 UTC
> What is Module1.xba?

Module1.xba is a file with user's standard macro library which is located in 

~/.openoffice/3/user/basic/Standard

folder.

The conversion commands call macro function SaveAsMSO which is defined in this file (AFAIK there is no other way to call a macro function from a command line than to use user's macro library defined in this file).

> ./test.sh gives:
> No protocol specified
> No protocol specified
> /opt/openoffice4/program/soffice.bin X11 error: Can't open display: 
>   Set DISPLAY environment variable, use -display option
>   or check permissions of your X-Server
>   (See "man X" resp. "man xhost" for details)

Perhaps you are running it without X display.
It's necessary for the first command

soffice macro:///Standard.Module1.SaveAsMSO\($FILE\)

to have access to graphic display. It shows OO logo window for a second
and then the resulted file.xls is made (the correct one).

Only the second command gives the wrong file.xls (with wrong column1 size):

DISPLAY="" soffice -headless macro:///Standard.Module1.SaveAsMSO\($FILE\)
Comment 3 Edwin Sharp 2013-12-18 14:37:02 UTC
Thank you. 
The first command in test.sh was commented.
./test.sh now has no effect.
Apologies for not being a Linux expert.
Comment 4 Edwin Sharp 2014-01-02 09:50:57 UTC
No info from author.