diff --git a/gui/gui.go b/gui/gui.go index 91a6a1e..189f736 100644 --- a/gui/gui.go +++ b/gui/gui.go @@ -260,8 +260,8 @@ func (gui *GUI) createWindow(width int, height int) (*glfw.Window, error) { } glfw.WindowHint(glfw.Resizable, glfw.True) - glfw.WindowHint(glfw.ContextVersionMajor, 3) // OR 2 - glfw.WindowHint(glfw.ContextVersionMinor, 2) + glfw.WindowHint(glfw.ContextVersionMajor, 4) + glfw.WindowHint(glfw.ContextVersionMinor, 1) glfw.WindowHint(glfw.OpenGLProfile, glfw.OpenGLCoreProfile) glfw.WindowHint(glfw.OpenGLForwardCompatible, glfw.True) diff --git a/gui/renderer.go b/gui/renderer.go index d09a814..70d2360 100644 --- a/gui/renderer.go +++ b/gui/renderer.go @@ -179,7 +179,7 @@ func (r *OpenGLRenderer) generateRectangle(col uint, line uint) *rectangle { // rounding to whole pixels makes everything nice x := float32(float32(col) * r.cellWidth) - y := float32((float32(line) * r.cellHeight)) + r.cellHeight + (r.font.LinePadding() / 2) + y := float32((float32(line) * r.cellHeight)) + r.cellHeight r.rectangles[[2]uint{col, line}] = r.newRectangle(x, y, r.colourAttr) return r.rectangles[[2]uint{col, line}] } @@ -226,7 +226,7 @@ func (r *OpenGLRenderer) DrawCellText(cell buffer.Cell, col uint, row uint) { r.font.SetColor(fg[0], fg[1], fg[2], alpha) x := float32(col) * r.cellWidth - y := (float32(row+1) * r.cellHeight) - (r.font.LinePadding() / 2) + y := (float32(row+1) * r.cellHeight) - (r.font.LinePadding()) if cell.Attr().Bold { // bold means draw text again one pixel to right, so it's fatter r.font.Print(x+1, y, string(cell.Rune()))