From 8779553b877a2bb728ddf9d7c21b272c2eedb653 Mon Sep 17 00:00:00 2001 From: dam Date: Tue, 7 May 2024 10:27:22 +0100 Subject: Fixed biggest performance bottleneck on draw_user_interface: print white spaces. --- modules/TUI/module.jai | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/TUI/module.jai') diff --git a/modules/TUI/module.jai b/modules/TUI/module.jai index 7c3a71d..a5db3bf 100644 --- a/modules/TUI/module.jai +++ b/modules/TUI/module.jai @@ -572,7 +572,7 @@ read_input_line :: (count_limit: int, is_visible: bool = true) -> string, Key { idx += 1; // Truncate string to avoid incomplete utf8 codes on the string tail. - truncate(*str, count_limit); + str.count = truncate(str, count_limit).count; } } -- cgit v1.2.3