From a1887aa86694208549bee0ef46758d602ba79696 Mon Sep 17 00:00:00 2001 From: jussi Date: Fri, 24 Nov 2023 20:09:34 +0200 Subject: SDL Events. --- examples/gui/main.lua | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'examples/gui/main.lua') diff --git a/examples/gui/main.lua b/examples/gui/main.lua index 4779535..676b562 100644 --- a/examples/gui/main.lua +++ b/examples/gui/main.lua @@ -32,6 +32,8 @@ function RL.init() RL.SetWindowState( RL.FLAG_VSYNC_HINT ) RL.SetWindowSize( winSize ) RL.SetWindowPosition( { mPos[1] + mSize[1] / 2 - winSize[1] / 2, mPos[2] + mSize[2] / 2 - winSize[2] / 2 } ) + + RL.GuiSetStyle( RL.LISTVIEW, RL.TEXT_ALIGNMENT, RL.TEXT_ALIGN_LEFT ) end function RL.draw() @@ -74,8 +76,8 @@ function RL.draw() if result == 1 then dropdownActive = not dropdownActive end - - _, listView.scroll, listView.item = RL.GuiListView( { 200, 400, 200, 200 }, "Cat;Elefant;Squirrel", listView.scroll, listView.item ) + + _, listView.scroll, listView.item = RL.GuiListView( { 200, 400, 200, 200 }, "Cat\nElefant\nSquirrel", listView.scroll, listView.item ) result = RL.GuiMessageBox( { 420, 400, 200, 100 }, "Message", "Are you sure about this?", "Yes;No" ) if 0 <= result then -- cgit v1.2.3