2 Commits

Author SHA1 Message Date
68591a3821 migrated to git.milar.in 2022-08-16 12:09:21 +02:00
d036639ee6 Offset introduced 2022-05-04 18:06:24 +02:00
2 changed files with 7 additions and 1 deletions

View File

@ -69,6 +69,12 @@ func (b *Buffer[T]) Height() int {
return b.height
}
// Offset returns the offset of b relative to its parent buffer.
// Offset returns zeros if b has no parent
func (b *Buffer[T]) Offset() (x, y int) {
return b.x, b.y
}
// OffsetX returns the horizontal offset of b relative to its parent buffer.
// OffsetX returns 0 if b has no parent
func (b *Buffer[T]) OffsetX() int {

2
go.mod
View File

@ -1,3 +1,3 @@
module git.tordarus.net/Tordarus/buf2d
module git.milar.in/milarin/buf2d
go 1.18