Fix up X,Y values in BufView

Let's return absolute X, Y values, rather than relative to the bufwindow.
This commit is contained in:
Dmitry Maluka 2021-04-09 01:48:58 +02:00
parent aaac60a78d
commit 88c95c8fae
2 changed files with 3 additions and 3 deletions

View File

@ -99,8 +99,8 @@ func (w *BufWindow) IsActive() bool {
// ruler, scrollbar and statusline.
func (w *BufWindow) BufView() View {
return View{
X: w.gutterOffset,
Y: 0,
X: w.X + w.gutterOffset,
Y: w.Y,
Width: w.bufWidth,
Height: w.bufHeight,
StartLine: w.StartLine,

View File

@ -75,7 +75,7 @@ func (i *InfoWindow) LocFromVisual(vloc buffer.Loc) buffer.Loc {
func (i *InfoWindow) BufView() View {
return View{
X: 0,
Y: 0,
Y: i.Y,
Width: i.Width,
Height: 1,
StartLine: SLoc{0, 0},