Releases: Limekys/LimeUI
LimeUI 2025.08.17 [ALPHA] [EVENTS UPDATE]
This is a very big and important update that brings the system closer to a more stable state.
Firstly, all component constructor arguments have been removed. Instead, each element accepts a structure with element parameters. There are basic parameters in LuiBase + additional ones for each element. This greatly improves code readability, as there will no longer be any “empty” arguments at the beginning of each element. You only write the parameters you need. For example: new LuiButton({text: “Login”, width: 150, color: c_red}). In addition to this, all the corresponding methods have been added to the parameters so that they can be called in chain mode. For example: new LuiButton().setText(“Login”).setWidth(150).setColor(c_red).
Secondly, an event listener system has been added. Each element can have different logic added to it depending on the event that occurs, whether it be a mouse hover, click, or drag. A complete list of events can be found in the “LuiEvents” script. Events are already used by default in each component to designate their logic. But you can stack these events on top of each other and they will be executed one after another. Due to this change, the old logic with the “callback” method has been removed from all elements.
Thirdly, animation support has been added. Currently, it is being designed within components and can now be seen in the following components: LuiToggleSwitch, LuiProgressBar, LuiProgressRing, LuiSlider. It is called using the animate(target_element, property, end_value, duration, easing_func) method from LuiMain. The system also initializes all possible available easing functions in global.Ease.
Almost all elements and methods have been renamed for logical designation.
The description of errors and warnings when designing your UI has also been improved. You can enable or disable them by changing the macro mode LUI_LOG_ERROR_MODE.
Full changelog 2025.08.17:
- ADDED: Component animation (animate method in LuiMain)
- ADDED: Event model: addEvent(eventType, callback) All possible events can be viewed in the “LuiEvents” script
- ADDED: New LuiSurface element - Renders game maker surface
- ADDED: New LuiToggleSwitch element - switch similar to LuiCheckbox, moves horizontally on/off
- ADDED: New element LuiToggleButton - switch like LuiButton, but has the property of being on or off, glows with accent color when on
- ADDED: New LuiWindow element - a movable panel on the screen with a title and “minimize” and “close” buttons
- ADDED: getContent method to get the element's content array
- ADDED: view_region struct with coordinates of the visible area of the element for optimization
- ADDED: Added the ability to specify the displayed text for LuiCheckbox, which is a clickable area. Also added the setText method for LuiCheckbox
- ADDED: can_drag flag that determines whether to trigger DRAGGING, DRAG_START, DRAG_END events on an element with a mouse/finger or not
- ADDED: luiRescale methods for adjusting the UI size to the window/screen size, luiNextDebugMode(), luiToggleDebugGrid()
- ADDED: setData and getData methods for storing, retrieving, and modifying user data within elements
- ADDED: Methods to all possible elements to support chained parameter specification instead of element parameters
- ADDED: LuiSlider: Thickness setting
- ADDED: LuiButton, LuiTab, LuiComboBoxItem: Improved icon placement before text
- ADDED: Auxiliary method setPositionAbsolute(), equivalent to calling setPositionType(flexpanel_position_type.absolute)
- ADDED: LuiInput: Parameters for excluding characters, for allowed characters. Letter, number, and password input modes
- ADDED: Optional indentation from the container for LuiTabs tabs
- ADDED: LuiProgressBar, LuiProgressRing, LuiSlider - ability to set custom colors
- ADDED: setMouseIgnoreAll method to ignore the mouse for all nested elements
- CHANGED: All optional arguments have been removed from all components and replaced with a structure with parameters. Available parameters have been added to the description of each component.
- CHANGED: Renamed LuiSprite > LuiImage
- CHANGED: Renamed LuiSpriteButton > LuiImageButton
- CHANGED: Renamed LuiTextbox > LuiInput
- CHANGED: Renamed LuiTabGroup > LuiTabs
- CHANGED: Renamed LuiDropDown > LuiComboBox
- CHANGED: Renamed LuiDropDownItem > LuiComboBoxItem
- CHANGED: Renamed LuiAbsContainer > LuiAbsoluteContainer
- CHANGED: Renamed LuiBlockArea > LuiBox
- CHANGED: Renamed LuiFlexColumn > LuiColumn
- CHANGED: Renamed LuiFlexRow > LuiRow
- CHANGED: Renamed textbox_cursor > input_cursor
- CHANGED: Renamed textbox_password > input_password
- CHANGED: Renamed sprite_textbox > sprite_input
- CHANGED: Renamed sprite_textbox_border > sprite_input_border
- CHANGED: Renamed setSpriteDropdownArrow > setSpriteComboBoxArrow
- CHANGED: Renamed sprite_dropdown to sprite_combobox
- CHANGED: Renamed sprite_dropdown_border to sprite_combobox_border
- CHANGED: Renamed sprite_dropdown_item to sprite_combobox_item
- CHANGED: Renamed sprite_dropdown_item_border > sprite_combobox_item_border
- CHANGED: Renamed sprite_dropdown_arrow > sprite_combobox_arrow
- CHANGED: Renamed setSpriteTabGroup > setSpriteTabs
- CHANGED: Renamed sprite_tabgroup > sprite_tabs
- CHANGED: Renamed sprite_tabgroup_border > sprite_tabs_border
- CHANGED: Renamed setFlexPadding, setFlexGap, setFlexBorder > setPadding, setGap, setBorder
- CHANGED: Renamed showLuiMessage > luiShowMessage
- CHANGED: Renamed setBinding > bindVariable
- CHANGED: Renamed script “Additional” > “LuiAdditional”
- CHANGED: setPos..., setSize... now do not change the position/size if the user tries to specify the same position/size
- CHANGED: Changed color logic (Now uses primary, secondary, background, accent, and border colors for all elements)
- CHANGED: Element depth system (Now a more accurate and precise system for distributing element depth)
- CHANGED: Now the system indicates the incorrect number of ratios when adding elements, but continues to add, filling or trimming excess elements automatically
- FIXED: LuiDropDown: Does not close when clicking on another element or empty space
- FIXED: LuiDropDown: LuiDropDownPanel may throw an error when deleting the main UI after deletion
- FIXED: LuiDropDownPanel: Incorrect drop-down panel size is set for buttons
- FIXED: setFlexPadding, setFlexGap, setFlexBorder do not work properly
- FIXED: LuiTabGroup When moving a tab, the render does not keep up with the main panel
- FIXED: When checking isInteractingMouse, invisible LuiFlexRow and others are taken into account...
- FIXED: LuiScrollPanel scrolls if there is something on top of it
- FIXED: Memory leaks fixed
- FIXED: Performance improved
- REMOVED: All callbacks from components, the setCallback() method, and the macro LUI_DEBUG_CALLBACK (the callback has been replaced with the events listener system)
- REMOVED: The pos_x and pos_y variables (element initialization logic has been fixed)
Compatibility:
Game Maker runtime version 2024.13.1 or higher
Previous versions have not been tested.
LimeUI 2025.02.07 [ALPHA] [FLEX UPDATE]
The new release brings a built-in system Game Maker flexpanels, which allows you to fine-tune the location and size of all elements, and all this is calculated automatically and on the fly, which, for example, will allow you to change the size of the game window, and your interface will adjust to the new size.
A lot of work has been done to update all the elements for the new system, and also retained some past functionality, for example, you still, when adding elements, the last element can specify an array of ratios of the size of the elements and it will work correctly.
But some functions like setHalign and setValign had to be removed (they are still in the code, but will be removed in the next release). Instead of them it is now better to use setFlexJustifyContent and setFlexAlignContent, and the LuiFlexRow, LuiFlexColumn and LuiAbsContainer helper elements together, so you can customize your interface much more flexibly.
The way you create your initial design for the UI has also been changed. Now you don't need to write a huge structure with variable naming to specify sprites, colors, etc. It is enough to create new LuiStyle() and by chaining functions specify all sprites, colors and other settings: .setSprites(sUiPanel...).setColors(c_white, c_grey...).setPadding(16)...
Before you start, I suggest you study the Game Maker flexpanels documentation, and see how Yoga works, on which it is based.
The DEMO code has also been updated and is much more readable, you can see what it looks like now to get a better understanding of how to write your UI.
changelog 2025.02.07 "Flex update":
- ADDED: Functions in LuiStyle to set sprites, colors, sounds, fonts and other settings
- ADDED: New element LuiProgressRing: Circular progress bar
- ADDED: New methods for elements: setPositionType, setPosX, setPosY, setPosR, setPosB, setPosition, setWidth, setHeight, setSize, setMinWidth, setMaxWidth, setMinHeight, setMaxHeight, setMinMaxSize, setFlexPadding, setFlexGap, setFlexDirection, setFlexWrap, setFlexGrow, setFlexShrink, setFlexJustifyContent, setFlexAlignItems, setFlexAlignSelf, setFlexAlignContent, centerContent, setFlexDisplay, setContainer, getContainer
- ADDED: New helper elements for positioning other elements LuiFlexRow, LuiFlexColumn, LuiAbsContainer.
- ADDED: Game Maker system Flexpanels is now tightly integrated into LimeUI. The placement and size of all elements depends on it. Also, the old system of element placement did not allow to stretch the parent element correctly. In the new system everything happens automatically depending on the number and size of elements, and on the fly, not just at the moment of UI creation!
- ADDED: LUI_FORCE_ALPHA_1 macro that determines whether alpha should be set to 1 before rendering UI or not (default is true).
- CHANGED: Names of macro settings and global variables
- CHANGED: Name of method ignoreMouseHover --> setMouseIgnore
- CHANGED: Name of method create --> onCreate
- CHANGED: Variable name global.lui_debug_grid --> global.lui_debug_render_grid
- CHANGED: Updated the rendering mode for debugging information
- CHANGED: Now the mouse wheel changes the LuiSlider value to 2% or to the specified rounding if it is set to a value greater than 2% of the slider.
- CHANGED: LuiScrollPanel now draws content with gpu_set_scissors instead of draw_surface
- FIXED: Many bugs and incorrect behavior fixed due to the new Flexpanels element placement system
- FIXED: In LuiSlider, mouse wheel does not change value if rounding is greater than 2 units.
- FIXED: LuiSlider initial value could be greater or less than its specified range
- FIXED: Checkbox renderer (To be finalized in the future)
- FIXED: If you try to add content to Tab when Tab is not yet added to LuiTabGroup, an error occurs (Error found by wrekt from our Discord server).
- REMOVED: checkbox_pin_margin
- REMOVED: functions setHalign, setValign. Now alignment can be done in other ways: (setFlexJustifyContent, setFlexAlignContent).
Compatibility:
Game Maker runtime version
2024.11.0.226+
LimeUI 2025.01.16 [ALPHA]
One of the useful new functions is setBinding() with which you can very easily bind any variable to an element. For example, your player has the immortality variable "invincibile", you can easily bind it to a checkbox like this:
checkbox = new LuiCheckbox().setBinding(oPlayer, "invincible");
And that's it! After that, when interacting with the checkbox, the variable in the player will change and vice versa, if the variable changes, the element will react to that change and change its visual state.
And there's also some simple support for touch devices, you can see the full list of changes below:
- ADDED: Style parameters for LuiDropDown menu items: color_dropdown_item and color_dropdown_item_border
- ADDED: SetColor() and setAlpha() functions for LuiBlockArea
- ADDED: setBinding() function for binding variables to item value
- ADDED: Rounding parameter and setRounding() function for LuiSlider and LuiProgressBar
- ADDED: Popup text of slider value when interacting with it
- ADDED: setTooltip() Text tooltip for items when hovering mouse over them
- ADDED: #macro LUI_LOG_ERROR_MODE Mode of error output to console (0 - none, 1 - warnings, 2 - errors)
- ADDED: #macro LUI_DEBUG_CALLBACK Enables/disables callbakc debugging function by default for all items
- ADDED: SetIcon(Asset.GMSprite, scale) function (WIP) for LuiButton, LuiTab, LuiDropDown and LuiDropDownItem (Adds an icon sprite to the left of the text).
- ADDED: Support for touch devices (pop-up keyboard in textboxes, finger scrolling on scrollbars)
- ADDED: Auto change height of parent element when adding different elements to it, if its height is LUI_AUTO
- CHANGED: Updates and rendering related to LuiMain are now only in LuiMain
- CHANGED: The "cleanUp" method has been renamed to "onDestroy".
- FIXED: Problems with getElement() function
- FIXED: Problems with setVisible() function
- FIXED: Incorrect visibility change for LuiTabGroup if setVisible(false) is specified at creation.
- FIXED: Incorrect visibility change for LuiDropDown when it is open
- FIXED: Minor fixes and optimisations
- REMOVED: setIntegersOnly() and setRenderMode() for LuiSlider and LuiProgressBar (Use setRounding instead or specify rounding when creating an item).
LimeUI 2024.07.09 [ALPHA]
- Added LuiMain to separate logic, fix bugs and memory leaks. Now when creating a UI, LuiMain should be created initially instead of LuiBase.
- Added main surface of the entire ui, updated as needed
- Added setName() function to set a unique name for an element
- Added getElement(_name) function to get an element by its unique name
- Added name arguments for LuiButton, LuiCheckbox, LuiDropDown, LuiDropDownItem, LuiProgressBar, LuiSlider, LuiSprite, LuiSpriteButton, LuiTab, LuiText, LuiTextbox
- Added isInteracting() function for the main UI element (Returns true if the UI is mouse-over or keyboard input is used).
- Added isInteractingMouse() function
- Added isInteractingKeyboard() function
- Added onFocusSet() method
- Added onFocusRemove() method
- Added onMouseWheel() method
- Added onKeyboardInput() method
- Added onKeyboardRelease() method
- Added onMouseEnter() method
- Added onMouseLeave() method
- Added onValueUpdate() method
- Added onShow() method
- Added onHide() method
- Added scale_to_fit argument for LuiText
- Added default_min_width and default_min_height to styles
- Added sprite_dropdown_item, sprite_dropdown_item_border, sprite_dropdown_arrow and color_dropdown_arrow to styles
- Changed LuiDropDown view
- Changed the order of arguments in LuiTabGroup
- Changed the order of arguments for all elements so that the beginning of arguments is always x,y,width,height,name,...
- Changed DEMO project
- Renamed all functions to camelCase type
- Renamed variable global.LUI_DEBUG_MODE to global.lui_debug_mode
- Removed get_absolute_x and get_absolute_y functions, x y values of the element are now used instead
- Removed other unused code
- Fixes
- Optimization
LimeUI 2024.06.10 [ALPHA]
- Added optimization of interaction with the elements on the grid
- Added checkbox sprites to styles
- Added sprites and colors for ProgressBar and Slider to styles
- Added color for textbox to styles
- Added color for checkbox and checkbox border to styles
- Added checkbox_pin_margin to styles
- Added scroll_surface_offset to styles (array with boundaries to cut off surface)
- Added create() method (Called after adding somewhere)
- Added method pre_draw() (Called before the main drawing)
- Added on_content_update() method (Called every time elements are added)
- Added method clean_up() (Called after the destroy function call)
- Added on_mouse_left() method
- Added on_mouse_left_pressed() method
- Added on_mouse_left_released() method
- Added on_position_update() method
- Added render_content_enabled variable
- Changed LuiScrollPanel renderer to make the code more correct
- Changed logic of adding elements and assigning styles to them
- Changed display of debugging information
- Fixed checkbox drawing
- Fixed tab size calculation
- Fixed drawing of sprites
- Fixed auto addition of elements in a row
- Fixed adding tabs to TabGroup
- Removed color_slider variable in styles (replaced with color_progress_bar_value)
- Optimized code
LimeUI 2024.06.04 [ALPHA]
LimeUI 2024.06.03 [ALPHA]
Fix with visible logic
LimeUI 2024.05.25 [ALPHA]
Update README.md
