From 644ba8d02eadddbf1f6526031806cd901eb68ae4 Mon Sep 17 00:00:00 2001 From: Ryan Fleury Date: Fri, 2 May 2025 15:28:56 -0700 Subject: [PATCH] theme presets work --- src/base/base_strings.c | 13 ++ src/base/base_strings.h | 1 + src/raddbg/generated/raddbg.meta.c | 15 +- src/raddbg/generated/raddbg.meta.h | 7 +- src/raddbg/raddbg.mdesk | 270 ++++++++++++++++++++++++++++- src/raddbg/raddbg_core.c | 47 ++++- src/raddbg/raddbg_views.c | 2 +- src/ui/ui_core.c | 27 ++- src/ui/ui_core.h | 1 + 9 files changed, 356 insertions(+), 27 deletions(-) diff --git a/src/base/base_strings.c b/src/base/base_strings.c index 47b94f74..d3823676 100644 --- a/src/base/base_strings.c +++ b/src/base/base_strings.c @@ -1174,6 +1174,19 @@ str8_array_reserve(Arena *arena, U64 count) return arr; } +internal String8Array +str8_array_copy(Arena *arena, String8Array array) +{ + String8Array result = {0}; + result.count = array.count; + result.v = push_array(arena, String8, result.count); + for EachIndex(idx, result.count) + { + result.v[idx] = push_str8_copy(arena, array.v[idx]); + } + return result; +} + //////////////////////////////// //~ rjf: String Path Helpers diff --git a/src/base/base_strings.h b/src/base/base_strings.h index 9e5878f0..d5ccaad1 100644 --- a/src/base/base_strings.h +++ b/src/base/base_strings.h @@ -291,6 +291,7 @@ internal void str8_list_from_flags(Arena *arena, String8List *list, U32 internal String8Array str8_array_zero(void); internal String8Array str8_array_from_list(Arena *arena, String8List *list); internal String8Array str8_array_reserve(Arena *arena, U64 count); +internal String8Array str8_array_copy(Arena *arena, String8Array array); //////////////////////////////// //~ rjf: String Path Helpers diff --git a/src/raddbg/generated/raddbg.meta.c b/src/raddbg/generated/raddbg.meta.c index c8ad4b9d..a80d3443 100644 --- a/src/raddbg/generated/raddbg.meta.c +++ b/src/raddbg/generated/raddbg.meta.c @@ -938,7 +938,7 @@ str8_lit_comp("code_line_numbers"), str8_lit_comp("code_line_numbers_selected"), }; -String8 rd_theme_preset_display_string_table[9] = +String8 rd_theme_preset_display_string_table[10] = { str8_lit_comp("Default (Dark)"), str8_lit_comp("Default (Light)"), @@ -948,10 +948,11 @@ str8_lit_comp("Solarized (Dark)"), str8_lit_comp("Solarized (Light)"), str8_lit_comp("Handmade Hero"), str8_lit_comp("4coder"), +str8_lit_comp("Grove"), str8_lit_comp("Far Manager"), }; -String8 rd_theme_preset_code_string_table[9] = +String8 rd_theme_preset_code_string_table[10] = { str8_lit_comp("default_dark"), str8_lit_comp("default_light"), @@ -961,19 +962,21 @@ str8_lit_comp("solarized_dark"), str8_lit_comp("solarized_light"), str8_lit_comp("handmade_hero"), str8_lit_comp("four_coder"), +str8_lit_comp("grove"), str8_lit_comp("far_manager"), }; -String8 rd_theme_preset_cfg_string_table[9] = +String8 rd_theme_preset_cfg_string_table[10] = { -str8_lit_comp("theme:\n{\n theme_color: {tags:\"background\", value: 0x1b1b1bff }\n theme_color: {tags:\"alt background\", value: 0x222222ff }\n theme_color: {tags:\"pop background\", value: 0x355b6eff }\n theme_color: {tags:\"fresh background\", value: 0x31393dff }\n theme_color: {tags:\"match background\", value: 0x31393dff }\n theme_color: {tags:\"border\", value: 0x404040ff }\n theme_color: {tags:\"text\", value: 0xe5e5e5ff }\n theme_color: {tags:\"weak text\", value: 0xa4a4a4ff }\n theme_color: {tags:\"good text\", value: 0x32a852ff }\n theme_color: {tags:\"neutral text\", value: 0x3a90bbff }\n theme_color: {tags:\"bad text\", value: 0xcf5242ff }\n theme_color: {tags:\"hover\", value: 0xffffffff }\n theme_color: {tags:\"focus\", value: 0xfda200ff }\n theme_color: {tags:\"cursor\", value: 0x8aff00ff }\n theme_color: {tags:\"selection\", value: 0x99ccff0f }\n theme_color: {tags:\"inactive background\", value: 0x0000002f }\n theme_color: {tags:\"drop_shadow\", value: 0x0000007f }\n theme_color: {tags:\"good_pop background\", value: 0x2c5b36ff }\n theme_color: {tags:\"good_pop border\", value: 0x568761ff }\n theme_color: {tags:\"good_pop hover\", value: 0xe3f5d3ff }\n theme_color: {tags:\"good_pop weak text\", value: 0xe3f5d3ff }\n theme_color: {tags:\"bad_pop background\", value: 0x803425ff }\n theme_color: {tags:\"bad_pop hover\", value: 0xff825cff }\n theme_color: {tags:\"code_default\", value: 0xcbcbcbff }\n theme_color: {tags:\"code_symbol\", value: 0x42a2cfff }\n theme_color: {tags:\"code_type\", value: 0xfec746ff }\n theme_color: {tags:\"code_local\", value: 0x98bc80ff }\n theme_color: {tags:\"code_register\", value: 0xb7afd5ff }\n theme_color: {tags:\"code_keyword\", value: 0xb38d4cff }\n theme_color: {tags:\"code_delimiter_or_operator\", value: 0x767676ff }\n theme_color: {tags:\"code_numeric\", value: 0x98abb1ff }\n theme_color: {tags:\"code_numeric_alt_digit_group\", value: 0x738287ff }\n theme_color: {tags:\"code_string\", value: 0x98abb1ff }\n theme_color: {tags:\"code_meta\", value: 0xd96759ff }\n theme_color: {tags:\"code_comment\", value: 0x717171ff }\n theme_color: {tags:\"line_info_0\", value: 0x4f3022ff }\n theme_color: {tags:\"line_info_1\", value: 0x4f3e15ff }\n theme_color: {tags:\"line_info_2\", value: 0x434e2aff }\n theme_color: {tags:\"line_info_3\", value: 0x36241fff }\n theme_color: {tags:\"line_info_4\", value: 0x4f3022ff }\n theme_color: {tags:\"line_info_5\", value: 0x4f3e15ff }\n theme_color: {tags:\"line_info_6\", value: 0x434e2aff }\n theme_color: {tags:\"line_info_7\", value: 0x36241fff }\n theme_color: {tags:\"thread_0\", value: 0xffcb7fff }\n theme_color: {tags:\"thread_1\", value: 0xb2ff65ff }\n theme_color: {tags:\"thread_2\", value: 0xff99e5ff }\n theme_color: {tags:\"thread_3\", value: 0x6598ffff }\n theme_color: {tags:\"thread_4\", value: 0x65ffcbff }\n theme_color: {tags:\"thread_5\", value: 0xff9819ff }\n theme_color: {tags:\"thread_6\", value: 0x9932ffff }\n theme_color: {tags:\"thread_7\", value: 0x65ff4cff }\n theme_color: {tags:\"thread_unwound\", value: 0xb2ccd8ff }\n theme_color: {tags:\"thread_error\", value: 0xb23219ff }\n theme_color: {tags:\"breakpoint\", value: 0xa72911ff }\n theme_color: {tags:\"floating background\", value: 0x1b1b1baf }\n theme_color: {tags:\"floating background alt\", value: 0x0000005f }\n theme_color: {tags:\"floating background fresh\", value: 0x31393d5f }\n theme_color: {tags:\"floating border\", value: 0xbfbfbf1f }\n theme_color: {tags:\"floating scroll_bar background\", value: 0x3b3b3b5f }\n theme_color: {tags:\"floating scroll_bar border\", value: 0x5f5f5f5f }\n theme_color: {tags:\"menu_bar background\", value: 0x2b3740ff }\n theme_color: {tags:\"menu_bar border\", value: 0x3e4c57ff }\n theme_color: {tags:\"scroll_bar background\", value: 0x2b2b2bff }\n theme_color: {tags:\"scroll_bar border\", value: 0x3f3f3fff }\n theme_color: {tags:\"implicit background\", value: 0x00000000 }\n theme_color: {tags:\"implicit border\", value: 0x00000000 }\n theme_color: {tags:\"hollow background\", value: 0x00000000 }\n theme_color: {tags:\"hollow border\", value: 0xffffff1f }\n theme_color: {tags:\"tab background\", value: 0x6f5135ff }\n theme_color: {tags:\"tab border\", value: 0x8a6e54ff }\n theme_color: {tags:\"tab inactive background\", value: 0x2b3740ff }\n theme_color: {tags:\"tab inactive border\", value: 0x3e4c57ff }\n theme_color: {tags:\"tab auto background\", value: 0x693847ff }\n theme_color: {tags:\"tab auto border\", value: 0x9e6274ff }\n theme_color: {tags:\"tab auto inactive background\", value: 0x2f2633ff }\n theme_color: {tags:\"tab auto inactive border\", value: 0x685073ff }\n theme_color: {tags:\"drop_site background\", value: 0xffffff05 }\n theme_color: {tags:\"drop_site border\", value: 0xffffff0f }\n}\n"), -str8_lit_comp(""), -str8_lit_comp("theme:\n{\n background: 0x1b0000ff,\n}\n"), +str8_lit_comp("theme:\n{\n theme_color: {tags:\"background\", value: 0x1b1b1bff }\n theme_color: {tags:\"alt background\", value: 0x222222ff }\n theme_color: {tags:\"pop background\", value: 0x355b6eff }\n theme_color: {tags:\"fresh background\", value: 0x31393dff }\n theme_color: {tags:\"match background\", value: 0x31393dff }\n theme_color: {tags:\"border\", value: 0x404040ff }\n theme_color: {tags:\"text\", value: 0xe5e5e5ff }\n theme_color: {tags:\"weak text\", value: 0xa4a4a4ff }\n theme_color: {tags:\"good text\", value: 0x32a852ff }\n theme_color: {tags:\"neutral text\", value: 0x3a90bbff }\n theme_color: {tags:\"bad text\", value: 0xcf5242ff }\n theme_color: {tags:\"hover\", value: 0xffffffff }\n theme_color: {tags:\"focus overlay\", value: 0xfda20012 }\n theme_color: {tags:\"focus border\", value: 0xfda200ff }\n theme_color: {tags:\"cursor\", value: 0x8aff00ff }\n theme_color: {tags:\"selection\", value: 0x99ccff0f }\n theme_color: {tags:\"inactive background\", value: 0x0000002f }\n theme_color: {tags:\"drop_shadow\", value: 0x0000007f }\n theme_color: {tags:\"good_pop background\", value: 0x2c5b36ff }\n theme_color: {tags:\"good_pop border\", value: 0x568761ff }\n theme_color: {tags:\"good_pop hover\", value: 0xe3f5d3ff }\n theme_color: {tags:\"good_pop weak text\", value: 0xe3f5d3ff }\n theme_color: {tags:\"bad_pop background\", value: 0x803425ff }\n theme_color: {tags:\"bad_pop hover\", value: 0xff825cff }\n theme_color: {tags:\"code_default\", value: 0xcbcbcbff }\n theme_color: {tags:\"code_symbol\", value: 0x42a2cfff }\n theme_color: {tags:\"code_type\", value: 0xfec746ff }\n theme_color: {tags:\"code_local\", value: 0x98bc80ff }\n theme_color: {tags:\"code_register\", value: 0xb7afd5ff }\n theme_color: {tags:\"code_keyword\", value: 0xb38d4cff }\n theme_color: {tags:\"code_delimiter_or_operator\", value: 0x767676ff }\n theme_color: {tags:\"code_numeric\", value: 0x98abb1ff }\n theme_color: {tags:\"code_numeric_alt_digit_group\", value: 0x738287ff }\n theme_color: {tags:\"code_string\", value: 0x98abb1ff }\n theme_color: {tags:\"code_meta\", value: 0xd96759ff }\n theme_color: {tags:\"code_comment\", value: 0x717171ff }\n theme_color: {tags:\"line_info_0\", value: 0x4f3022ff }\n theme_color: {tags:\"line_info_1\", value: 0x4f3e15ff }\n theme_color: {tags:\"line_info_2\", value: 0x434e2aff }\n theme_color: {tags:\"line_info_3\", value: 0x36241fff }\n theme_color: {tags:\"line_info_4\", value: 0x4f3022ff }\n theme_color: {tags:\"line_info_5\", value: 0x4f3e15ff }\n theme_color: {tags:\"line_info_6\", value: 0x434e2aff }\n theme_color: {tags:\"line_info_7\", value: 0x36241fff }\n theme_color: {tags:\"thread_0\", value: 0xffcb7fff }\n theme_color: {tags:\"thread_1\", value: 0xb2ff65ff }\n theme_color: {tags:\"thread_2\", value: 0xff99e5ff }\n theme_color: {tags:\"thread_3\", value: 0x6598ffff }\n theme_color: {tags:\"thread_4\", value: 0x65ffcbff }\n theme_color: {tags:\"thread_5\", value: 0xff9819ff }\n theme_color: {tags:\"thread_6\", value: 0x9932ffff }\n theme_color: {tags:\"thread_7\", value: 0x65ff4cff }\n theme_color: {tags:\"thread_unwound\", value: 0xb2ccd8ff }\n theme_color: {tags:\"thread_error\", value: 0xb23219ff }\n theme_color: {tags:\"breakpoint\", value: 0xa72911ff }\n theme_color: {tags:\"floating background\", value: 0x1b1b1baf }\n theme_color: {tags:\"floating background alt\", value: 0x0000005f }\n theme_color: {tags:\"floating background fresh\", value: 0x31393d5f }\n theme_color: {tags:\"floating border\", value: 0xbfbfbf1f }\n theme_color: {tags:\"floating scroll_bar background\", value: 0x3b3b3b5f }\n theme_color: {tags:\"floating scroll_bar border\", value: 0x5f5f5f5f }\n theme_color: {tags:\"menu_bar background\", value: 0x2b3740ff }\n theme_color: {tags:\"menu_bar border\", value: 0x3e4c57ff }\n theme_color: {tags:\"scroll_bar background\", value: 0x2b2b2bff }\n theme_color: {tags:\"scroll_bar border\", value: 0x3f3f3fff }\n theme_color: {tags:\"implicit background\", value: 0x00000000 }\n theme_color: {tags:\"implicit border\", value: 0x00000000 }\n theme_color: {tags:\"hollow background\", value: 0x00000000 }\n theme_color: {tags:\"hollow border\", value: 0xffffff1f }\n theme_color: {tags:\"tab background\", value: 0x6f5135ff }\n theme_color: {tags:\"tab border\", value: 0x8a6e54ff }\n theme_color: {tags:\"tab inactive background\", value: 0x2b3740ff }\n theme_color: {tags:\"tab inactive border\", value: 0x3e4c57ff }\n theme_color: {tags:\"tab auto background\", value: 0x693847ff }\n theme_color: {tags:\"tab auto border\", value: 0x9e6274ff }\n theme_color: {tags:\"tab auto inactive background\", value: 0x2f2633ff }\n theme_color: {tags:\"tab auto inactive border\", value: 0x685073ff }\n theme_color: {tags:\"drop_site background\", value: 0xffffff05 }\n theme_color: {tags:\"drop_site border\", value: 0xffffff0f }\n}\n"), +str8_lit_comp("theme:\n{\n theme_color:{ tags: background value: 0xffffffff }\n theme_color:{ tags: \"alt background\" value: 0xf8f8f8ff }\n theme_color:{ tags: \"pop background\" value: 0xcbe4f2ff }\n theme_color:{ tags: \"menu_bar pop background\" value: 0x5aabd9ff }\n theme_color:{ tags: \"fresh background\" value: 0xeaddceff }\n theme_color:{ tags: \"match background\" value: 0xc1e9c4ff }\n theme_color:{ tags: border value: 0xcbcbcbff }\n theme_color:{ tags: text value: 0xff }\n theme_color:{ tags: \"weak text\" value: 0x727272ff }\n theme_color:{ tags: \"good text\" value: 0x217538ff }\n theme_color:{ tags: \"neutral text\" value: 0x1a5b7cff }\n theme_color:{ tags: \"bad text\" value: 0x972717ff }\n theme_color:{ tags: hover value: 0xff }\n theme_color:{ tags: \"focus overlay\" value: 0x67ff4b }\n theme_color:{ tags: \"focus border\" value: 0x67ffff }\n theme_color:{ tags: cursor value: 0xff }\n theme_color:{ tags: selection value: 0x283d5166 }\n theme_color:{ tags: \"inactive background\" value: 0x8 }\n theme_color:{ tags: drop_shadow value: 0xb }\n theme_color:{ tags: \"good_pop background\" value: 0x90c09aff }\n theme_color:{ tags: \"good_pop border\" value: 0x1e7231ff }\n theme_color:{ tags: \"good_pop hover\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"good_pop weak text\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"good_pop text\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"bad_pop background\" value: 0xa93620ff }\n theme_color:{ tags: \"bad_pop text\" value: 0xffffffff }\n theme_color:{ tags: \"bad_pop text weak\" value: 0xffffffff }\n theme_color:{ tags: \"menu_bar bad_pop background\" value: 0xff2a00ff }\n theme_color:{ tags: \"menu_bar bad_pop text\" value: 0xffffffff }\n theme_color:{ tags: \"bad_pop hover\" value: 0xff825cff }\n theme_color:{ tags: code_default value: 0x80808ff }\n theme_color:{ tags: code_symbol value: 0x4ac3ff }\n theme_color:{ tags: code_type value: 0xf46200ff }\n theme_color:{ tags: code_local value: 0x317c00ff }\n theme_color:{ tags: code_register value: 0x9a00ffff }\n theme_color:{ tags: code_keyword value: 0xff0600ff }\n theme_color:{ tags: code_delimiter_or_operator value: 0x8a8a8aff }\n theme_color:{ tags: code_numeric value: 0x7d49ff }\n theme_color:{ tags: code_numeric_alt_digit_group value: 0xb56aff }\n theme_color:{ tags: code_string value: 0x63549fff }\n theme_color:{ tags: code_meta value: 0xd96759ff }\n theme_color:{ tags: code_comment value: 0x717171ff }\n theme_color:{ tags: line_info_0 value: 0xe6d5cdff }\n theme_color:{ tags: line_info_1 value: 0xdbcfb2ff }\n theme_color:{ tags: line_info_2 value: 0xddeac1ff }\n theme_color:{ tags: line_info_3 value: 0xddc4bdff }\n theme_color:{ tags: line_info_4 value: 0xba917eff }\n theme_color:{ tags: thread_0 value: 0xffa700ff }\n theme_color:{ tags: thread_1 value: 0xb41fff }\n theme_color:{ tags: thread_2 value: 0xff99e5ff }\n theme_color:{ tags: thread_3 value: 0x6598ffff }\n theme_color:{ tags: thread_4 value: 0x65ffcbff }\n theme_color:{ tags: thread_5 value: 0xff9819ff }\n theme_color:{ tags: thread_6 value: 0x9932ffff }\n theme_color:{ tags: thread_7 value: 0x65ff4cff }\n theme_color:{ tags: thread_unwound value: 0xb2ccd8ff }\n theme_color:{ tags: thread_error value: 0xb23219ff }\n theme_color:{ tags: breakpoint value: 0xff2800ff }\n theme_color:{ tags: \"floating background\" value: 0xffffffc7 }\n theme_color:{ tags: \"floating background alt\" value: 0x23 }\n theme_color:{ tags: \"floating background fresh\" value: 0xeaddceff }\n theme_color:{ tags: \"floating border\" value: 0x88888884 }\n theme_color:{ tags: \"scroll_bar background\" value: 0xe9e9e9ff }\n theme_color:{ tags: \"scroll_bar border\" value: 0x5f5f5f5f }\n theme_color:{ tags: \"floating scroll_bar background\" value: 0xe9e9e9ff }\n theme_color:{ tags: \"floating scroll_bar border\" value: 0x5f5f5f5f }\n theme_color:{ tags: \"menu_bar background\" value: 0x2b6b9aff }\n theme_color:{ tags: \"menu_bar border\" value: 0x4d }\n theme_color:{ tags: \"menu_bar text\" value: 0xffffffff }\n theme_color:{ tags: \"menu_bar text weak\" value: 0xffffffff }\n theme_color:{ tags: \"good menu_bar text\" value: 0x70db8dff }\n theme_color:{ tags: \"bad menu_bar text\" value: 0xffa79bff }\n theme_color:{ tags: \"neutral menu_bar text\" value: 0xc4dbe7ff }\n theme_color:{ tags: \"implicit background\" value: 0x00000000 }\n theme_color:{ tags: \"implicit border\" value: 0x00000000 }\n theme_color:{ tags: \"hollow background\" value: 0x00000000 }\n theme_color:{ tags: \"hollow border\" value: 0xffffff1f }\n theme_color:{ tags: \"tab text\" value: 0xffffffff }\n theme_color:{ tags: \"tab text weak\" value: 0xffffffff }\n theme_color:{ tags: \"tab background\" value: 0xb67e48ff }\n theme_color:{ tags: \"tab border\" value: 0x875b31ff }\n theme_color:{ tags: \"tab inactive background\" value: 0xcacacaff }\n theme_color:{ tags: \"tab inactive border\" value: 0xb5b5b5ff }\n theme_color:{ tags: \"tab auto background\" value: 0xc41c69ff }\n theme_color:{ tags: \"tab auto border\" value: 0x981039ff }\n theme_color:{ tags: \"tab auto inactive background\" value: 0x9b88a3ff }\n theme_color:{ tags: \"tab auto inactive border\" value: 0x373737ff }\n theme_color:{ tags: \"drop_site background\" value: 0xffffff05 }\n theme_color:{ tags: \"drop_site border\" value: 0xffffff0f }\n}\n"), +str8_lit_comp("theme:\n{\n theme_color:{ tags: background value: 0x1f1f1fff }\n theme_color:{ tags: \"alt background\" value: 0x222222ff }\n theme_color:{ tags: \"pop background\" value: 0x383167ff }\n theme_color:{ tags: \"fresh background\" value: 0x31393dff }\n theme_color:{ tags: \"match background\" value: 0x31393dff }\n theme_color:{ tags: border value: 0x404040ff }\n theme_color:{ tags: text value: 0xe5e5e5ff }\n theme_color:{ tags: \"weak text\" value: 0xa4a4a4ff }\n theme_color:{ tags: \"good text\" value: 0x32a852ff }\n theme_color:{ tags: \"neutral text\" value: 0x3a90bbff }\n theme_color:{ tags: \"bad text\" value: 0xcf5242ff }\n theme_color:{ tags: hover value: 0xffffffff }\n theme_color:{ tags: \"focus overlay\" value: 0x7160e81e }\n theme_color:{ tags: \"focus border\" value: 0x7160e8ff }\n theme_color:{ tags: cursor value: 0x8aff00ff }\n theme_color:{ tags: selection value: 0x99ccff0f }\n theme_color:{ tags: \"inactive background\" value: 0x0000002f }\n theme_color:{ tags: drop_shadow value: 0x0000007f }\n theme_color:{ tags: \"good_pop background\" value: 0x2c5b36ff }\n theme_color:{ tags: \"good_pop border\" value: 0x568761ff }\n theme_color:{ tags: \"good_pop hover\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"good_pop weak text\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"bad_pop background\" value: 0x803425ff }\n theme_color:{ tags: \"bad_pop hover\" value: 0xff825cff }\n theme_color:{ tags: code_default value: 0xe0e0e0ff }\n theme_color:{ tags: code_symbol value: 0xdcdcaaff }\n theme_color:{ tags: code_type value: 0x4ec9b0ff }\n theme_color:{ tags: code_local value: 0x9cdcfeff }\n theme_color:{ tags: code_register value: 0xb7afd5ff }\n theme_color:{ tags: code_keyword value: 0x569cd6ff }\n theme_color:{ tags: code_delimiter_or_operator value: 0x767676ff }\n theme_color:{ tags: code_numeric value: 0xb5cea8ff }\n theme_color:{ tags: code_numeric_alt_digit_group value: 0x7c986dff }\n theme_color:{ tags: code_string value: 0xd69d85ff }\n theme_color:{ tags: code_meta value: 0x9b9b9bff }\n theme_color:{ tags: code_comment value: 0x51a644ff }\n theme_color:{ tags: line_info_0 value: 0x4f3022ff }\n theme_color:{ tags: line_info_1 value: 0x4f3e15ff }\n theme_color:{ tags: line_info_2 value: 0x434e2aff }\n theme_color:{ tags: line_info_3 value: 0x36241fff }\n theme_color:{ tags: line_info_4 value: 0x4f3022ff }\n theme_color:{ tags: line_info_5 value: 0x4f3e15ff }\n theme_color:{ tags: line_info_6 value: 0x434e2aff }\n theme_color:{ tags: line_info_7 value: 0x36241fff }\n theme_color:{ tags: thread_0 value: 0xffdc48ff }\n theme_color:{ tags: thread_1 value: 0xb2ff65ff }\n theme_color:{ tags: thread_2 value: 0xff99e5ff }\n theme_color:{ tags: thread_3 value: 0x6598ffff }\n theme_color:{ tags: thread_4 value: 0x65ffcbff }\n theme_color:{ tags: thread_5 value: 0xff9819ff }\n theme_color:{ tags: thread_6 value: 0x9932ffff }\n theme_color:{ tags: thread_7 value: 0x65ff4cff }\n theme_color:{ tags: thread_unwound value: 0xb2ccd8ff }\n theme_color:{ tags: thread_error value: 0xb23219ff }\n theme_color:{ tags: breakpoint value: 0xa72911ff }\n theme_color:{ tags: \"floating background\" value: 0x1b1b1baf }\n theme_color:{ tags: \"floating background alt\" value: 0x0000005f }\n theme_color:{ tags: \"floating background fresh\" value: 0x31393d5f }\n theme_color:{ tags: \"floating border\" value: 0xbfbfbf1f }\n theme_color:{ tags: \"floating scroll_bar background\" value: 0x3b3b3b5f }\n theme_color:{ tags: \"floating scroll_bar border\" value: 0x5f5f5f5f }\n theme_color:{ tags: \"scroll_bar background\" value: 0x2b2b2bff }\n theme_color:{ tags: \"scroll_bar border\" value: 0x3f3f3fff }\n theme_color:{ tags: \"implicit background\" value: 0x00000000 }\n theme_color:{ tags: \"implicit border\" value: 0x00000000 }\n theme_color:{ tags: \"hollow background\" value: 0x00000000 }\n theme_color:{ tags: \"hollow border\" value: 0xffffff1f }\n theme_color:{ tags: \"tab background\" value: 0x333333ff }\n theme_color:{ tags: \"tab border\" value: 0x7160e8ff }\n theme_color:{ tags: \"tab inactive background\" value: 0x171717ff }\n theme_color:{ tags: \"tab inactive border\" value: 0x3e4c57ff }\n theme_color:{ tags: \"tab auto background\" value: 0x3f386dff }\n theme_color:{ tags: \"tab auto border\" value: 0x7160e8ff }\n theme_color:{ tags: \"tab auto inactive background\" value: 0x2f2633ff }\n theme_color:{ tags: \"tab auto inactive border\" value: 0x685073ff }\n theme_color:{ tags: \"drop_site background\" value: 0xffffff05 }\n theme_color:{ tags: \"drop_site border\" value: 0xffffff0f }\n}\n"), str8_lit_comp(""), str8_lit_comp(""), str8_lit_comp(""), str8_lit_comp(""), str8_lit_comp(""), +str8_lit_comp("theme:\n{\n theme_color:{ tags: background value: 0x1b1f22ff }\n theme_color:{ tags: \"alt background\" value: 0x232929ff }\n theme_color:{ tags: \"pop background\" value: 0x2f4838ff }\n theme_color:{ tags: \"fresh background\" value: 0x31393dff }\n theme_color:{ tags: \"match background\" value: 0x31393dff }\n theme_color:{ tags: border value: 0x485347ff }\n theme_color:{ tags: text value: 0xffffffff }\n theme_color:{ tags: \"weak text\" value: 0xa2a2a2ff }\n theme_color:{ tags: \"good text\" value: 0x32a852ff }\n theme_color:{ tags: \"neutral text\" value: 0x3a90bbff }\n theme_color:{ tags: \"bad text\" value: 0xcf5242ff }\n theme_color:{ tags: hover value: 0xffffffff }\n theme_color:{ tags: \"focus overlay\" value: 0xfda20012 }\n theme_color:{ tags: \"focus border\" value: 0xfda200ff }\n theme_color:{ tags: cursor value: 0x8aff00ff }\n theme_color:{ tags: selection value: 0x99ccff0f }\n theme_color:{ tags: \"inactive background\" value: 0x0 }\n theme_color:{ tags: drop_shadow value: 0x0000007f }\n theme_color:{ tags: \"good_pop background\" value: 0x2c5b36ff }\n theme_color:{ tags: \"good_pop border\" value: 0x568761ff }\n theme_color:{ tags: \"good_pop hover\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"good_pop weak text\" value: 0xe3f5d3ff }\n theme_color:{ tags: \"bad_pop background\" value: 0x803425ff }\n theme_color:{ tags: \"bad_pop hover\" value: 0xff825cff }\n theme_color:{ tags: code_default value: 0xad8b69ff }\n theme_color:{ tags: code_symbol value: 0x87ad6aff }\n theme_color:{ tags: code_type value: 0xb67474ff }\n theme_color:{ tags: code_local value: 0xe9bf95ff }\n theme_color:{ tags: code_register value: 0xa688b2ff }\n theme_color:{ tags: code_keyword value: 0xe49e17ff }\n theme_color:{ tags: code_delimiter_or_operator value: 0x795e43ff }\n theme_color:{ tags: code_numeric value: 0x98b19eff }\n theme_color:{ tags: code_numeric_alt_digit_group value: 0x688b71ff }\n theme_color:{ tags: code_string value: 0x98b19eff }\n theme_color:{ tags: code_meta value: 0xad5979ff }\n theme_color:{ tags: code_comment value: 0x52675dff }\n theme_color:{ tags: line_info_0 value: 0x4f3022ff }\n theme_color:{ tags: line_info_1 value: 0x4f3e15ff }\n theme_color:{ tags: line_info_2 value: 0x434e2aff }\n theme_color:{ tags: line_info_3 value: 0x36241fff }\n theme_color:{ tags: line_info_4 value: 0x4f3022ff }\n theme_color:{ tags: line_info_5 value: 0x4f3e15ff }\n theme_color:{ tags: line_info_6 value: 0x434e2aff }\n theme_color:{ tags: line_info_7 value: 0x36241fff }\n theme_color:{ tags: thread_0 value: 0xffc258ff }\n theme_color:{ tags: thread_1 value: 0x82d331ff }\n theme_color:{ tags: thread_2 value: 0xff99e5ff }\n theme_color:{ tags: thread_3 value: 0x6598ffff }\n theme_color:{ tags: thread_4 value: 0x65ffcbff }\n theme_color:{ tags: thread_5 value: 0xff9819ff }\n theme_color:{ tags: thread_6 value: 0x9932ffff }\n theme_color:{ tags: thread_7 value: 0x65ff4cff }\n theme_color:{ tags: thread_unwound value: 0xb2ccd8ff }\n theme_color:{ tags: thread_error value: 0xb23219ff }\n theme_color:{ tags: breakpoint value: 0xa72911ff }\n theme_color:{ tags: \"floating background\" value: 0x1b1f2276 }\n theme_color:{ tags: \"floating background alt\" value: 0x0000005f }\n theme_color:{ tags: \"floating background fresh\" value: 0x31393d5f }\n theme_color:{ tags: \"floating border\" value: 0xbfbfbf1f }\n theme_color:{ tags: \"floating scroll_bar background\" value: 0x3b3b3b5f }\n theme_color:{ tags: \"floating scroll_bar border\" value: 0x5f5f5f5f }\n theme_color:{ tags: \"menu_bar background\" value: 0x243d32ff }\n theme_color:{ tags: \"menu_bar border\" value: 0x597b63ff }\n theme_color:{ tags: \"scroll_bar background\" value: 0x232929ff }\n theme_color:{ tags: \"scroll_bar border\" value: 0x3c4a3fff }\n theme_color:{ tags: \"implicit background\" value: 0x00000000 }\n theme_color:{ tags: \"implicit border\" value: 0x00000000 }\n theme_color:{ tags: \"hollow background\" value: 0x00000000 }\n theme_color:{ tags: \"hollow border\" value: 0xffffff1f }\n theme_color:{ tags: \"tab background\" value: 0x243d32ff }\n theme_color:{ tags: \"tab border\" value: 0x597b63ff }\n theme_color:{ tags: \"tab inactive background\" value: 0x30383eff }\n theme_color:{ tags: \"tab inactive border\" value: 0x6b7680ff }\n theme_color:{ tags: \"tab auto background\" value: 0x30636dff }\n theme_color:{ tags: \"tab auto border\" value: 0x768f94ff }\n theme_color:{ tags: \"tab auto inactive background\" value: 0x2f2633ff }\n theme_color:{ tags: \"tab auto inactive border\" value: 0x685073ff }\n theme_color:{ tags: \"drop_site background\" value: 0xffffff05 }\n theme_color:{ tags: \"drop_site border\" value: 0xffffff0f }\n}\n"), str8_lit_comp(""), }; diff --git a/src/raddbg/generated/raddbg.meta.h b/src/raddbg/generated/raddbg.meta.h index b6a08655..d966c718 100644 --- a/src/raddbg/generated/raddbg.meta.h +++ b/src/raddbg/generated/raddbg.meta.h @@ -395,6 +395,7 @@ RD_ThemePreset_SolarizedDark, RD_ThemePreset_SolarizedLight, RD_ThemePreset_HandmadeHero, RD_ThemePreset_FourCoder, +RD_ThemePreset_Grove, RD_ThemePreset_FarManager, RD_ThemePreset_COUNT, } RD_ThemePreset; @@ -565,9 +566,9 @@ extern String8 rd_binding_version_remap_old_name_table[8]; extern String8 rd_binding_version_remap_new_name_table[8]; extern String8 rd_icon_kind_text_table[75]; extern String8 rd_code_color_slot_name_table[14]; -extern String8 rd_theme_preset_display_string_table[9]; -extern String8 rd_theme_preset_code_string_table[9]; -extern String8 rd_theme_preset_cfg_string_table[9]; +extern String8 rd_theme_preset_display_string_table[10]; +extern String8 rd_theme_preset_code_string_table[10]; +extern String8 rd_theme_preset_cfg_string_table[10]; read_only global U8 rd_icon_font_bytes__data[] = { 0x00,0x01,0x00,0x00,0x00,0x0f,0x00,0x80,0x00,0x03,0x00,0x70,0x47,0x53,0x55,0x42,0x20,0x8b,0x25,0x7a,0x00,0x00,0x00,0xfc,0x00,0x00,0x00,0x54,0x4f,0x53,0x2f,0x32,0x56,0x43,0x62,0x25,0x00,0x00,0x01,0x50,0x00,0x00,0x00,0x60,0x63,0x6d,0x61,0x70,0xa3,0x60,0xa4,0x23,0x00,0x00,0x01,0xb0,0x00,0x00,0x06,0x12,0x63,0x76,0x74,0x20, diff --git a/src/raddbg/raddbg.mdesk b/src/raddbg/raddbg.mdesk index 9748ef1f..9d896b22 100644 --- a/src/raddbg/raddbg.mdesk +++ b/src/raddbg/raddbg.mdesk @@ -1381,7 +1381,8 @@ RD_ThemePresetTable: theme_color: {tags:"neutral text", value: 0x3a90bbff } theme_color: {tags:"bad text", value: 0xcf5242ff } theme_color: {tags:"hover", value: 0xffffffff } - theme_color: {tags:"focus", value: 0xfda200ff } + theme_color: {tags:"focus overlay", value: 0xfda20012 } + theme_color: {tags:"focus border", value: 0xfda200ff } theme_color: {tags:"cursor", value: 0x8aff00ff } theme_color: {tags:"selection", value: 0x99ccff0f } theme_color: {tags:"inactive background", value: 0x0000002f } @@ -1451,21 +1452,284 @@ RD_ThemePresetTable: ``` } - { DefaultLight default_light "Default (Light)" } + //- rjf: default light theme + { DefaultLight default_light "Default (Light)", + ```theme: + { + theme_color:{ tags: background value: 0xffffffff } + theme_color:{ tags: "alt background" value: 0xf8f8f8ff } + theme_color:{ tags: "pop background" value: 0xcbe4f2ff } + theme_color:{ tags: "menu_bar pop background" value: 0x5aabd9ff } + theme_color:{ tags: "fresh background" value: 0xeaddceff } + theme_color:{ tags: "match background" value: 0xc1e9c4ff } + theme_color:{ tags: border value: 0xcbcbcbff } + theme_color:{ tags: text value: 0xff } + theme_color:{ tags: "weak text" value: 0x727272ff } + theme_color:{ tags: "good text" value: 0x217538ff } + theme_color:{ tags: "neutral text" value: 0x1a5b7cff } + theme_color:{ tags: "bad text" value: 0x972717ff } + theme_color:{ tags: hover value: 0xff } + theme_color:{ tags: "focus overlay" value: 0x67ff4b } + theme_color:{ tags: "focus border" value: 0x67ffff } + theme_color:{ tags: cursor value: 0xff } + theme_color:{ tags: selection value: 0x283d5166 } + theme_color:{ tags: "inactive background" value: 0x8 } + theme_color:{ tags: drop_shadow value: 0xb } + theme_color:{ tags: "good_pop background" value: 0x90c09aff } + theme_color:{ tags: "good_pop border" value: 0x1e7231ff } + theme_color:{ tags: "good_pop hover" value: 0xe3f5d3ff } + theme_color:{ tags: "good_pop weak text" value: 0xe3f5d3ff } + theme_color:{ tags: "good_pop text" value: 0xe3f5d3ff } + theme_color:{ tags: "bad_pop background" value: 0xa93620ff } + theme_color:{ tags: "bad_pop text" value: 0xffffffff } + theme_color:{ tags: "bad_pop text weak" value: 0xffffffff } + theme_color:{ tags: "menu_bar bad_pop background" value: 0xff2a00ff } + theme_color:{ tags: "menu_bar bad_pop text" value: 0xffffffff } + theme_color:{ tags: "bad_pop hover" value: 0xff825cff } + theme_color:{ tags: code_default value: 0x80808ff } + theme_color:{ tags: code_symbol value: 0x4ac3ff } + theme_color:{ tags: code_type value: 0xf46200ff } + theme_color:{ tags: code_local value: 0x317c00ff } + theme_color:{ tags: code_register value: 0x9a00ffff } + theme_color:{ tags: code_keyword value: 0xff0600ff } + theme_color:{ tags: code_delimiter_or_operator value: 0x8a8a8aff } + theme_color:{ tags: code_numeric value: 0x7d49ff } + theme_color:{ tags: code_numeric_alt_digit_group value: 0xb56aff } + theme_color:{ tags: code_string value: 0x63549fff } + theme_color:{ tags: code_meta value: 0xd96759ff } + theme_color:{ tags: code_comment value: 0x717171ff } + theme_color:{ tags: line_info_0 value: 0xe6d5cdff } + theme_color:{ tags: line_info_1 value: 0xdbcfb2ff } + theme_color:{ tags: line_info_2 value: 0xddeac1ff } + theme_color:{ tags: line_info_3 value: 0xddc4bdff } + theme_color:{ tags: line_info_4 value: 0xba917eff } + theme_color:{ tags: thread_0 value: 0xffa700ff } + theme_color:{ tags: thread_1 value: 0xb41fff } + theme_color:{ tags: thread_2 value: 0xff99e5ff } + theme_color:{ tags: thread_3 value: 0x6598ffff } + theme_color:{ tags: thread_4 value: 0x65ffcbff } + theme_color:{ tags: thread_5 value: 0xff9819ff } + theme_color:{ tags: thread_6 value: 0x9932ffff } + theme_color:{ tags: thread_7 value: 0x65ff4cff } + theme_color:{ tags: thread_unwound value: 0xb2ccd8ff } + theme_color:{ tags: thread_error value: 0xb23219ff } + theme_color:{ tags: breakpoint value: 0xff2800ff } + theme_color:{ tags: "floating background" value: 0xffffffc7 } + theme_color:{ tags: "floating background alt" value: 0x23 } + theme_color:{ tags: "floating background fresh" value: 0xeaddceff } + theme_color:{ tags: "floating border" value: 0x88888884 } + theme_color:{ tags: "scroll_bar background" value: 0xe9e9e9ff } + theme_color:{ tags: "scroll_bar border" value: 0x5f5f5f5f } + theme_color:{ tags: "floating scroll_bar background" value: 0xe9e9e9ff } + theme_color:{ tags: "floating scroll_bar border" value: 0x5f5f5f5f } + theme_color:{ tags: "menu_bar background" value: 0x2b6b9aff } + theme_color:{ tags: "menu_bar border" value: 0x4d } + theme_color:{ tags: "menu_bar text" value: 0xffffffff } + theme_color:{ tags: "menu_bar text weak" value: 0xffffffff } + theme_color:{ tags: "good menu_bar text" value: 0x70db8dff } + theme_color:{ tags: "bad menu_bar text" value: 0xffa79bff } + theme_color:{ tags: "neutral menu_bar text" value: 0xc4dbe7ff } + theme_color:{ tags: "implicit background" value: 0x00000000 } + theme_color:{ tags: "implicit border" value: 0x00000000 } + theme_color:{ tags: "hollow background" value: 0x00000000 } + theme_color:{ tags: "hollow border" value: 0xffffff1f } + theme_color:{ tags: "tab text" value: 0xffffffff } + theme_color:{ tags: "tab text weak" value: 0xffffffff } + theme_color:{ tags: "tab background" value: 0xb67e48ff } + theme_color:{ tags: "tab border" value: 0x875b31ff } + theme_color:{ tags: "tab inactive background" value: 0xcacacaff } + theme_color:{ tags: "tab inactive border" value: 0xb5b5b5ff } + theme_color:{ tags: "tab auto background" value: 0xc41c69ff } + theme_color:{ tags: "tab auto border" value: 0x981039ff } + theme_color:{ tags: "tab auto inactive background" value: 0x9b88a3ff } + theme_color:{ tags: "tab auto inactive border" value: 0x373737ff } + theme_color:{ tags: "drop_site background" value: 0xffffff05 } + theme_color:{ tags: "drop_site border" value: 0xffffff0f } + } + ``` + } + //- rjf: vs dark theme { VSDark vs_dark "VS (Dark)", ```theme: { - background: 0x1b0000ff, + theme_color:{ tags: background value: 0x1f1f1fff } + theme_color:{ tags: "alt background" value: 0x222222ff } + theme_color:{ tags: "pop background" value: 0x383167ff } + theme_color:{ tags: "fresh background" value: 0x31393dff } + theme_color:{ tags: "match background" value: 0x31393dff } + theme_color:{ tags: border value: 0x404040ff } + theme_color:{ tags: text value: 0xe5e5e5ff } + theme_color:{ tags: "weak text" value: 0xa4a4a4ff } + theme_color:{ tags: "good text" value: 0x32a852ff } + theme_color:{ tags: "neutral text" value: 0x3a90bbff } + theme_color:{ tags: "bad text" value: 0xcf5242ff } + theme_color:{ tags: hover value: 0xffffffff } + theme_color:{ tags: "focus overlay" value: 0x7160e81e } + theme_color:{ tags: "focus border" value: 0x7160e8ff } + theme_color:{ tags: cursor value: 0x8aff00ff } + theme_color:{ tags: selection value: 0x99ccff0f } + theme_color:{ tags: "inactive background" value: 0x0000002f } + theme_color:{ tags: drop_shadow value: 0x0000007f } + theme_color:{ tags: "good_pop background" value: 0x2c5b36ff } + theme_color:{ tags: "good_pop border" value: 0x568761ff } + theme_color:{ tags: "good_pop hover" value: 0xe3f5d3ff } + theme_color:{ tags: "good_pop weak text" value: 0xe3f5d3ff } + theme_color:{ tags: "bad_pop background" value: 0x803425ff } + theme_color:{ tags: "bad_pop hover" value: 0xff825cff } + theme_color:{ tags: code_default value: 0xe0e0e0ff } + theme_color:{ tags: code_symbol value: 0xdcdcaaff } + theme_color:{ tags: code_type value: 0x4ec9b0ff } + theme_color:{ tags: code_local value: 0x9cdcfeff } + theme_color:{ tags: code_register value: 0xb7afd5ff } + theme_color:{ tags: code_keyword value: 0x569cd6ff } + theme_color:{ tags: code_delimiter_or_operator value: 0x767676ff } + theme_color:{ tags: code_numeric value: 0xb5cea8ff } + theme_color:{ tags: code_numeric_alt_digit_group value: 0x7c986dff } + theme_color:{ tags: code_string value: 0xd69d85ff } + theme_color:{ tags: code_meta value: 0x9b9b9bff } + theme_color:{ tags: code_comment value: 0x51a644ff } + theme_color:{ tags: line_info_0 value: 0x4f3022ff } + theme_color:{ tags: line_info_1 value: 0x4f3e15ff } + theme_color:{ tags: line_info_2 value: 0x434e2aff } + theme_color:{ tags: line_info_3 value: 0x36241fff } + theme_color:{ tags: line_info_4 value: 0x4f3022ff } + theme_color:{ tags: line_info_5 value: 0x4f3e15ff } + theme_color:{ tags: line_info_6 value: 0x434e2aff } + theme_color:{ tags: line_info_7 value: 0x36241fff } + theme_color:{ tags: thread_0 value: 0xffdc48ff } + theme_color:{ tags: thread_1 value: 0xb2ff65ff } + theme_color:{ tags: thread_2 value: 0xff99e5ff } + theme_color:{ tags: thread_3 value: 0x6598ffff } + theme_color:{ tags: thread_4 value: 0x65ffcbff } + theme_color:{ tags: thread_5 value: 0xff9819ff } + theme_color:{ tags: thread_6 value: 0x9932ffff } + theme_color:{ tags: thread_7 value: 0x65ff4cff } + theme_color:{ tags: thread_unwound value: 0xb2ccd8ff } + theme_color:{ tags: thread_error value: 0xb23219ff } + theme_color:{ tags: breakpoint value: 0xa72911ff } + theme_color:{ tags: "floating background" value: 0x1b1b1baf } + theme_color:{ tags: "floating background alt" value: 0x0000005f } + theme_color:{ tags: "floating background fresh" value: 0x31393d5f } + theme_color:{ tags: "floating border" value: 0xbfbfbf1f } + theme_color:{ tags: "floating scroll_bar background" value: 0x3b3b3b5f } + theme_color:{ tags: "floating scroll_bar border" value: 0x5f5f5f5f } + theme_color:{ tags: "scroll_bar background" value: 0x2b2b2bff } + theme_color:{ tags: "scroll_bar border" value: 0x3f3f3fff } + theme_color:{ tags: "implicit background" value: 0x00000000 } + theme_color:{ tags: "implicit border" value: 0x00000000 } + theme_color:{ tags: "hollow background" value: 0x00000000 } + theme_color:{ tags: "hollow border" value: 0xffffff1f } + theme_color:{ tags: "tab background" value: 0x333333ff } + theme_color:{ tags: "tab border" value: 0x7160e8ff } + theme_color:{ tags: "tab inactive background" value: 0x171717ff } + theme_color:{ tags: "tab inactive border" value: 0x3e4c57ff } + theme_color:{ tags: "tab auto background" value: 0x3f386dff } + theme_color:{ tags: "tab auto border" value: 0x7160e8ff } + theme_color:{ tags: "tab auto inactive background" value: 0x2f2633ff } + theme_color:{ tags: "tab auto inactive border" value: 0x685073ff } + theme_color:{ tags: "drop_site background" value: 0xffffff05 } + theme_color:{ tags: "drop_site border" value: 0xffffff0f } } ``` } + + //- rjf: to-do { VSLight vs_light "VS (Light)" } { SolarizedDark solarized_dark "Solarized (Dark)" } { SolarizedLight solarized_light "Solarized (Light)" } { HandmadeHero handmade_hero "Handmade Hero" } { FourCoder four_coder "4coder" } + + //- rjf: grove theme + { Grove grove "Grove", + ```theme: + { + theme_color:{ tags: background value: 0x1b1f22ff } + theme_color:{ tags: "alt background" value: 0x232929ff } + theme_color:{ tags: "pop background" value: 0x2f4838ff } + theme_color:{ tags: "fresh background" value: 0x31393dff } + theme_color:{ tags: "match background" value: 0x31393dff } + theme_color:{ tags: border value: 0x485347ff } + theme_color:{ tags: text value: 0xffffffff } + theme_color:{ tags: "weak text" value: 0xa2a2a2ff } + theme_color:{ tags: "good text" value: 0x32a852ff } + theme_color:{ tags: "neutral text" value: 0x3a90bbff } + theme_color:{ tags: "bad text" value: 0xcf5242ff } + theme_color:{ tags: hover value: 0xffffffff } + theme_color:{ tags: "focus overlay" value: 0xfda20012 } + theme_color:{ tags: "focus border" value: 0xfda200ff } + theme_color:{ tags: cursor value: 0x8aff00ff } + theme_color:{ tags: selection value: 0x99ccff0f } + theme_color:{ tags: "inactive background" value: 0x0 } + theme_color:{ tags: drop_shadow value: 0x0000007f } + theme_color:{ tags: "good_pop background" value: 0x2c5b36ff } + theme_color:{ tags: "good_pop border" value: 0x568761ff } + theme_color:{ tags: "good_pop hover" value: 0xe3f5d3ff } + theme_color:{ tags: "good_pop weak text" value: 0xe3f5d3ff } + theme_color:{ tags: "bad_pop background" value: 0x803425ff } + theme_color:{ tags: "bad_pop hover" value: 0xff825cff } + theme_color:{ tags: code_default value: 0xad8b69ff } + theme_color:{ tags: code_symbol value: 0x87ad6aff } + theme_color:{ tags: code_type value: 0xb67474ff } + theme_color:{ tags: code_local value: 0xe9bf95ff } + theme_color:{ tags: code_register value: 0xa688b2ff } + theme_color:{ tags: code_keyword value: 0xe49e17ff } + theme_color:{ tags: code_delimiter_or_operator value: 0x795e43ff } + theme_color:{ tags: code_numeric value: 0x98b19eff } + theme_color:{ tags: code_numeric_alt_digit_group value: 0x688b71ff } + theme_color:{ tags: code_string value: 0x98b19eff } + theme_color:{ tags: code_meta value: 0xad5979ff } + theme_color:{ tags: code_comment value: 0x52675dff } + theme_color:{ tags: line_info_0 value: 0x4f3022ff } + theme_color:{ tags: line_info_1 value: 0x4f3e15ff } + theme_color:{ tags: line_info_2 value: 0x434e2aff } + theme_color:{ tags: line_info_3 value: 0x36241fff } + theme_color:{ tags: line_info_4 value: 0x4f3022ff } + theme_color:{ tags: line_info_5 value: 0x4f3e15ff } + theme_color:{ tags: line_info_6 value: 0x434e2aff } + theme_color:{ tags: line_info_7 value: 0x36241fff } + theme_color:{ tags: thread_0 value: 0xffc258ff } + theme_color:{ tags: thread_1 value: 0x82d331ff } + theme_color:{ tags: thread_2 value: 0xff99e5ff } + theme_color:{ tags: thread_3 value: 0x6598ffff } + theme_color:{ tags: thread_4 value: 0x65ffcbff } + theme_color:{ tags: thread_5 value: 0xff9819ff } + theme_color:{ tags: thread_6 value: 0x9932ffff } + theme_color:{ tags: thread_7 value: 0x65ff4cff } + theme_color:{ tags: thread_unwound value: 0xb2ccd8ff } + theme_color:{ tags: thread_error value: 0xb23219ff } + theme_color:{ tags: breakpoint value: 0xa72911ff } + theme_color:{ tags: "floating background" value: 0x1b1f2276 } + theme_color:{ tags: "floating background alt" value: 0x0000005f } + theme_color:{ tags: "floating background fresh" value: 0x31393d5f } + theme_color:{ tags: "floating border" value: 0xbfbfbf1f } + theme_color:{ tags: "floating scroll_bar background" value: 0x3b3b3b5f } + theme_color:{ tags: "floating scroll_bar border" value: 0x5f5f5f5f } + theme_color:{ tags: "menu_bar background" value: 0x243d32ff } + theme_color:{ tags: "menu_bar border" value: 0x597b63ff } + theme_color:{ tags: "scroll_bar background" value: 0x232929ff } + theme_color:{ tags: "scroll_bar border" value: 0x3c4a3fff } + theme_color:{ tags: "implicit background" value: 0x00000000 } + theme_color:{ tags: "implicit border" value: 0x00000000 } + theme_color:{ tags: "hollow background" value: 0x00000000 } + theme_color:{ tags: "hollow border" value: 0xffffff1f } + theme_color:{ tags: "tab background" value: 0x243d32ff } + theme_color:{ tags: "tab border" value: 0x597b63ff } + theme_color:{ tags: "tab inactive background" value: 0x30383eff } + theme_color:{ tags: "tab inactive border" value: 0x6b7680ff } + theme_color:{ tags: "tab auto background" value: 0x30636dff } + theme_color:{ tags: "tab auto border" value: 0x768f94ff } + theme_color:{ tags: "tab auto inactive background" value: 0x2f2633ff } + theme_color:{ tags: "tab auto inactive border" value: 0x685073ff } + theme_color:{ tags: "drop_site background" value: 0xffffff05 } + theme_color:{ tags: "drop_site border" value: 0xffffff0f } + } + ``` + } + + //- rjf: todo { FarManager far_manager "Far Manager" } } diff --git a/src/raddbg/raddbg_core.c b/src/raddbg/raddbg_core.c index c49e656d..a3276a60 100644 --- a/src/raddbg/raddbg_core.c +++ b/src/raddbg/raddbg_core.c @@ -5752,10 +5752,13 @@ rd_window_frame(void) //- rjf: @window_frame_part compute window's theme // { + HS_Scope *hs_scope = hs_scope_open(); + //- rjf: for this window, scan upwards, and then try the project, then the user, until we // find explicit preset / colors trees in the config. we will prefer the tightest ones, so // that windows can have their own colors, and have those override higher-up settings. RD_Cfg *preset_cfg = &rd_nil_cfg; + RD_Cfg *file_cfg = &rd_nil_cfg; RD_CfgList colors_cfgs = {0}; RD_Cfg *theme_parents[] = { @@ -5771,14 +5774,22 @@ rd_window_frame(void) for EachIndex(idx, theme_parents_count) { RD_Cfg *parent_cfg = theme_parents[idx]; - if(preset_cfg != &rd_nil_cfg) + if(preset_cfg == &rd_nil_cfg) { - RD_Cfg *possible_preset_cfg = rd_cfg_child_from_string(parent_cfg, str8_lit("color_preset")); + RD_Cfg *possible_preset_cfg = rd_cfg_child_from_string(parent_cfg, str8_lit("theme_preset")); if(possible_preset_cfg != &rd_nil_cfg) { preset_cfg = possible_preset_cfg; } } + if(file_cfg == &rd_nil_cfg) + { + RD_Cfg *possible_file_cfg = rd_cfg_child_from_string(parent_cfg, str8_lit("theme_file")); + if(possible_file_cfg != &rd_nil_cfg) + { + file_cfg = possible_file_cfg; + } + } for(RD_Cfg *child = parent_cfg->first; child != &rd_nil_cfg; child = child->next) { if(str8_match(child->string, str8_lit("theme_color"), 0)) @@ -5803,6 +5814,21 @@ rd_window_frame(void) } } + //- rjf: map the file config to the associated theme file parse + MD_Node *file_tree = &md_nil_node; + if(file_cfg != &rd_nil_cfg) + { + String8 path = file_cfg->first->string; + U64 endt_us = 0; + if(ws->frames_alive == 0) + { + endt_us = os_now_microseconds()+50000; + } + U128 hash = fs_hash_from_path_range(path, r1u64(0, max_U64), endt_us); + String8 data = hs_data_from_hash(hs_scope, hash); + file_tree = md_tree_from_string(scratch.arena, data); + } + //- rjf: build tasks for color applications - each task comprises of a metadesk // tree, describing the color patterns typedef struct ThemeTask ThemeTask; @@ -5811,7 +5837,7 @@ rd_window_frame(void) ThemeTask *next; MD_Node *tree; }; - ThemeTask start_task = {0, preset_tree}; + ThemeTask start_task = {0, !md_node_is_nil(file_tree) ? file_tree : preset_tree}; ThemeTask *first_task = &start_task; ThemeTask *last_task = first_task; { @@ -5867,6 +5893,8 @@ rd_window_frame(void) ws->theme->patterns[idx] = n->pattern; } } + + hs_scope_close(hs_scope); } ////////////////////////////// @@ -8852,6 +8880,7 @@ rd_window_frame(void) UI_TextAlignment(UI_TextAlign_Center) UI_PrefWidth(ui_px(tab_bar_vheight, 1.f)) UI_PrefHeight(ui_px(tab_bar_vheight, 1.f)) + UI_TagF(".") { ui_set_next_child_layout_axis(Axis2_Y); UI_Box *container = ui_build_box_from_stringf(!is_changing_panel_boundaries*UI_BoxFlag_AnimatePosX, "###add_new_tab"); @@ -9431,8 +9460,10 @@ rd_window_frame(void) // rjf: draw focus overlay if(b->flags & UI_BoxFlag_Clickable && !(b->flags & UI_BoxFlag_DisableFocusOverlay) && b->focus_hot_t > 0.01f) { - Vec4F32 color = ui_color_from_tags_key_name(box->tags_key, str8_lit("focus")); - color.w *= 0.09f*b->focus_hot_t; + String8 extras[] = {str8_lit("focus"), str8_lit("overlay")}; + String8Array extras_array = {extras, ArrayCount(extras)}; + Vec4F32 color = ui_color_from_tags_key_extras(b->tags_key, extras_array); + color.w *= b->focus_hot_t; R_Rect2DInst *inst = dr_rect(b->rect, color, 0, 0, 0.f); MemoryCopyArray(inst->corner_radii, b_corner_radii); } @@ -9446,7 +9477,9 @@ rd_window_frame(void) rect = pad_2f32(rect, 1.f); rect = intersect_2f32(window_rect, rect); } - Vec4F32 color = ui_color_from_tags_key_name(box->tags_key, str8_lit("focus")); + String8 extras[] = {str8_lit("focus"), str8_lit("border")}; + String8Array extras_array = {extras, ArrayCount(extras)}; + Vec4F32 color = ui_color_from_tags_key_extras(b->tags_key, extras_array); color.w *= b->focus_active_t; R_Rect2DInst *inst = dr_rect(rect, color, 0, 1.f, border_softness*1.f); MemoryCopyArray(inst->corner_radii, b_corner_radii); @@ -14628,10 +14661,10 @@ rd_frame(void) rd_cfg_release(n->v); } String8 color_preset = rd_setting_from_name(str8_lit("theme_preset")); - String8 color_file = rd_setting_from_name(str8_lit("theme_file")); RD_ThemePreset preset = RD_ThemePreset_DefaultDark; // TODO(rjf): map preset via string MD_Node *theme_tree = rd_state->theme_preset_trees[preset]; + String8 color_file = rd_setting_from_name(str8_lit("theme_file")); for(MD_Node *n = theme_tree; !md_node_is_nil(n); n = md_node_rec_depth_first_pre(n, theme_tree).next) { if(str8_match(n->string, str8_lit("theme_color"), 0)) diff --git a/src/raddbg/raddbg_views.c b/src/raddbg/raddbg_views.c index b2b35fdf..3f8192bf 100644 --- a/src/raddbg/raddbg_views.c +++ b/src/raddbg/raddbg_views.c @@ -1418,7 +1418,7 @@ rd_watch_row_info_from_row(Arena *arena, EV_Row *row) //////////////////////////// //- rjf: @watch_row_build_cells root-level type rows // - else if(row->eval.irtree.mode == E_Mode_Null && row->block->eval.irtree.mode != E_Mode_Null) + else if(row->eval.irtree.mode == E_Mode_Null && (e_type_key_match(row->block->eval.irtree.type_key, e_type_key_zero()) || row->block->eval.irtree.mode != E_Mode_Null)) { info.cell_style_key = str8_lit("root_type"); RD_Cfg *view = rd_cfg_from_id(rd_regs()->view); diff --git a/src/ui/ui_core.c b/src/ui/ui_core.c index dfc614e7..239ccdeb 100644 --- a/src/ui/ui_core.c +++ b/src/ui/ui_core.c @@ -2221,12 +2221,17 @@ ui_color_from_name(String8 name) } internal Vec4F32 -ui_color_from_tags_key_name(UI_Key key, String8 name) +ui_color_from_tags_key_extras(UI_Key key, String8Array extras) { Vec4F32 result = {0}; + if(ui_state->theme_pattern_cache_slots_count && extras.count > 0) { - //- rjf: compute final key, mixing (tags_key, name) - UI_Key final_key = ui_key_from_string(key, name); + //- rjf: compute final key, mixing (tags_key, extras) + UI_Key final_key = key; + for EachIndex(idx, extras.count) + { + final_key = ui_key_from_string(final_key, extras.v[idx]); + } //- rjf: map to existing node U64 slot_idx = final_key.u64[0]%ui_state->theme_pattern_cache_slots_count; @@ -2273,12 +2278,12 @@ ui_color_from_tags_key_name(UI_Key key, String8 name) for EachIndex(p_tags_idx, p->tags.count) { B32 p_tag_in_key = 0; - for EachIndex(key_tags_idx, tags.count+1) + for EachIndex(key_tags_idx, tags.count + extras.count) { - String8 key_string = key_tags_idx < tags.count ? tags.v[key_tags_idx] : name; + String8 key_string = key_tags_idx < tags.count ? tags.v[key_tags_idx] : extras.v[key_tags_idx - tags.count]; if(str8_match(p->tags.v[p_tags_idx], key_string, 0)) { - if(key_tags_idx == tags.count) + if(key_tags_idx == tags.count + extras.count - 1) { name_matches = 1; } @@ -2298,7 +2303,7 @@ ui_color_from_tags_key_name(UI_Key key, String8 name) pattern = p; best_match_count = match_count; } - if(match_count == tags.count+1) + if(match_count == tags.count + extras.count) { break; } @@ -2320,6 +2325,14 @@ ui_color_from_tags_key_name(UI_Key key, String8 name) return result; } +internal Vec4F32 +ui_color_from_tags_key_name(UI_Key key, String8 name) +{ + String8Array extras = {&name, 1}; + Vec4F32 result = ui_color_from_tags_key_extras(key, extras); + return result; +} + //- rjf: box node construction internal UI_Box * diff --git a/src/ui/ui_core.h b/src/ui/ui_core.h index d0461bf9..18d99706 100644 --- a/src/ui/ui_core.h +++ b/src/ui/ui_core.h @@ -908,6 +908,7 @@ internal UI_Key ui_top_tags_key(void); //- rjf: theme color lookups internal Vec4F32 ui_color_from_name(String8 name); +internal Vec4F32 ui_color_from_tags_key_extras(UI_Key key, String8Array extras); internal Vec4F32 ui_color_from_tags_key_name(UI_Key key, String8 name); //- rjf: box node construction