Skip to content

Commit

Permalink
Merge pull request qax-os#156 from dolmen-go/fix/SheetViewOptPtr-is-a…
Browse files Browse the repository at this point in the history
…-SheetViewOpt

SheetViewOptionPtr: document that it is a superset of SheetViewOption
  • Loading branch information
xuri authored Nov 21, 2017
2 parents 130eb45 + d2fb019 commit 3d231cb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions sheetview.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ type SheetViewOption interface {

// SheetViewOptionPtr is a writable SheetViewOption. See GetSheetViewOptions().
type SheetViewOptionPtr interface {
SheetViewOption
getSheetViewOption(view *xlsxSheetView)
}

Expand Down
6 changes: 6 additions & 0 deletions sheetview_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ var _ = []excelize.SheetViewOption{
excelize.ShowFormulas(false),
excelize.ShowGridLines(true),
excelize.ShowRowColHeaders(true),
// SheetViewOptionPtr are also SheetViewOption
new(excelize.DefaultGridColor),
new(excelize.RightToLeft),
new(excelize.ShowFormulas),
new(excelize.ShowGridLines),
new(excelize.ShowRowColHeaders),
}

var _ = []excelize.SheetViewOptionPtr{
Expand Down

0 comments on commit 3d231cb

Please sign in to comment.