Add (not perfect) mouse interaction to input widget
This commit is contained in:
parent
4ac0f37097
commit
b37c35dc0a
2 changed files with 36 additions and 25 deletions
|
@ -109,7 +109,7 @@ function theme.Input(input, opt, x,y,w,h)
|
|||
-- set scissors
|
||||
local sx, sy, sw, sh = love.graphics.getScissor()
|
||||
love.graphics.setScissor(x-1,y,w+2,h)
|
||||
x = x - input.drawoffset
|
||||
x = x - input.text_draw_offset
|
||||
|
||||
-- text
|
||||
love.graphics.setColor(opt.color and opt.color.normal or theme.color.normal.fg)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue