Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ScrollBar not appearing #49

Closed
flamendless opened this issue Aug 21, 2020 · 1 comment
Closed

ScrollBar not appearing #49

flamendless opened this issue Aug 21, 2020 · 1 comment

Comments

@flamendless
Copy link
Owner

Consider this snippet:

local Slab = require 'Slab'
local SlabTest = require 'SlabTest'

local list = {}
for i = 1, 50 do
	local t = { id = tostring(i) }
	table.insert(list, t)
end

function love.load(args)
	love.graphics.setBackgroundColor(0.4, 0.88, 1.0)
	Slab.Initialize(args)
end

function love.update(dt)
	Slab.Update(dt)
	SlabTest.Begin()

	Slab.BeginWindow("test", {Title = "test"})
	for i, v in ipairs(list) do
		Slab.Text(v.id)
		Slab.SameLine()
		if Slab.Button("x") then
			print(i)
		end
	end
	Slab.EndWindow()
end

function love.draw()
	Slab.Draw()
end

This makes a window that is very long but no vertical scrollbar appears.

@coding-jackalope
Copy link
Collaborator

Thanks for reporting this. Adding this for the upcoming patch release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants