mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-06-13 07:32:23 -07:00
begin fitting settings into window evaluation
This commit is contained in:
+33
-17
@@ -108,7 +108,8 @@ void optimized_struct_parameters_eval_tests(void);
|
||||
|
||||
raddbg_auto_view_rule(std::vector<?>, slice(_Mypair._Myval2));
|
||||
|
||||
struct Basics{
|
||||
struct Basics
|
||||
{
|
||||
char a;
|
||||
unsigned char b;
|
||||
short c;
|
||||
@@ -119,11 +120,11 @@ struct Basics{
|
||||
unsigned long long h;
|
||||
float i;
|
||||
double j;
|
||||
|
||||
int z;
|
||||
};
|
||||
|
||||
struct Basics_Stdint{
|
||||
struct Basics_Stdint
|
||||
{
|
||||
int8_t a;
|
||||
uint8_t b;
|
||||
int16_t c;
|
||||
@@ -136,23 +137,27 @@ struct Basics_Stdint{
|
||||
double j;
|
||||
};
|
||||
|
||||
struct Pair{
|
||||
struct Pair
|
||||
{
|
||||
int x;
|
||||
float y;
|
||||
};
|
||||
|
||||
struct Fixed_Array{
|
||||
struct Fixed_Array
|
||||
{
|
||||
Pair pairs[10];
|
||||
int count;
|
||||
};
|
||||
|
||||
struct Dynamic_Array{
|
||||
struct Dynamic_Array
|
||||
{
|
||||
Pair *pairs;
|
||||
int count;
|
||||
};
|
||||
raddbg_auto_view_rule(Dynamic_Array, slice($));
|
||||
|
||||
struct Struct_With_Embedded_Arrays{
|
||||
struct Struct_With_Embedded_Arrays
|
||||
{
|
||||
int x;
|
||||
float y;
|
||||
Pair pairs[10];
|
||||
@@ -173,13 +178,16 @@ struct Callback{
|
||||
Pair pair;
|
||||
};
|
||||
|
||||
union Vector_R2{
|
||||
struct{
|
||||
union Vector_R2
|
||||
{
|
||||
struct
|
||||
{
|
||||
float x;
|
||||
float y;
|
||||
};
|
||||
float v[2];
|
||||
};
|
||||
raddbg_auto_view_rule(Vector_R2, only($, x, y));
|
||||
|
||||
typedef union Matrix4x4F32 Matrix4x4F32;
|
||||
union Matrix4x4F32
|
||||
@@ -188,7 +196,8 @@ union Matrix4x4F32
|
||||
};
|
||||
raddbg_auto_view_rule(Matrix4x4F32, table($.elements, $[0], $[1], $[2], $[3]));
|
||||
|
||||
enum Kind{
|
||||
enum Kind
|
||||
{
|
||||
Kind_None,
|
||||
Kind_First,
|
||||
Kind_Second,
|
||||
@@ -197,7 +206,8 @@ enum Kind{
|
||||
Kind_COUNT,
|
||||
};
|
||||
|
||||
enum Flag{
|
||||
enum Flag
|
||||
{
|
||||
Flag_None = 0,
|
||||
Flag_First = 1,
|
||||
Flag_Second = 2,
|
||||
@@ -208,25 +218,31 @@ enum Flag{
|
||||
Flag_All = 0xFFFFFFFF,
|
||||
};
|
||||
|
||||
struct Has_Enums{
|
||||
struct Has_Enums
|
||||
{
|
||||
Kind kind;
|
||||
Flag flags;
|
||||
};
|
||||
|
||||
struct Discriminated_Union{
|
||||
struct Discriminated_Union
|
||||
{
|
||||
Kind kind;
|
||||
union{
|
||||
struct{
|
||||
union
|
||||
{
|
||||
struct
|
||||
{
|
||||
int x;
|
||||
int y;
|
||||
Vector_R2 vector;
|
||||
} first;
|
||||
Pair second;
|
||||
struct{
|
||||
struct
|
||||
{
|
||||
Function_Few_Params_Type *few_params;
|
||||
Pair pairs[4];
|
||||
} third;
|
||||
struct{
|
||||
struct
|
||||
{
|
||||
Kind sub_kind;
|
||||
Flag flags;
|
||||
} fourth;
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
//- GENERATED CODE
|
||||
|
||||
C_LINKAGE_BEGIN
|
||||
RD_VocabInfo rd_vocab_info_table[315] =
|
||||
RD_VocabInfo rd_vocab_info_table[319] =
|
||||
{
|
||||
{str8_lit_comp("auto_view_rule"), str8_lit_comp("auto_view_rules"), str8_lit_comp("Auto View Rule"), str8_lit_comp("Auto View Rules"), RD_IconKind_Binoculars},
|
||||
{str8_lit_comp("file_path_map"), str8_lit_comp("file_path_maps"), str8_lit_comp("File Path Map"), str8_lit_comp("File Path Maps"), RD_IconKind_FileOutline},
|
||||
@@ -108,6 +108,10 @@ RD_VocabInfo rd_vocab_info_table[315] =
|
||||
{str8_lit_comp("pitch"), str8_lit_comp(""), str8_lit_comp("Pitch"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("zoom"), str8_lit_comp(""), str8_lit_comp("Zoom"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("font_size"), str8_lit_comp(""), str8_lit_comp("Font Size"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("smooth_ui_text"), str8_lit_comp(""), str8_lit_comp("Smooth UI Text"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("smooth_code_text"), str8_lit_comp(""), str8_lit_comp("Smooth Code Text"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("hint_ui_text"), str8_lit_comp(""), str8_lit_comp("Hint UI Text"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("hint_code_text"), str8_lit_comp(""), str8_lit_comp("Hint Code Text"), str8_lit_comp(""), RD_IconKind_Null},
|
||||
{str8_lit_comp("launch_and_run"), str8_lit_comp(""), str8_lit_comp("Launch and Run"), str8_lit_comp(""), RD_IconKind_Play},
|
||||
{str8_lit_comp("launch_and_step_into"), str8_lit_comp(""), str8_lit_comp("Launch and Step Into"), str8_lit_comp(""), RD_IconKind_PlayStepForward},
|
||||
{str8_lit_comp("kill"), str8_lit_comp(""), str8_lit_comp("Kill"), str8_lit_comp(""), RD_IconKind_X},
|
||||
@@ -325,8 +329,8 @@ RD_VocabInfo rd_vocab_info_table[315] =
|
||||
|
||||
RD_NameSchemaInfo rd_name_schema_info_table[19] =
|
||||
{
|
||||
{str8_lit_comp("settings"), str8_lit_comp("x:\n{\n @default(1) 'hover_animations': bool,\n @default(1) 'press_animations': bool,\n @default(0) 'focus_animations': bool,\n @default(1) 'tooltip_animations': bool,\n @default(1) 'menu_animations': bool,\n @default(1) 'scrolling_animations': bool,\n @default(1) 'background_blur': bool,\n @default(1) 'thread_lines': bool,\n @default(1) 'breakpoint_lines': bool,\n @default(1) 'thread_glow': bool,\n @default(1) 'breakpoint_glow': bool,\n @default(0) 'opaque_backgrounds': bool,\n @default(1) 'smooth_main_text': bool,\n @default(0) 'smooth_code_text': bool,\n @default(1) 'hint_main_text': bool,\n @default(1) 'hint_code_text': bool,\n @default(2) 'tab_width': @range[1, 32] u64,\n @default(11) 'font_size': @range[6, 72] u64,\n}\n")},
|
||||
{str8_lit_comp("window"), str8_lit_comp("x:\n{\n @default(11) 'font_size': @range[6, 72] u64,\n}\n")},
|
||||
{str8_lit_comp("settings"), str8_lit_comp("x:\n{\n @default(1) 'hover_animations': bool,\n @default(1) 'press_animations': bool,\n @default(0) 'focus_animations': bool,\n @default(1) 'tooltip_animations': bool,\n @default(1) 'menu_animations': bool,\n @default(1) 'scrolling_animations': bool,\n @default(1) 'background_blur': bool,\n @default(1) 'thread_lines': bool,\n @default(1) 'breakpoint_lines': bool,\n @default(1) 'thread_glow': bool,\n @default(1) 'breakpoint_glow': bool,\n @default(0) 'opaque_backgrounds': bool,\n @default(1) 'smooth_ui_text': bool,\n @default(0) 'smooth_code_text': bool,\n @default(1) 'hint_ui_text': bool,\n @default(1) 'hint_code_text': bool,\n @default(2) 'tab_width': @range[1, 32] u64,\n @default(11) 'font_size': @range[6, 72] u64,\n}\n")},
|
||||
{str8_lit_comp("window"), str8_lit_comp("x:\n{\n //- rjf: animations\n @default(1) 'hover_animations': bool,\n @default(1) 'press_animations': bool,\n @default(0) 'focus_animations': bool,\n @default(1) 'tooltip_animations': bool,\n @default(1) 'menu_animations': bool,\n @default(1) 'scrolling_animations': bool,\n\n //- rjf: thread & breakpoint decorations\n @default(1) 'thread_lines': bool,\n @default(1) 'thread_glow': bool,\n @default(1) 'breakpoint_lines': bool,\n @default(1) 'breakpoint_glow': bool,\n\n //- rjf: occluding background settings\n @default(0) 'opaque_backgrounds': bool,\n @default(1) 'background_blur': bool,\n\n //- rjf: text rasterization settings\n @default(1) 'smooth_ui_text': bool,\n @default(1) 'hint_ui_text': bool,\n @default(0) 'smooth_code_text': bool,\n @default(1) 'hint_code_text': bool,\n @default(11) 'font_size': @range[6, 72] u64,\n}\n")},
|
||||
{str8_lit_comp("tab"), str8_lit_comp("x:\n{\n @default(11) 'font_size': @range[6, 72] u64,\n}\n")},
|
||||
{str8_lit_comp("text"), str8_lit_comp("@inherit(tab) x:\n{\n 'lang':lang,\n 'size':code_string,\n @default(1) 'show_line_numbers':bool,\n}\n")},
|
||||
{str8_lit_comp("disasm"), str8_lit_comp("@inherit(tab) x:\n{\n 'arch': arch,\n 'syntax': dasm_syntax,\n 'size': code_string,\n @default(1) 'show_addresses': bool,\n @default(0) 'show_code_bytes': bool,\n @default(1) 'show_source_lines': bool,\n @default(1) 'show_symbol_names': bool,\n @default(1) 'show_line_numbers': bool,\n}\n")},
|
||||
|
||||
@@ -637,7 +637,7 @@ RD_Query query;
|
||||
.os_event = rd_regs()->os_event,\
|
||||
|
||||
C_LINKAGE_BEGIN
|
||||
extern RD_VocabInfo rd_vocab_info_table[315];
|
||||
extern RD_VocabInfo rd_vocab_info_table[319];
|
||||
extern RD_NameSchemaInfo rd_name_schema_info_table[19];
|
||||
extern Rng1U64 rd_reg_slot_range_table[40];
|
||||
extern String8 rd_binding_version_remap_old_name_table[8];
|
||||
|
||||
+29
-2
@@ -121,6 +121,10 @@ RD_VocabTable:
|
||||
{pitch "" "Pitch" "" Null }
|
||||
{zoom "" "Zoom" "" Null }
|
||||
{font_size "" "Font Size" "" Null }
|
||||
{smooth_ui_text "" "Smooth UI Text" "" Null }
|
||||
{smooth_code_text "" "Smooth Code Text" "" Null }
|
||||
{hint_ui_text "" "Hint UI Text" "" Null }
|
||||
{hint_code_text "" "Hint Code Text" "" Null }
|
||||
}
|
||||
|
||||
@struct RD_VocabInfo:
|
||||
@@ -161,9 +165,9 @@ RD_VocabTable:
|
||||
@default(1) 'thread_glow': bool,
|
||||
@default(1) 'breakpoint_glow': bool,
|
||||
@default(0) 'opaque_backgrounds': bool,
|
||||
@default(1) 'smooth_main_text': bool,
|
||||
@default(1) 'smooth_ui_text': bool,
|
||||
@default(0) 'smooth_code_text': bool,
|
||||
@default(1) 'hint_main_text': bool,
|
||||
@default(1) 'hint_ui_text': bool,
|
||||
@default(1) 'hint_code_text': bool,
|
||||
@default(2) 'tab_width': @range[1, 32] u64,
|
||||
@default(11) 'font_size': @range[6, 72] u64,
|
||||
@@ -177,6 +181,29 @@ RD_VocabTable:
|
||||
```
|
||||
x:
|
||||
{
|
||||
//- rjf: animations
|
||||
@default(1) 'hover_animations': bool,
|
||||
@default(1) 'press_animations': bool,
|
||||
@default(0) 'focus_animations': bool,
|
||||
@default(1) 'tooltip_animations': bool,
|
||||
@default(1) 'menu_animations': bool,
|
||||
@default(1) 'scrolling_animations': bool,
|
||||
|
||||
//- rjf: thread & breakpoint decorations
|
||||
@default(1) 'thread_lines': bool,
|
||||
@default(1) 'thread_glow': bool,
|
||||
@default(1) 'breakpoint_lines': bool,
|
||||
@default(1) 'breakpoint_glow': bool,
|
||||
|
||||
//- rjf: occluding background settings
|
||||
@default(0) 'opaque_backgrounds': bool,
|
||||
@default(1) 'background_blur': bool,
|
||||
|
||||
//- rjf: text rasterization settings
|
||||
@default(1) 'smooth_ui_text': bool,
|
||||
@default(1) 'hint_ui_text': bool,
|
||||
@default(0) 'smooth_code_text': bool,
|
||||
@default(1) 'hint_code_text': bool,
|
||||
@default(11) 'font_size': @range[6, 72] u64,
|
||||
}
|
||||
```
|
||||
|
||||
@@ -5507,8 +5507,8 @@ rd_window_frame(void)
|
||||
ui_push_pref_height(ui_px(floor_f32(ui_top_font_size()*3.f), 1.f));
|
||||
ui_push_blur_size(10.f);
|
||||
FNT_RasterFlags text_raster_flags = 0;
|
||||
if(rd_setting_b32_from_name(str8_lit("smooth_main_text"))) {text_raster_flags |= FNT_RasterFlag_Smooth;}
|
||||
if(rd_setting_b32_from_name(str8_lit("hint_main_text"))) {text_raster_flags |= FNT_RasterFlag_Hinted;}
|
||||
if(rd_setting_b32_from_name(str8_lit("smooth_ui_text"))) {text_raster_flags |= FNT_RasterFlag_Smooth;}
|
||||
if(rd_setting_b32_from_name(str8_lit("hint_ui_text"))) {text_raster_flags |= FNT_RasterFlag_Hinted;}
|
||||
ui_push_text_raster_flags(text_raster_flags);
|
||||
}
|
||||
|
||||
@@ -10452,7 +10452,7 @@ rd_raster_flags_from_slot(RD_FontSlot slot)
|
||||
{
|
||||
default:{}break;
|
||||
case RD_FontSlot_Icons:{flags = FNT_RasterFlag_Smooth;}break;
|
||||
case RD_FontSlot_Main: {flags = (rd_setting_b32_from_name(str8_lit("smooth_main_text"))*FNT_RasterFlag_Smooth)|(rd_setting_b32_from_name(str8_lit("hint_main_text"))*FNT_RasterFlag_Hinted);}break;
|
||||
case RD_FontSlot_Main: {flags = (rd_setting_b32_from_name(str8_lit("smooth_ui_text"))*FNT_RasterFlag_Smooth)|(rd_setting_b32_from_name(str8_lit("hint_ui_text"))*FNT_RasterFlag_Hinted);}break;
|
||||
case RD_FontSlot_Code: {flags = (rd_setting_b32_from_name(str8_lit("smooth_code_text"))*FNT_RasterFlag_Smooth)|(rd_setting_b32_from_name(str8_lit("hint_code_text"))*FNT_RasterFlag_Hinted);}break;
|
||||
}
|
||||
return flags;
|
||||
|
||||
Reference in New Issue
Block a user