v0.0.497
Some checks failed
Build Docker and Deploy / Run goext test-suite (push) Failing after 2m33s
Some checks failed
Build Docker and Deploy / Run goext test-suite (push) Failing after 2m33s
This commit is contained in:
parent
741611a2e1
commit
7204562879
@ -1,5 +1,5 @@
|
|||||||
package goext
|
package goext
|
||||||
|
|
||||||
const GoextVersion = "0.0.496"
|
const GoextVersion = "0.0.497"
|
||||||
|
|
||||||
const GoextVersionTimestamp = "2024-08-07T15:34:06+0200"
|
const GoextVersionTimestamp = "2024-08-07T17:04:59+0200"
|
||||||
|
@ -289,23 +289,28 @@ func (b *TableBuilder) calculateColumns() []float64 {
|
|||||||
return columnWidths
|
return columnWidths
|
||||||
}
|
}
|
||||||
|
|
||||||
for i, _ := range columnDef {
|
{
|
||||||
|
rmSub := 0.0
|
||||||
|
for i := range columnDef {
|
||||||
if frColumnWeights[i] != 0 {
|
if frColumnWeights[i] != 0 {
|
||||||
w := min(autoWidths[i], (remainingWidth/float64(frColumnWidthCount))*frColumnWeights[i])
|
w := min(autoWidths[i], (remainingWidth/float64(frColumnWidthCount))*frColumnWeights[i])
|
||||||
remainingWidth += columnWidths[i]
|
rmSub += w - columnWidths[i]
|
||||||
columnWidths[i] = w
|
columnWidths[i] = w
|
||||||
remainingWidth -= w
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
remainingWidth -= rmSub
|
||||||
|
}
|
||||||
|
|
||||||
if remainingWidth > 0 {
|
if remainingWidth > 0.01 {
|
||||||
|
rmSub := 0.0
|
||||||
for i, _ := range columnDef {
|
for i, _ := range columnDef {
|
||||||
if frColumnWeights[i] != 0 {
|
if frColumnWeights[i] != 0 {
|
||||||
addW := (remainingWidth / float64(frColumnWidthCount)) * frColumnWeights[i]
|
addW := (remainingWidth / float64(frColumnWidthCount)) * frColumnWeights[i]
|
||||||
|
rmSub += addW
|
||||||
columnWidths[i] += addW
|
columnWidths[i] += addW
|
||||||
remainingWidth -= addW
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
remainingWidth -= rmSub
|
||||||
}
|
}
|
||||||
|
|
||||||
return columnWidths
|
return columnWidths
|
||||||
|
Loading…
Reference in New Issue
Block a user