git-lfs/vendor/github.com/olekukonko/ts/ts.go
Taylor Blau 4593d0a641 vendor: vendor dependencies in vendor/ using Glide
- script/vendor received an update in order to work with Glide
- import paths have been rewritten to work with GO15VENDOREXPERIMENT
2016-05-23 12:10:35 -06:00

37 lines
681 B
Go

// Copyright 2014 Oleku Konko All rights reserved.
// Use of this source code is governed by a MIT
// license that can be found in the LICENSE file.
// This module is a Terminal API for the Go Programming Language.
// The protocols were written in pure Go and works on windows and unix systems
package ts
// Return System Size
type Size struct {
row uint16
col uint16
posX uint16
posY uint16
}
// Get Terminal Width
func (w Size) Col() int {
return int(w.col)
}
// Get Terminal Height
func (w Size) Row() int {
return int(w.row)
}
// Get Position X
func (w Size) PosX() int {
return int(w.posX)
}
// Get Position Y
func (w Size) PosY() int {
return int(w.posY)
}