DrawOffset
This commit is contained in:
7
text.go
7
text.go
@@ -72,6 +72,13 @@ func (w *Text) Draw(screen tcell.Screen) {
|
||||
y++
|
||||
}
|
||||
}
|
||||
|
||||
func (w *Text) DrawOffset(c Coord, screen tcell.Screen) {
|
||||
p := w.GetPos()
|
||||
w.SetPos(p.Add(c))
|
||||
w.Draw(screen)
|
||||
w.SetPos(p)
|
||||
}
|
||||
func (w *Text) Active() bool { return false }
|
||||
func (w *Text) SetActive(a bool) {}
|
||||
func (w *Text) Visible() bool { return w.visible }
|
||||
|
||||
Reference in New Issue
Block a user