aboutsummaryrefslogtreecommitdiffstats
path: root/style-default.lua
diff options
context:
space:
mode:
Diffstat (limited to 'style-default.lua')
-rw-r--r--style-default.lua18
1 files changed, 11 insertions, 7 deletions
diff --git a/style-default.lua b/style-default.lua
index a0e3fdf..95aecef 100644
--- a/style-default.lua
+++ b/style-default.lua
@@ -82,20 +82,24 @@ end
local function Slider(state, fraction, vertical, x,y,w,h)
local c = color[state]
- love.graphics.setLineWidth(2)
+ love.graphics.setLine(2, 'rough')
love.graphics.setColor(c.border)
- love.graphics.line(x,y+h/2-1,x+w,y+h/2-1)
- love.graphics.line(x,y+h/2+1,x+w,y+h/2+1)
- love.graphics.setColor(c.bg)
- love.graphics.line(x,y+h/2,x+w,y+h/2)
-
if vertical then
- y = math.floor(y + h * fraction - 5)
+ love.graphics.line(x+w/2-1,y,x+w/2-1,y+h)
+ love.graphics.line(x+w/2+1,y,x+w/2+1,y+h)
+ love.graphics.setColor(c.bg)
+ love.graphics.line(x+w/2,y,x+w/2,y+h)
+ y = math.floor(y + h - h * fraction - 5)
h = 10
else
+ love.graphics.line(x,y+h/2-1,x+w,y+h/2-1)
+ love.graphics.line(x,y+h/2+1,x+w,y+h/2+1)
+ love.graphics.setColor(c.bg)
+ love.graphics.line(x,y+h/2,x+w,y+h/2)
x = math.floor(x + w * fraction - 5)
w = 10
end
+
box(x,y,w,h, c.bg,c.border)
end