fix some europe character error

This commit is contained in:
Liu Ming
2016-06-20 09:39:08 +08:00
parent 6f63f448b8
commit 0b5fd56f62
2 changed files with 60 additions and 46 deletions

View File

@@ -177,8 +177,13 @@ func (w *WorkBook) get_string(buf io.ReadSeeker, size uint16) string {
}
} else {
var bts = make([]byte, size)
var bts1 = make([]uint16, size)
binary.Read(buf, binary.LittleEndian, &bts)
res = string(bts)
for k, v := range bts {
bts1[k] = uint16(v)
}
runes := utf16.Decode(bts1)
res = string(runes)
}
if flag&0x8 != 0 {
var bts []byte