Releases: jedib0t/go-pretty
v5.0.1
Features
- table
- support auto-merge of cells in a column with
ColumnConfig.AutoMerge
- support title/caption using the <caption> tag on the table in HTML mode
- support auto-merge of cells in a column with
Bug-Fixes
- table
- support auto-index in CSV/HTML/Markdown modes
General
- update dependency
go-runewidth
tov0.0.9
to enhance emoji support
v5.0.0
Features
- table
AppendSeparator
to append a separator after the last appended rowColumnConfig.Hidden
flag to control the visibility of individual columnsColumnConfig.WidthMaxEnforcer
to customize howWidthMax
is applied/enforcedResetFooters
to reset and remove all appended footersResetHeaders
to reset and remove all appended headersResetRows
to reset and remove all appended rows- Deprecated interfaces have been removed; refer to the table below for details
- General
- Transition from
dep
togo mod
for dependency management
- Transition from
Deprecations
table
Old Functionality | Replacement |
---|---|
SetAlign |
SetColumnConfig with ColumnConfig.Align |
SetAlignFooter |
SetColumnConfig with ColumnConfig.AlignFooter |
SetAlignHeader |
SetColumnConfig with ColumnConfig.AlignHeader |
SetAllowedColumnLengths |
SetColumnConfig with ColumnConfig.WidthMax |
SetColors |
SetColumnConfig with ColumnConfig.Colors |
SetColorsFooter |
SetColumnConfig with ColumnConfig.ColorsFooter |
SetColorsHeader |
SetColumnConfig with ColumnConfig.ColorsHeader |
SetVAlign |
SetColumnConfig with ColumnConfig.VAlign |
SetVAlignFooter |
SetColumnConfig with ColumnConfig.VAlignFooter |
SetVAlignHeader |
SetColumnConfig with ColumnConfig.VAlignHeader |
v4.3.0
v4.2.1
v4.2.0
This minor release contains a bunch of content:
ProgressWriter
@Haraguroicha found a plethora of go-routine-unsafe variable accesses in Progress Writer. This release contains the fixes for the same and prevents all identified unsafe accesses and sets up tests to check for race-conditions in the build process.
Thanks @Haraguroicha!
TableWriter
@Issif requested functionality to control the colorization of individual rows based on the content of the row and also for the capability to output the color coding in RenderHTML()
output. This release contains these features and some more:
- introduce a new interface SetColumnConfigs() to control every option for a column:
- Alignment (horizontal, vertical)
- Colors
- Transformation
- Width (minimum, maximum)
- mark older interfaces for deprecation:
- SetAlign(), SetAlignFooter(), SetAlignHeader()
- SetAllowedColumnLengths()
- SetColors(), SetColorsFooter(), SetColorsHeader()
- SetVAlign(), SetVAlignFooter(), SetVAlignHeader()
- support
RowPainter
to determine the colors to be used on an entire row overriding ColumnConfig settings - support text.Colors in HTML using similarly named CSS classes that can be customized by end-user
Thanks @Issif for the feedback!
v4.1.0
v4.0.3
This patch release does a better job at calculating character widths for Unicode characters as they appear on the console and render tables with such characters with a higher precision. It is not going to be 100% right all the time as the typeface plays a huge role in how the character gets rendered, but it will be better than before.
New Dependency: github.com/mattn/go-runewidth
v4.0.2
v4.0.1
v4.0.0
This major release refactors the text package to have much more user-friendly and usable functions. This renames quite a few existing functions and hence the major release.
- refactor text/ functions to make it a lot more useful and usable
- please look at GoDoc for the latest signatures
- table: restore some performance lost due to PR#66
- update README.md for the text changes and update benchmark results
- adds GoDoc examples to most functions