// Draw draws the label into the given grid. It returns the grid slice that was
// drawn.
Draw draws the label into the given grid. It returns the grid slice that was
drawn.
// Draw draws the label into the given grid . It returns the grid slice that was // drawn .
func (lb *Label) Draw(gd gruid.Grid) gruid.Grid {
	grid := lb.drawGrid(gd)
	cgrid := grid
	if lb.Box != nil {
		lb.Box.Draw(grid)
		rg := grid.Range()
		cgrid = grid.Slice(rg.Shift(1, 1, -1, -1))
	}
	cgrid.Fill(gruid.Cell{Rune: ' ', Style: lb.Content.Style()})
	lb.Content.Draw(cgrid)
	return grid
}
func ( lb * Label ) Draw ( gd gruid . Grid ) gruid . Grid { grid := lb . drawGrid ( gd ) cgrid := grid if lb . Box != nil { lb . Box . Draw ( grid ) rg := grid . Range ( ) cgrid = grid . Slice ( rg . Shift ( 1 , 1 , - 1 , - 1 ) ) } cgrid . Fill ( gruid . Cell { Rune : ' ' , Style : lb . Content . Style ( ) } ) lb . Content . Draw ( cgrid ) return grid }
Draw draws the label into the given grid.
Draw draws the label into the given grid .