That's a quite sad statement to make nowadays. I guess the old binary format might be worse regarding character sets, but at least the newer ones should use Unicode exclusively which makes this a very odd restriction.
Taking a piece of software and making all of the UI language localized is one thing. Making sure that your program doesn't blow up if it encounters UTF-8 is another thing. Nowadays if your program chokes on UTF-8, I think it's safe to just consider it broken.
In any case, looks like this is really where the issue may lie:
# for non-English characters
def getRealLengh(str):
length = len(str)
for s in str:
if ord(s) > 256:
length += 1
return length
and: for val in shn.row_values(n):
try: val = val.replace('\n',' ')
except: pass
val = isinstance(val, basestring) and val.strip() or str(val).strip()
line += val + ' ' * (30 - getRealLengh(val))
vim.current.buffer.append(line)
In accounting for the fix-width layout of non-ASCII characters.Like other people have pointed out, handling unicode properly does not mean internationalization. Handling utf-8 isn't even difficult if you just keep it in mind.
The notion of non-ASCII characters in user Excel documents IS NOT something rare even for English speaking nations. There are tons of people with foreign names, addresses and other personal information which is commonly stored in Excel documents. And the funny thing is: it's usually not alot of additional work to support UTF-8 if you START correctly.
> For vim 7.3 and less, it works well for almost all kinds of file formats,
> ie. .xls,.xlam,.xla,.xlsb,.xlsx,.xlsm,.xltx,.xltm,.xlt etc
Someone already pointed it out (https://github.com/yakiang/excel.vim/issues/5) on github: xlrd does not support the XLSB format (and the xlrd authors expressed no interest in building it)
The problem you will encounter is that most programs (Numbers, Google Docs) do not support XLSB.
Shameless plug: https://github.com/SheetJS/js-xlsx supports both XLSX and XLSB (AFAICT the only liberally licensed project that handles the format)
http://vim.wikia.com/wiki/Working_with_CSV_files
I'm not sure if it's what you're looking for, but I've found it very useful.
Edit: To clarify, I think this shows what hacking is all about. Playful cleverness and curiosity.