Excelize 2.9.1 Released - Open-source library for Excel (XLAM / XLSM / XLSX / XLTM / XLTX) spreadsheets

xurixuri
5 min read

Excelize is a library written in pure Go providing a set of functions that allow you to write to and read from XLAM / XLSM / XLSX / XLTM / XLTX files. Supports reading and writing spreadsheet documents generated by Microsoft Excel™ 2007 and later. Supports complex components by high compatibility, and provided streaming API for generating or reading data from a worksheet with huge amounts of data.

GitHub: github.com/xuri/excelize

We are pleased to announce the release of version 2.9.1. Featured are a handful of new areas of functionality and numerous bug fixes.

A summary of changes is available in the Release Notes.

Release Notes

The most notable changes in this release are:

Breaking Change

  • Upgrade requirements Go language version is 1.23 or later, for upgrade of dependency package golang.org/x/crypto

  • Change the data type of DataValidationType, DataValidationErrorStyle, DataValidationOperator, PictureInsertType from int to byte

  • SetCellInt function required int64 data type parameter, resolve issue 2068

  • When adding drawing objects such as pictures, charts, shapes, and form controls, the offset setting will no longer affect the size of the drawing object, related issue 2001

Notable Features

  • Add new fields GapWidth and Overlap in the Chart data type

  • Add new fields ShowDataTable and ShowDataTableKeys fields in the ChartPlotAreadata type

  • Add new field Alignment in the ChartAxis data type

  • Add new field DataLabel in the ChartSeries data type

  • Add new field PageOrder for PageLayoutOptions data type

  • Add 2 new exported error variables: ErrPageSetupAdjustTo and ErrStreamSetColStyle

  • Add 2 new exported enumerations: HeaderFooterImagePositionType and IgnoredErrorsType

  • Add 2 new exported data types: CalcPropsOptions and HeaderFooterImageOptions

  • Add 2 new functions: SetCalcProps and GetCalcProps support setting and getting workbook calculation properties

  • Add new CultureNameJaJP, CultureNameKoKR and CultureNameZhTW enumeration values, support apply number format for the Japanese calendar years, the Korean Danki calendar and the Republic of China year, related issue 1885

  • Add new function AddHeaderFooterImage to support set graphics in a header and footer, related issue 1395

  • Add new function AddIgnoredErrors support to ignored error for a range of cells, related issue 2046

  • Add new function SetColStyle for streaming writer to support set columns style, related issue 2075

  • The AddChart and AddChartSheet function support set chart axis text direction and rotation, related issue 2025

  • The AddChart and AddChartSheet function support set gap width and overlap for column and bar chart, related issue 2033

  • The AddChart and AddChartSheet function support set the format of the chart series data label, related issue 2052

  • The AddChart and AddChartSheet function support set data table for chart, related issue 2117

  • The AddFormControl function support set cell link for check box, related issue 2113

  • The SetPageLayout function support set page order of page layout

  • The DeletePicture function support delete one cell anchor image, related issue 2059

  • An error will be return if the option value of the SetPageLayout function is invalid

  • Support adjust data validations cross multiple worksheets, related issue 2072

  • Support apply number format with hash and zero place holder, related issue 2058

  • Support apply number format with ? symbol

  • Support to insert one cell anchor drawing object when specified the positioning as “oneCell”, related issue 2002

Bug Fixes

  • Fix a v2.9.0 regression bug, corrupted workbook generated by open the workbook generated by stream writer, resolve issue 2015

  • Fix redundant none type pattern fill generated, resolve issue 2014

  • Fix missing vertical and horizontal border styles in some case, resolve issue 2048

  • Fix conditional format’s border styles missing in some case, resolve issue 2061

  • Fix get pivot tables panic in some case, resolve issues 1954 and 2051

  • Fix GetStyle function can not get VertAlign format

  • Fix CalcCellValue function subexpressions aren’t correctly calculated in some case, resolve issue 2083

  • Fix delete wrong images in some case which caused by image reference detection issue

  • Fix cell default style doesn’t override by none-zero row style when set row by stream writer

  • Fix redundant cols element generated by stream writer

  • Fix panic on set chart title font, resolve issue 2102

  • Fix panic on delete calc chain in some case

  • Fix incorrect formula calculation result caused by shared formula parse error, resolve issue 2056

  • Fix corrupted workbook generated when an inner ZIP64 file size exceeds 4GB

  • Fix sheet name error in defined name after rename sheet, resolve issue 2126

Performance

  • Use a 3 times faster deepcopy library github.com/tiendc/go-deepcopy instead of github.com/mohae/deepcopy, related issue 2029

  • Fix performance regression in v2.9.0, reduce trim cell value memory allocation for blank cells

  • Improve performance for calculate formula when formula contains whole column and row reference

  • Rows iterator speedup about 20%, memory allocation reduce about 10%

Miscellaneous

  • The dependencies module has been updated

  • Unit tests and godoc updated

  • Documentation website with multilingual: Arabic, German, English, Spanish, French, Italian, Japanese, Korean, Portuguese, Russian, Chinese Simplified and Chinese Traditional, which has been updated.

  • excelize-wasm NPM package release update for WebAssembly / JavaScript support

  • excelize PyPI package release update for Python

Thank you

Thanks for all the contributors to Excelize. Below is a list of contributors that have code contributions in this version:

  • wushiling50

  • imirkin (Ilia Mirkin)

  • Juneezee (Eng Zer Jun)

  • Arpelicy

  • zhuhaicity (ZhuHaiCheng)

  • xxf0512 (xxf)

  • gypsy1234

  • mengpromax (MengZhongYuan)

  • hly-717

  • kurtinge (Kurt Inge Smådal)

  • IvanHristov98 (Ivan Hristov)

  • artur-chopikian (Artur Chopikian)

  • romanshevelev (Roman Shevelev)

  • LZCZ

  • hm3248

  • moisespsena (Moises P. Sena)

  • paolobarbolini (Paolo Barbolini)

  • timesince

  • shcabin

  • tgulacsi (Tamás Gulácsi)

  • R3dByt3 (R3dByt3)

  • Now-Shimmer

1
Subscribe to my newsletter

Read articles from xuri directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

xuri
xuri