[gnumeric] dbf: improve codepage support.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] dbf: improve codepage support.
- Date: Tue, 8 Mar 2011 18:19:12 +0000 (UTC)
commit aceee2b34c172996a6edbedc15b4edbd18ae221c
Author: Morten Welinder <terra gnome org>
Date: Tue Mar 8 13:18:52 2011 -0500
dbf: improve codepage support.
NEWS | 1 +
plugins/xbase/ChangeLog | 5 +++
plugins/xbase/xbase.c | 73 ++++++++++++++++++++++++++++++++++++----------
3 files changed, 63 insertions(+), 16 deletions(-)
---
diff --git a/NEWS b/NEWS
index 3012113..03d6b84 100644
--- a/NEWS
+++ b/NEWS
@@ -32,6 +32,7 @@ Morten:
* Fix xlsx import crash. [#643808]
* Import sheet visibility from xlsx. [#643815]
* Import names from xlsx. [#643874]
+ * Improve dbf codepage support. [#644189]
Stanley Pinchak:
* Improve "dif" output.
diff --git a/plugins/xbase/ChangeLog b/plugins/xbase/ChangeLog
index 5b56207..e8841b4 100644
--- a/plugins/xbase/ChangeLog
+++ b/plugins/xbase/ChangeLog
@@ -1,3 +1,8 @@
+2011-03-08 Morten Welinder <terra gnome org>
+
+ * xbase.c (xbase_read_header): Add more codepages from some
+ googling.
+
2011-03-08 Andreas J. Guelzow <aguelzow prshep ca>
* boot.c (xbase_file_open): do not overwrite the
diff --git a/plugins/xbase/xbase.c b/plugins/xbase/xbase.c
index f27a920..1d92202 100644
--- a/plugins/xbase/xbase.c
+++ b/plugins/xbase/xbase.c
@@ -115,31 +115,72 @@ xbase_read_header (XBfile *x, GOErrorInfo **ret_error)
char const *const name;
} const codepages [] = {
{ 0x01, 437, "U.S. MS-DOS" },
- { 0x69, 620, "Mazovia (Polish) MS-DOS" },
- { 0x6A, 737, "Greek MS-DOS (437G)" },
{ 0x02, 850, "International MS-DOS" },
+ { 0x03, 1252, "Windows ANSI" },
+ { 0x04, 10000, "Standard Macintosh" },
+ { 0x08, 865, "Danish OEM" },
+ { 0x09, 437, "Dutch OEM" },
+ { 0x0A, 850, "Dutch OEM*" },
+ { 0x0B, 437, "Finnish OEM" },
+ { 0x0D, 437, "French OEM" },
+ { 0x0E, 850, "French OEM*" },
+ { 0x0F, 437, "German OEM" },
+ { 0x10, 850, "German OEM*" },
+ { 0x11, 437, "Italian OEM" },
+ { 0x12, 850, "Italian OEM*" },
+ { 0x13, 932, "Japanese Shift-JIS" },
+ { 0x14, 850, "Spanish OEM*" },
+ { 0x15, 437, "Swedish OEM" },
+ { 0x16, 850, "Swedish OEM*" },
+ { 0x17, 865, "Norwegian OEM" },
+ { 0x18, 437, "Spanish OEM" },
+ { 0x19, 437, "English OEM (Britain)" },
+ { 0x1A, 850, "English OEM (Britain)*" },
+ { 0x1B, 437, "English OEM (U.S.)" },
+ { 0x1C, 863, "French OEM (Canada)" },
+ { 0x1D, 850, "French OEM*" },
+ { 0x1F, 852, "Czech OEM" },
+ { 0x22, 852, "Hungarian OEM" },
+ { 0x23, 852, "Polish OEM" },
+ { 0x24, 860, "Portugese OEM" },
+ { 0x25, 850, "Potugese OEM*" },
+ { 0x26, 866, "Russian OEM" },
+ { 0x37, 850, "English OEM (U.S.)*" },
+ { 0x40, 852, "Romanian OEM" },
+ { 0x4D, 936, "Chinese GBK (PRC)" },
+ { 0x4E, 949, "Korean (ANSI/OEM)" },
+ { 0x4F, 950, "Chinese Big 5 (Taiwan)" },
+ { 0x50, 874, "Thai (ANSI/OEM)" },
+ { 0x57, 1252, "Windows ANSI" }, /* guess */
+ { 0x58, 1252, "Western European ANSI" },
+ { 0x59, 1252, "Spanish ANSI" },
{ 0x64, 852, "Eastern European MS-DOS" },
- { 0x6B, 857, "Turkish MS-DOS" },
- { 0x67, 861, "Icelandic MS-DOS" },
- { 0x66, 865, "Nordic MS-DOS" },
{ 0x65, 866, "Russian MS-DOS" },
- { 0x7C, 874, "Thai Windows" },
+ { 0x66, 865, "Nordic MS-DOS" },
+ { 0x67, 861, "Icelandic MS-DOS" },
{ 0x68, 895, "Kamenicky (Czech) MS-DOS" },
- { 0x7B, 932, "Japanese Windows" },
- { 0x7A, 936, "Chinese (PRC, Singapore) Windows" },
- { 0x79, 949, "Korean Windows" },
+ { 0x69, 620, "Mazovia (Polish) MS-DOS" },
+ { 0x6A, 737, "Greek MS-DOS (437G)" },
+ { 0x6B, 857, "Turkish MS-DOS" },
+ { 0x6C, 863, "French-Canadian MS-DOS" },
{ 0x78, 950, "Chinese (Hong Kong SAR, Taiwan) Windows" },
- { 0xC8, 1250, "Eastern European Windows" },
- { 0xC9, 1251, "Russian Windows" },
- { 0x03, 1252, "Windows ANSI" },
- { 0xCB, 1253, "Greek Windows" },
- { 0xCA, 1254, "Turkish Windows" },
+ { 0x79, 949, "Korean Windows" },
+ { 0x7A, 936, "Chinese (PRC, Singapore) Windows" },
+ { 0x7B, 932, "Japanese Windows" },
+ { 0x7C, 874, "Thai Windows" },
{ 0x7D, 1255, "Hebrew Windows" },
{ 0x7E, 1256, "Arabic Windows" },
- { 0x04, 10000, "Standard Macintosh" },
- { 0x98, 10006, "Greek Macintosh" },
+ { 0x86, 737, "Greek OEM" },
+ { 0x87, 852, "Slovenian OEM" },
+ { 0x88, 857, "Turkish OEM" },
{ 0x96, 10007, "Russian Macintosh" },
{ 0x97, 10029, "Macintosh EE" },
+ { 0x98, 10006, "Greek Macintosh" },
+ { 0xC8, 1250, "Eastern European Windows" },
+ { 0xC9, 1251, "Russian Windows" },
+ { 0xCA, 1254, "Turkish Windows" },
+ { 0xCB, 1253, "Greek Windows" },
+ { 0xCC, 1257, "Baltic Windows" },
{ 0x00, 0, NULL }
};
int i;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]