flamendless / Slab

An immediate mode GUI for the Love2D framework.
MIT License
286 stars 25 forks source link

Option to Always Show Scrollbar #166

Closed MikuAuahDark closed 7 months ago

MikuAuahDark commented 10 months ago

Currently to make Slab show scrollbar, the AutoSizeWindow needs to be set to false. However in my use case, this is not possible since I need the window to be resizable. The screen size may also change. Furthermore, I can't determine exactly how much elements I'll put into.

flamendless commented 10 months ago

@MikuAuahDark you can now achieve this using the ShowScrollbarX or ShowScrollbarY

Example:

    Slab.BeginWindow("MyFirstWindow", {
        Title = "My First Window",
        ShowScrollbarX = true,
        ShowScrollbarY = true,
    })
        Slab.Text("Hello World")
    Slab.EndWindow()
MikuAuahDark commented 10 months ago

Cool, I'll test it out ASAP.