Closed MellowArpeggiation closed 1 year ago
Awesome! Thanks for the improvements.
Just to be sure, there's no breaking changes to the API?
No breaking API changes, however I did leave a TODO for an API change from the Text option Pad to PadX/PadW for an eventual v1.
I also made a minor change to the behaviour of Textf when a W option is passed which may lead to unexpected behaviour, but I believe it’s much better aligned to what a developer would expect from the option
A small subset of the more general changes I made to Slab for FUNG - cleaned up and brought back to the main repo. Strap yourself in:
File loading
The file dialog as it is now will return a string containing the path to the selected file, but expects you to bring in a whole 'nother library just to load that file using love library functions. Since Slab already has 90% of the lovefs implementation, I've added the file copy to it, which will copy the file to the love save directory as a temporary file, returning a love friendly path which can be directly input into the love library functions:
Menus
Added a new Hint option for menu items, which can be used to tell the user available keyboard shortcuts
Added menu and menu item padding to style options
Windows
Added default window border to style options Added window title height to style options
Misc
Insert multiple newlines with NewLine Checkbox size now matches font size Listboxes now have a BG color, default transparent Button can be set to appear clicked (useful for toggles) Add init argument to prevent the cursor from being modified by Slab Add H option to Textf, aligns centered in the defined height Fix Textf not respecting explicit width Fix layouts completely ignoring borders (and causing overlaps with large borders!) Fix minimise/close button position and rendering when borders or title height is larger than default