Handbook
Glossary
compute-column-widths ( table -- total widths )
Vocabulary
ui
.
gadgets
.
tables
.
private
Inputs
table
an
object
Outputs
total
an
object
widths
an
object
Definition
IN:
ui.gadgets.tables.private
GENERIC:
compute-column-widths
( table -- total widths )
Methods
USING:
accessors
arrays
assocs
kernel
math.vectors
sequences
ui.gadgets.tables.private
ui.tools.inspector
;
M:
inspector-table
compute-column-widths
dup
rows>>
[
drop
0
{
}
]
[
[
drop
gap>>
]
[
initial-widths
]
[
keys
longest
""
2array
row-column-widths
]
2tri
vmax
[
compute-total-width
]
keep
]
if-empty
;
USING:
accessors
kernel
math.vectors
sequences
ui.gadgets.tables
ui.gadgets.tables.private
;
M:
table
compute-column-widths
dup
rows>>
[
drop
0
{
}
]
[
[
drop
gap>>
]
[
initial-widths
]
[
]
2tri
[
row-column-widths
vmax
]
with
each
[
compute-total-width
]
keep
]
if-empty
;