opendocument

How does Open Office compress its files?

孤人 提交于 2019-11-30 05:16:13
I'm trying to create an Open Office spreadsheet programmatically but for some reason simply compressing a folder with all the necessary files makes Open Office flag the file as corrupted. How did I get to this? I started by creating a normal spreadsheet in Open Office with some values in it. After saving I change the extension to .zip and make a copy of the folder. I then compress the second folder using command line zip and change the file extension to .ods. When trying to open the resulting file I get an error from Open Office saying the file is corrupt. Does Open Office use a special

Background image dark or light?

删除回忆录丶 提交于 2019-11-30 02:26:55
I'm doing a ODP->HTML conversion with PHP. I have problems with the following: Use the style:use-window-font-color property to specify whether or not the window foreground color should be as used as the foreground color for a light background color and white for a dark background color. (OpenDocument specification version 1.0, 15.4.4) If i have a background image, how do i check, if this image is light or dark? Do you have any ideas? Thanks in advance, Levu I thought this was quite an interesting problem to solve, so i hacked up a quick script to do it. following the other suggestions provided

How to convert OpenDocument spreadsheets to a pandas DataFrame?

僤鯓⒐⒋嵵緔 提交于 2019-11-29 21:21:56
The Python library pandas can read Excel spreadsheets and convert them to a pandas.DataFrame with pandas.read_excel(file) command. Under the hood, it uses xlrd library which does not support ods files. Is there an equivalent of pandas.read_excel for ods files? If not, how can I do the same for an Open Document Formatted spreadsheet (ods file)? ODF is used by LibreOffice and OpenOffice. davidovitch You can read ODF (Open Document Format .ods ) documents in Python using the following modules: odfpy / read-ods-with-odfpy ezodf pyexcel / pyexcel-ods py-odftools simpleodspy Using ezodf, a simple

How does Open Office compress its files?

情到浓时终转凉″ 提交于 2019-11-29 02:53:24
问题 I'm trying to create an Open Office spreadsheet programmatically but for some reason simply compressing a folder with all the necessary files makes Open Office flag the file as corrupted. How did I get to this? I started by creating a normal spreadsheet in Open Office with some values in it. After saving I change the extension to .zip and make a copy of the folder. I then compress the second folder using command line zip and change the file extension to .ods. When trying to open the resulting

Background image dark or light?

僤鯓⒐⒋嵵緔 提交于 2019-11-28 22:51:06
问题 I'm doing a ODP->HTML conversion with PHP. I have problems with the following: Use the style:use-window-font-color property to specify whether or not the window foreground color should be as used as the foreground color for a light background color and white for a dark background color. (OpenDocument specification version 1.0, 15.4.4) If i have a background image, how do i check, if this image is light or dark? Do you have any ideas? Thanks in advance, Levu 回答1: I thought this was quite an

How to convert OpenDocument spreadsheets to a pandas DataFrame?

核能气质少年 提交于 2019-11-28 17:25:26
问题 The Python library pandas can read Excel spreadsheets and convert them to a pandas.DataFrame with pandas.read_excel(file) command. Under the hood, it uses xlrd library which does not support ods files. Is there an equivalent of pandas.read_excel for ods files? If not, how can I do the same for an Open Document Formatted spreadsheet (ods file)? ODF is used by LibreOffice and OpenOffice. 回答1: You can read ODF (Open Document Format .ods ) documents in Python using the following modules: odfpy /