mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-08-07 22:38:41 +00:00
fix zero-sized content rect busting panel rectangles
This commit is contained in:
@@ -7462,6 +7462,8 @@ ws->cfg_palettes[RD_PaletteCode_##name].selection = current->colors[RD_The
|
|||||||
////////////////////////////
|
////////////////////////////
|
||||||
//- rjf: panel leaf UI
|
//- rjf: panel leaf UI
|
||||||
//
|
//
|
||||||
|
if(content_rect.x1 > content_rect.x0 && content_rect.y1 > content_rect.y0)
|
||||||
|
{
|
||||||
ProfScope("leaf panel UI")
|
ProfScope("leaf panel UI")
|
||||||
for(RD_PanelNode *panel = panel_tree.root;
|
for(RD_PanelNode *panel = panel_tree.root;
|
||||||
panel != &rd_nil_panel_node;
|
panel != &rd_nil_panel_node;
|
||||||
@@ -8301,6 +8303,7 @@ ws->cfg_palettes[RD_PaletteCode_##name].selection = current->colors[RD_The
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
////////////////////////////
|
////////////////////////////
|
||||||
//- rjf: drag/drop cancelling
|
//- rjf: drag/drop cancelling
|
||||||
@@ -10794,14 +10797,12 @@ rd_title_fstrs_from_code_name(Arena *arena, String8 code_name)
|
|||||||
// more faded/smaller, but only after a primary title is pushed,
|
// more faded/smaller, but only after a primary title is pushed,
|
||||||
// which could be caused by many different potential parts of a cfg.
|
// which could be caused by many different potential parts of a cfg.
|
||||||
//
|
//
|
||||||
DR_FStrParams params = {rd_font_from_slot(RD_FontSlot_Main), rd_raster_flags_from_slot(RD_FontSlot_Main), ui_top_palette()->text, ui_top_font_size()};
|
DR_FStrParams params = {rd_font_from_slot(RD_FontSlot_Main), rd_raster_flags_from_slot(RD_FontSlot_Main), ui_color_from_name(str8_lit("text")), ui_top_font_size()};
|
||||||
B32 running_is_secondary = 0;
|
|
||||||
#define start_secondary() if(!running_is_secondary){running_is_secondary = 1; params.color = secondary_color; params.size = ui_top_font_size()*0.95f;}
|
|
||||||
|
|
||||||
//- rjf: push icon
|
//- rjf: push icon
|
||||||
if(info->icon_kind != RD_IconKind_Null)
|
if(info->icon_kind != RD_IconKind_Null) UI_Tag(str8_lit("weak"))
|
||||||
{
|
{
|
||||||
dr_fstrs_push_new(arena, &result, ¶ms, rd_icon_kind_text_table[info->icon_kind], .font = rd_font_from_slot(RD_FontSlot_Icons), .raster_flags = rd_raster_flags_from_slot(RD_FontSlot_Icons), .color = ui_top_palette()->text_weak);
|
dr_fstrs_push_new(arena, &result, ¶ms, rd_icon_kind_text_table[info->icon_kind], .font = rd_font_from_slot(RD_FontSlot_Icons), .raster_flags = rd_raster_flags_from_slot(RD_FontSlot_Icons), .color = ui_color_from_name(str8_lit("text")));
|
||||||
dr_fstrs_push_new(arena, &result, ¶ms, str8_lit(" "));
|
dr_fstrs_push_new(arena, &result, ¶ms, str8_lit(" "));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -10816,8 +10817,6 @@ rd_title_fstrs_from_code_name(Arena *arena, String8 code_name)
|
|||||||
{
|
{
|
||||||
dr_fstrs_push_new(arena, &result, ¶ms, code_name, .font = rd_font_from_slot(RD_FontSlot_Code), .raster_flags = rd_raster_flags_from_slot(RD_FontSlot_Code));
|
dr_fstrs_push_new(arena, &result, ¶ms, code_name, .font = rd_font_from_slot(RD_FontSlot_Code), .raster_flags = rd_raster_flags_from_slot(RD_FontSlot_Code));
|
||||||
}
|
}
|
||||||
|
|
||||||
#undef start_secondary
|
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user