diff options
author | xuri <xuri.me@gmail.com> | 2020-11-04 00:28:20 +0800 |
---|---|---|
committer | xuri <xuri.me@gmail.com> | 2020-11-04 00:28:20 +0800 |
commit | c82a185af83b8b3934efcb0b227e494a18f426ea (patch) | |
tree | cb87009836fd0b879c4af1516ff9e6daf6faa043 /lib.go | |
parent | fcca8a38389c7a7f99639dc142b9b10c827ac7ce (diff) |
Compatibility improvement: parse document core part (workbook) dynamically
Diffstat (limited to 'lib.go')
-rw-r--r-- | lib.go | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -206,7 +206,6 @@ func CoordinatesToCellName(col, row int) (string, error) { if col < 1 || row < 1 { return "", fmt.Errorf("invalid cell coordinates [%d, %d]", col, row) } - //Using itoa will save more memory colname, err := ColumnNumberToName(col) return colname + strconv.Itoa(row), err } @@ -244,11 +243,12 @@ func parseFormatSet(formatSet string) []byte { // Transitional namespaces. func namespaceStrictToTransitional(content []byte) []byte { var namespaceTranslationDic = map[string]string{ - StrictSourceRelationship: SourceRelationship.Value, - StrictSourceRelationshipChart: SourceRelationshipChart, - StrictSourceRelationshipComments: SourceRelationshipComments, - StrictSourceRelationshipImage: SourceRelationshipImage, - StrictNameSpaceSpreadSheet: NameSpaceSpreadSheet.Value, + StrictSourceRelationship: SourceRelationship.Value, + StrictSourceRelationshipOfficeDocument: SourceRelationshipOfficeDocument, + StrictSourceRelationshipChart: SourceRelationshipChart, + StrictSourceRelationshipComments: SourceRelationshipComments, + StrictSourceRelationshipImage: SourceRelationshipImage, + StrictNameSpaceSpreadSheet: NameSpaceSpreadSheet.Value, } for s, n := range namespaceTranslationDic { content = bytesReplace(content, []byte(s), []byte(n), -1) |