summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorRi Xu <xuri.me@gmail.com>2017-01-17 19:06:42 +0800
committerRi Xu <xuri.me@gmail.com>2017-01-17 19:06:42 +0800
commita99f0227b085d8f417f77864941650ef0e6273e4 (patch)
treed1b8fd8c323614c9defeaa6c9d10f6f432019e50 /README.md
parent53d8c4bb3aca921d7dd0a4ac3233887208513bfb (diff)
- New function `AddPicture()` added, support to add picture into excel cell;
- go test updated; - fix typo and `gofmt -s` formatted
Diffstat (limited to 'README.md')
-rw-r--r--README.md22
1 files changed, 22 insertions, 0 deletions
diff --git a/README.md b/README.md
index 3d0d24c..1c77058 100644
--- a/README.md
+++ b/README.md
@@ -106,6 +106,28 @@ func main() {
}
```
+### Add pictures to XLSX files
+
+```go
+package main
+
+import (
+ "fmt"
+ "os"
+
+ "github.com/Luxurioust/excelize"
+)
+
+func main() {
+ xlsx := excelize.CreateFile()
+ err := xlsx.AddPicture("Sheet1", "A2", "H9", "/tmp/image.jpg")
+ if err != nil {
+ fmt.Println(err)
+ os.Exit(1)
+ }
+}
+```
+
## Contributing
Contributions are welcome! Open a pull request to fix a bug, or open an issue to discuss a new feature or change.