MCPcopy Index your code
hub / github.com/g3n/engine / SetColAlignH

Method SetColAlignH

gui/gridlayout.go:92–102  ·  view source on GitHub ↗

SetColAlignH sets the horizontal alignment for all the cells of the specified column. The function panics if the supplied column is invalid.

(col int, align Align)

Source from the content-addressed store, hash-verified

90// SetColAlignH sets the horizontal alignment for all the cells of
91// the specified column. The function panics if the supplied column is invalid.
92func (g *GridLayout) SetColAlignH(col int, align Align) {
93
94 if col < 0 || col >= len(g.columns) {
95 panic("Invalid column")
96 }
97 if g.columns[col].alignh == nil {
98 g.columns[col].alignh = new(Align)
99 }
100 *g.columns[col].alignh = align
101 g.Recalc(g.pan)
102}
103
104// Recalc sets the position and sizes of all of the panel's children.
105// It is normally called by the parent panel when its size changes or

Callers

nothing calls this directly

Calls 1

RecalcMethod · 0.95

Tested by

no test coverage detected