11 lines
712 B
Plaintext
11 lines
712 B
Plaintext
|
draw_scrollbar = function(Editor_state)
|
||
|
App.color(Normal_color)
|
||
|
love.graphics.line(Editor_state.right+30, Editor_state.top, Editor_state.right+30, Editor_state.bottom)
|
||
|
love.graphics.line(Editor_state.right+25, Editor_state.top, Editor_state.right+35, Editor_state.top)
|
||
|
love.graphics.line(Editor_state.right+25, Editor_state.bottom, Editor_state.right+35, Editor_state.bottom)
|
||
|
local sbtop, sbbot = compute_scrollbar(Editor_state)
|
||
|
local topy = Editor_state.top + sbtop*(Editor_state.bottom - Editor_state.top)
|
||
|
local boty = Editor_state.top +sbbot*(Editor_state.bottom - Editor_state.top)
|
||
|
App.color{r=0.6, g=0.6, b=0.8, a=0.5}
|
||
|
love.graphics.rectangle('fill', Editor_state.right+20, topy, 20, boty-topy)
|
||
|
end
|