diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2016-05-16 17:14:37 +0300 |
---|---|---|
committer | Maxim Monastirsky <momonasmon@gmail.com> | 2016-05-19 00:01:38 +0300 |
commit | 4f1ce46b8d65360436e09750242101b566e6186c (patch) | |
tree | 76fd7cf106894e7073d824a211b07e12f1663fa4 /filter | |
parent | limit scanf string field width (diff) | |
download | core-4f1ce46b8d65360436e09750242101b566e6186c.tar.gz core-4f1ce46b8d65360436e09750242101b566e6186c.zip |
tdf#35208 Allow choosing encoding for old Excel files
Lots of BIFF2-BIFF5 files out there don't have CODEPAGE
record at all, or have one with a wrong value, and/or
FONT records with wrong charset value.
To solve that, this patch adds a new "Choose Encoding"
entry to the file picker, so that users could specify the
encoding to use for a given file, instead of relying on
the information that might be present (or not) inside the
file. It can be also used in headless mode,
e.g. --infilter="MS Excel (encoded)":61
This doesn't affect BIFF8 import, nor the default behavior
when not explicitly using the "Choose Encoding" entry.
Change-Id: I89d850d7679b81bd399044478fac7a02e8b7680e
Diffstat (limited to 'filter')
-rw-r--r-- | filter/Configuration_filter.mk | 1 | ||||
-rw-r--r-- | filter/source/config/fragments/filters/MS_Excel__encoded_.xcu | 30 |
2 files changed, 31 insertions, 0 deletions
diff --git a/filter/Configuration_filter.mk b/filter/Configuration_filter.mk index 5dd20f7f12f7..1fcd3a51100a 100644 --- a/filter/Configuration_filter.mk +++ b/filter/Configuration_filter.mk @@ -502,6 +502,7 @@ $(eval $(call filter_Configuration_add_filters,fcfg_langpack,fcfg_calc_filters.x MS_Excel_95_Vorlage_Template \ MS_Excel_97 \ MS_Excel_97_Vorlage_Template \ + MS_Excel__encoded_ \ Rich_Text_Format__StarCalc_ \ SYLK \ StarOffice_XML__Calc_ \ diff --git a/filter/source/config/fragments/filters/MS_Excel__encoded_.xcu b/filter/source/config/fragments/filters/MS_Excel__encoded_.xcu new file mode 100644 index 000000000000..767be941f1b9 --- /dev/null +++ b/filter/source/config/fragments/filters/MS_Excel__encoded_.xcu @@ -0,0 +1,30 @@ +<!-- + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . +--> +<node oor:name="MS Excel (encoded)" oor:op="replace"> + <prop oor:name="Flags"><value>IMPORT ALIEN</value></prop> + <prop oor:name="UIComponent"><value>com.sun.star.comp.Calc.FilterOptionsDialog</value></prop> + <prop oor:name="FilterService"/> + <prop oor:name="UserData"/> + <prop oor:name="UIName"> + <value xml:lang="en-US">Microsoft Excel - Choose Encoding</value> + </prop> + <prop oor:name="FileFormatVersion"><value>0</value></prop> + <prop oor:name="Type"><value>calc_MS_Excel_40</value></prop> + <prop oor:name="TemplateName"/> + <prop oor:name="DocumentService"><value>com.sun.star.sheet.SpreadsheetDocument</value></prop> +</node> |