Added svg support to CreateTextureFromFile
Added optional agrument 'size' to CreateTextureFromFile
Lua:local texture = ImGui.CreateTextureFromFile( 'path' ) local second_texture = ImGui.CreateTextureFromFile( 'path', ImGui.ImVec2( 100, 100 ) )
Added GetTextureInfo
Lua:local texture = ImGui.CreateTextureFromFile( 'path' ) local texture_info = ImGui.GetTextureInfo( texture ) print( tostring( texture_info.Width ) ) print( tostring( texture_info.Height ) )
Removed addons_module
Updated VT
Fixed Combo/ListBox
![]()
Lua:local ImGui = require( 'cimgui' ) local item = ImGui.new.int( 0 ) local item_list = {'Item 1', 'Item 2', 'Item 3', 'Item 4', 'Item 5'} local items = ImGui.new['const char*'][#item_list]( item_list ) ImGui.Paint( function( ) ImGui.Begin( 'Window' ) ImGui.Combo( 'Combo', item, items, #item_list ) ImGui.ListBox( 'ListBox', item, items, #item_list ) ImGui.End( ) end )
Added FreeType
Added imgui.GetBuilderForFreeType( )
Added imgui.FreeTypeBuilderFlags
![]()
Lua:local ImGui = require( 'cimgui' ) local font_config = ImGui.ImFontConfig( ) font_config.OversampleH = 3 font_config.OversampleV = 3 font_config.PixelSnapH = false font_config.FontBuilderFlags = bit.bor( ImGui.FreeTypeBuilderFlags.Monochrome, ImGui.FreeTypeBuilderFlags.MonoHinting ) local font = ImGui.GetIO( ).Fonts:AddFontFromFileTTF( 'C:/windows/fonts/verdana.ttf', 13, font_config, ImGui.GetIO( ).Fonts:GetGlyphRangesCyrillic( ) ) ImGui.Paint( function( ) ImGui.Begin( 'Window' ) ImGui.PushFont( font ) ImGui.Text( 'Text FreeType' ) ImGui.PopFont( ) ImGui.End( ) end )
Updated VT
Fixed TextInputs
Added TextLink
![]()
Lua:local ImGui = require( 'cimgui' ) ImGui.Paint( function( ) ImGui.Begin( 'Window' ) ImGui.TextLink( 'TextLink' ) if ImGui.TextLink( 'Second TextLink' ) then print( '123123' ) end ImGui.End( ) end )
Updated VT
Fixed glitch with textures
All TextInputs are temporarily inactive
imgui.OnInitialize has been removed
imgui.onFrame has been replaced by imgui.Paint
Lua:local ImGui = require( 'cimgui' ) ImGui.Paint( function( ) ImGui.Begin( 'Test' ) ImGui.End( ) end )
DrawBlurRect has been replaced by DrawBlur
Lua:local ImGui = require( 'cimgui' ) ImGui.Paint( function( ) ImGui.Begin( 'Test' ) local draw_list = ImGui.GetWindowDrawList( ) local pos, size = ImGui.GetWindowPos( ), ImGui.GetWindowSize( ) ImGui.DrawBlur( draw_list, pos, pos + size, ImGui.ImColor( 255, 0, 0, 255 ):U32( ) ) ImGui.End( ) end )
Updated VT
DrawCornerFlags replaced by DrawFlags
Added a new U32 method for ImColor and ImVec4
Lua:local ImGui = require( 'cimgui' ) ImGui.OnFrame( function( ) return true end, function( ) local draw_list = ImGui.GetBackgroundDrawList( ) local pos = ImGui.ImVec2( 200, 200 ) local size = ImGui.ImVec2( 100, 100 ) draw_list:AddRectFilled( pos, pos + size, ImGui.ImColor( 255, 255, 255, 255 ):U32( ) ) --does not crash draw_list:AddRectFilled( pos, pos + size, ImGui.ImVec4( 1, 1, 1, 1 ):U32( ) ) --does not crash draw_list:AddRectFilled( pos, pos + size, ImGui.U32( 1, 1, 1, 1 ) ) --does not crash draw_list:AddRectFilled( pos, pos + size, ImGui.ImColor( 255, 255, 255, 255 ) ) --crash draw_list:AddRectFilled( pos, pos + size, ImGui.ImVec4( 1, 1, 1, 1 ) ) --crash end )
Added DrawBlur( draw_list )
Added DrawBlurRect( draw_list, min, max, col, rounding, flags )
Updated VT