From 3ea02310f77dcf6aac26152a13a7ec848c78077f Mon Sep 17 00:00:00 2001 From: dam Date: Sun, 31 Mar 2024 23:47:35 +0100 Subject: WIP : Setup TUI styles. --- ttt.jai | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'ttt.jai') diff --git a/ttt.jai b/ttt.jai index 5229914..35a4bc2 100644 --- a/ttt.jai +++ b/ttt.jai @@ -1059,7 +1059,7 @@ draw_tui :: (db: *Database, layout: *Layout) { // Apply theme. if (task == active_task && task == selected_task) { // attron(COLOR_PAIR(xx Styles.ACTIVE_SELECTED) | A_BOLD); TODO DAM - TUI.set_style_colors(TUI.Colors8b.Red, 6); // TODO TESTING COLORS + TUI.set_style_colors(.RED, 6); // TODO TESTING COLORS TUI.set_style(true, true, true, false); } else if (task == selected_task) { @@ -1067,7 +1067,7 @@ draw_tui :: (db: *Database, layout: *Layout) { TUI.set_style_colors(4, 6); // TODO TESTING COLORS } else if (task == active_task) { - TUI.set_style_colors(TUI.Colors8b.Red, 6); // TODO TESTING COLORS + TUI.set_style_colors(.RED, 6); // TODO TESTING COLORS TUI.set_style(false, false, false, true); // TODO TESTING STYLE // attron(COLOR_PAIR(xx Styles.ACTIVE) | A_BOLD); TODO DAM } @@ -1224,7 +1224,7 @@ prompt_user_key :: (row: int, style: int, message: string) -> TUI.Key { TUI.set_cursor_position(row, 2); write_string(TUI.Commands.DrawingMode); - for 0..size_x-2 { + for 1..size_x-2 { print(TUI.Drawings.Checkerboard); } write_string(TUI.Commands.TextMode); @@ -1236,6 +1236,10 @@ prompt_user_key :: (row: int, style: int, message: string) -> TUI.Key { main :: () { + TUI.test(); + exit(0); + + // -- -- -- Testing TUI -- START perform_test := false; -- cgit v1.2.3