Sfoglia il codice sorgente

update README and functions docs (#351)

* update README and functions docs

* update README and functions docs
Kimxu 6 anni fa
parent
commit
164a3e126a
3 ha cambiato i file con 13 aggiunte e 9 eliminazioni
  1. 2 2
      README.md
  2. 4 0
      README_zh.md
  3. 7 7
      rows.go

+ 2 - 2
README.md

@@ -17,8 +17,8 @@ Excelize is a library written in pure Go and providing a set of functions that a
 
 **WARNING!**
 
-From version 1.5 all row manipulation methods uses Excel row numbering starting with `1` instead of zero-based numbering
-which take place in some methods in eraler versions.   
+From version 1.5.0 all row manipulation methods uses Excel row numbering starting with `1` instead of zero-based numbering
+which take place in some methods in eraler versions.
 
 ## Basic Usage
 

+ 4 - 0
README_zh.md

@@ -15,6 +15,10 @@
 
 Excelize 是 Go 语言编写的用于操作 Office Excel 文档类库,基于 ECMA-376 Office OpenXML 标准。可以使用它来读取、写入由 Microsoft Excel™ 2007 及以上版本创建的 XLSX 文档。相比较其他的开源类库,Excelize 支持写入原本带有图片(表)、透视表和切片器等复杂样式的文档,还支持向 Excel 文档中插入图片与图表,并且在保存后不会丢失文档原有样式,可以应用于各类报表系统中。使用本类库要求使用的 Go 语言为 1.8 或更高版本,完整的 API 使用文档请访问 [godoc.org](https://godoc.org/github.com/360EntSecGroup-Skylar/excelize) 或查看 [参考文档](https://xuri.me/excelize/)。
 
+**重要提示**
+
+从版本 1.5.0 开始,所有行操作方法都使用从 `1` 开始的 Excel 行编号,早期版本中某些方法中的基于 `0` 的行编号将不再使用。
+
 ## 快速上手
 
 ### 安装

+ 7 - 7
rows.go

@@ -285,7 +285,7 @@ func (xlsx *xlsxC) getValueFrom(f *File, d *xlsxSST) (string, error) {
 	}
 }
 
-// SetRowVisible2 provides a function to set visible of a single row by given
+// SetRowVisible provides a function to set visible of a single row by given
 // worksheet name and Excel row number. For example, hide row 2 in Sheet1:
 //
 //    xlsx.SetRowVisible("Sheet1", 2, false)
@@ -305,10 +305,9 @@ func (f *File) SetRowVisible(sheet string, row int, visible bool) {
 	xlsx.SheetData.Row[rowIdx].Hidden = true
 }
 
-// GetRowVisible2 provides a function to get visible of a single row by given
-// worksheet name and Excel row number.
-// For example, get visible state of row 2 in
-// Sheet1:
+// GetRowVisible provides a function to get visible of a single row by given
+// worksheet name and Excel row number. For example, get visible state of row
+// 2 in Sheet1:
 //
 //    xlsx.GetRowVisible("Sheet1", 2)
 //
@@ -376,8 +375,9 @@ func (f *File) RemoveRow(sheet string, row int) {
 	}
 }
 
-// InsertRow2 provides a function to insert a new row after given Excel row number
-// starting from 1. For example, create a new row before row 3 in Sheet1:
+// InsertRow provides a function to insert a new row after given Excel row
+// number starting from 1. For example, create a new row before row 3 in
+// Sheet1:
 //
 //    xlsx.InsertRow("Sheet1", 3)
 //