mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-09-22 17:20:05 +00:00
Compare commits
49
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
aa31afcd24 | ||
|
|
49f7fa9fa3 | ||
|
|
9b8c0e32b5 | ||
|
|
2518eaf57c | ||
|
|
d2bdf512cf | ||
|
|
0ce5239404 | ||
|
|
83e8bb8ddd | ||
|
|
afe105da31 | ||
|
|
f6e7db7c3a | ||
|
|
d1fde3c908 | ||
|
|
baca24c037 | ||
|
|
57fb21adf7 | ||
|
|
3fd9014c20 | ||
|
|
1ade5e44fa | ||
|
|
28e258b5dc | ||
|
|
967936cef6 | ||
|
|
04b5b362bc | ||
|
|
f047a0beac | ||
|
|
7355389e19 | ||
|
|
5f8ec62b4c | ||
|
|
207e46c8e8 | ||
|
|
b76a8b9854 | ||
|
|
6b7588b4b3 | ||
|
|
455dac958c | ||
|
|
0974337450 | ||
|
|
fea74aedd8 | ||
|
|
89af8124c7 | ||
|
|
33f5d4f5b1 | ||
|
|
88a218e36e | ||
|
|
f69176ee4e | ||
|
|
8c0708d2ab | ||
|
|
21deaace66 | ||
|
|
3aa602eca7 | ||
|
|
1319a23f98 | ||
|
|
c8c5da4f4a | ||
|
|
dd38822a4c | ||
|
|
644a94d5ef | ||
|
|
fc9449a2d5 | ||
|
|
168f66cc99 | ||
|
|
38b113f1d0 | ||
|
|
b14b9f0344 | ||
|
|
d0c3d9dc21 | ||
|
|
76b2facbf4 | ||
|
|
813554fa62 | ||
|
|
7cf0854178 | ||
|
|
ed7d31d7ea | ||
|
|
66b56789c6 | ||
|
|
96b0dd0783 | ||
|
|
2dbcc26cdb |
@@ -20,9 +20,9 @@ jobs:
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
|
||||
call build raddbg msvc debug
|
||||
call build raddbg_from_pdb msvc debug
|
||||
call build raddbg_from_dwarf msvc debug
|
||||
call build raddbg clang debug
|
||||
call build raddbg_from_pdb clang debug
|
||||
call build raddbg_from_dwarf clang debug
|
||||
call build raddbg msvc debug || exit /b 1
|
||||
call build raddbg_from_pdb msvc debug || exit /b 1
|
||||
call build raddbg_from_dwarf msvc debug || exit /b 1
|
||||
call build raddbg clang debug || exit /b 1
|
||||
call build raddbg_from_pdb clang debug || exit /b 1
|
||||
call build raddbg_from_dwarf clang debug || exit /b 1
|
||||
|
||||
@@ -60,6 +60,8 @@ if "%msvc%"=="1" set only_compile=/c
|
||||
if "%clang%"=="1" set only_compile=-c
|
||||
if "%msvc%"=="1" set EHsc=/EHsc
|
||||
if "%clang%"=="1" set EHsc=
|
||||
if "%msvc%"=="1" set rc=rc.exe
|
||||
if "%clang%"=="1" set rc=llvm-rc.exe
|
||||
|
||||
:: --- Choose Compile/Link Lines ----------------------------------------------
|
||||
if "%msvc%"=="1" set compile_debug=%cl_debug%
|
||||
@@ -79,7 +81,7 @@ if not exist local mkdir local
|
||||
|
||||
:: --- Produce Logo Icon File -------------------------------------------------
|
||||
pushd build
|
||||
rc /nologo /fo logo.res ..\data\logo.rc
|
||||
%rc% /nologo /fo logo.res ..\data\logo.rc || exit /b 1
|
||||
popd
|
||||
|
||||
:: --- Build & Run Metaprogram ------------------------------------------------
|
||||
@@ -100,7 +102,7 @@ if "%raddbg_dump%"=="1" %compile% ..\src\raddbg_dump\raddbg_d
|
||||
if "%ryan_scratch%"=="1" %compile% ..\src\scratch\ryan_scratch.c %compile_link% %out%ryan_scratch.exe || exit /b 1
|
||||
if "%cpp_tests%"=="1" %compile% ..\src\scratch\i_hate_c_plus_plus.cpp %compile_link% %out%cpp_tests.exe || exit /b 1
|
||||
if "%look_at_raddbg%"=="1" %compile% ..\src\scratch\look_at_raddbg.c %compile_link% %out%look_at_raddbg.exe || exit /b 1
|
||||
if "%mule_main%"=="1" del vc*.pdb mule*.pdb && %compile_release% %only_compile% ..\src\mule\mule_inline.cpp && %compile_release% %only_compile% ..\src\mule\mule_o2.cpp && %compile_debug% %EHsc% ..\src\mule\mule_main.cpp ..\src\mule\mule_c.c mule_inline.obj mule_o2.obj || exit /b 1
|
||||
if "%mule_main%"=="1" del vc*.pdb mule*.pdb && %compile_release% %only_compile% ..\src\mule\mule_inline.cpp && %compile_release% %only_compile% ..\src\mule\mule_o2.cpp && %compile_debug% %EHsc% ..\src\mule\mule_main.cpp ..\src\mule\mule_c.c mule_inline.obj mule_o2.obj %compile_link% %out%mule_main.exe || exit /b 1
|
||||
if "%mule_module%"=="1" %compile% ..\src\mule\mule_module.cpp %compile_link% %link_dll% %out%mule_module.dll || exit /b 1
|
||||
if "%mule_hotload%"=="1" %compile% ..\src\mule\mule_hotload_main.c %compile_link% %out%mule_hotload.exe & %compile% ..\src\mule\mule_hotload_module_main.c %compile_link% %link_dll% %out%mule_hotload_module.dll || exit /b 1
|
||||
popd
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 7.5 KiB After Width: | Height: | Size: 7.5 KiB |
+1
-1
@@ -65,7 +65,7 @@ commands =
|
||||
},
|
||||
.rjf_f3 =
|
||||
{
|
||||
.win = "pushd build && raddbg.exe && popd",
|
||||
.win = "pushd build && raddbg.exe --user:local_dev.raddbg_user --profile:local_dev.raddbg_profile && popd",
|
||||
.linux = "",
|
||||
.out = "*compilation*",
|
||||
.footer_panel = true,
|
||||
|
||||
@@ -141,6 +141,15 @@ make_translate_3x3f32(Vec2F32 delta)
|
||||
return mat;
|
||||
}
|
||||
|
||||
internal Mat3x3F32
|
||||
make_scale_3x3f32(Vec2F32 scale)
|
||||
{
|
||||
Mat3x3F32 mat = mat_3x3f32(1.f);
|
||||
mat.v[0][0] = scale.x;
|
||||
mat.v[1][1] = scale.y;
|
||||
return mat;
|
||||
}
|
||||
|
||||
internal Mat3x3F32
|
||||
mul_3x3f32(Mat3x3F32 a, Mat3x3F32 b)
|
||||
{
|
||||
|
||||
@@ -507,6 +507,7 @@ internal Vec4S32 mix_4s32(Vec4S32 a, Vec4S32 b, F32 t);
|
||||
|
||||
internal Mat3x3F32 mat_3x3f32(F32 diagonal);
|
||||
internal Mat3x3F32 make_translate_3x3f32(Vec2F32 delta);
|
||||
internal Mat3x3F32 make_scale_3x3f32(Vec2F32 scale);
|
||||
internal Mat3x3F32 mul_3x3f32(Mat3x3F32 a, Mat3x3F32 b);
|
||||
|
||||
internal Mat4x4F32 mat_4x4f32(F32 diagonal);
|
||||
|
||||
@@ -1341,7 +1341,7 @@ utf16_decode(U16 *str, U64 max){
|
||||
result.codepoint = str[0];
|
||||
result.inc = 1;
|
||||
if (max > 1 && 0xD800 <= str[0] && str[0] < 0xDC00 && 0xDC00 <= str[1] && str[1] < 0xE000){
|
||||
result.codepoint = ((str[0] - 0xD800) << 10) | (str[1] - 0xDC00);
|
||||
result.codepoint = ((str[0] - 0xD800) << 10) | (str[1] - 0xDC00) + 0x10000;
|
||||
result.inc = 2;
|
||||
}
|
||||
return(result);
|
||||
|
||||
+309
-285
@@ -754,189 +754,12 @@ ctrl_process_read(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range,
|
||||
return actual_bytes_read;
|
||||
}
|
||||
|
||||
internal String8
|
||||
ctrl_query_cached_data_from_process_vaddr_range(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range)
|
||||
{
|
||||
String8 result = {0};
|
||||
if(range.max > range.min &&
|
||||
dim_1u64(range) <= MB(256) &&
|
||||
range.min <= 0x000FFFFFFFFFFFFFull &&
|
||||
range.max <= 0x000FFFFFFFFFFFFFull)
|
||||
{
|
||||
HS_Scope *scope = hs_scope_open();
|
||||
CTRL_ProcessMemoryCache *cache = &ctrl_state->process_memory_cache;
|
||||
|
||||
//- rjf: unpack address range
|
||||
Rng1U64 page_range = r1u64(AlignDownPow2(range.min, KB(4)), AlignPow2(range.max, KB(4)));
|
||||
|
||||
//- rjf: setup output memory for read
|
||||
void *read_out = push_array(arena, U8, dim_1u64(page_range));
|
||||
|
||||
//- rjf: unpack process/machine params
|
||||
U64 hash = ctrl_hash_from_string(str8_struct(&process));
|
||||
U64 slot_idx = hash%cache->slots_count;
|
||||
U64 stripe_idx = slot_idx%cache->stripes_count;
|
||||
CTRL_ProcessMemoryCacheSlot *slot = &cache->slots[slot_idx];
|
||||
CTRL_ProcessMemoryCacheStripe *stripe = &cache->stripes[stripe_idx];
|
||||
|
||||
//- rjf: cache lookup & fill loop
|
||||
for(U64 page_vaddr = page_range.min; page_vaddr < page_range.max; page_vaddr += KB(4))
|
||||
{
|
||||
// rjf: unpack page base address
|
||||
U64 lvl5_idx = (page_vaddr&0x00000000000FF000ull) >> 12;
|
||||
U64 lvl4_idx = (page_vaddr&0x000000000FF00000ull) >> 20;
|
||||
U64 lvl3_idx = (page_vaddr&0x0000000FF0000000ull) >> 28;
|
||||
U64 lvl2_idx = (page_vaddr&0x00000FF000000000ull) >> 36;
|
||||
U64 lvl1_idx = (page_vaddr&0x000FF00000000000ull) >> 44;
|
||||
|
||||
// rjf: try to find node & read from it
|
||||
B32 node_found = 0;
|
||||
B32 page_found = 0;
|
||||
B32 page_stale = 0;
|
||||
OS_MutexScopeR(stripe->rw_mutex)
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode *node = 0;
|
||||
for(CTRL_ProcessMemoryCacheNode *n = slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(ctrl_handle_match(process, n->process) && n->machine_id == machine_id)
|
||||
{
|
||||
node = n;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(node != 0)
|
||||
{
|
||||
node_found = 1;
|
||||
CTRL_ProcessMemoryCacheNode1 *node1 = node->children[lvl1_idx];
|
||||
CTRL_ProcessMemoryCacheNode2 *node2 = node1 ? node1->children[lvl2_idx] : 0;
|
||||
CTRL_ProcessMemoryCacheNode3 *node3 = node2 ? node2->children[lvl3_idx] : 0;
|
||||
CTRL_ProcessMemoryCacheNode4 *node4 = node3 ? node3->children[lvl4_idx] : 0;
|
||||
U128 page_hash = node4 ? node4->page_hashes[lvl5_idx] : u128_zero();
|
||||
B32 stale = (node4 && node4->page_memgen_idxs[lvl5_idx] < ctrl_memgen_idx());
|
||||
if(!u128_match(page_hash, u128_zero()))
|
||||
{
|
||||
page_stale = stale;
|
||||
String8 page_data = hs_data_from_hash(scope, page_hash);
|
||||
if(page_data.size >= KB(4))
|
||||
{
|
||||
page_found = 1;
|
||||
MemoryCopy((U8*)read_out + (page_vaddr-page_range.min), page_data.str, KB(4));
|
||||
}
|
||||
else
|
||||
{
|
||||
page_stale = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: either node or page not found? -> need a hard-lock & fill
|
||||
if(!node_found || !page_found || page_stale) OS_MutexScopeW(stripe->rw_mutex)
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode *node = 0;
|
||||
for(CTRL_ProcessMemoryCacheNode *n = slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(ctrl_handle_match(process, n->process) && n->machine_id == machine_id)
|
||||
{
|
||||
node = n;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(node == 0)
|
||||
{
|
||||
Arena *node_arena = arena_alloc();
|
||||
node = push_array(node_arena, CTRL_ProcessMemoryCacheNode, 1);
|
||||
node->arena = node_arena;
|
||||
node->machine_id = machine_id;
|
||||
node->process = process;
|
||||
node->range_hash_slots_count = 1024;
|
||||
node->range_hash_slots = push_array(node_arena, CTRL_ProcessMemoryRangeHashSlot, node->range_hash_slots_count);
|
||||
DLLPushBack(slot->first, slot->last, node);
|
||||
}
|
||||
if(!page_found || page_stale)
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode1 *node1 = node->children[lvl1_idx];
|
||||
if(node1 == 0)
|
||||
{
|
||||
node1 = push_array(node->arena, CTRL_ProcessMemoryCacheNode1, 1);
|
||||
node->children[lvl1_idx] = node1;
|
||||
}
|
||||
CTRL_ProcessMemoryCacheNode2 *node2 = node1->children[lvl2_idx];
|
||||
if(node2 == 0)
|
||||
{
|
||||
node2 = push_array(node->arena, CTRL_ProcessMemoryCacheNode2, 1);
|
||||
node1->children[lvl2_idx] = node2;
|
||||
}
|
||||
CTRL_ProcessMemoryCacheNode3 *node3 = node2->children[lvl3_idx];
|
||||
if(node3 == 0)
|
||||
{
|
||||
node3 = push_array(node->arena, CTRL_ProcessMemoryCacheNode3, 1);
|
||||
node2->children[lvl3_idx] = node3;
|
||||
}
|
||||
CTRL_ProcessMemoryCacheNode4 *node4 = node3->children[lvl4_idx];
|
||||
if(node4 == 0)
|
||||
{
|
||||
node4 = push_array(node->arena, CTRL_ProcessMemoryCacheNode4, 1);
|
||||
node3->children[lvl4_idx] = node4;
|
||||
}
|
||||
Arena *page_arena = arena_alloc__sized(KB(8), KB(8));
|
||||
void *page_base = push_array_no_zero(page_arena, U8, KB(4));
|
||||
U64 actual_read_size = ctrl_process_read(machine_id, process, r1u64(page_vaddr, page_vaddr+KB(4)), page_base);
|
||||
if(actual_read_size >= KB(4))
|
||||
{
|
||||
node4->page_memgen_idxs[lvl5_idx] = ctrl_memgen_idx();
|
||||
if(page_stale)
|
||||
{
|
||||
MemoryCopy((U8*)read_out + (page_vaddr-page_range.min), page_base, KB(4));
|
||||
}
|
||||
U64 page_key_data[] =
|
||||
{
|
||||
(U64)machine_id,
|
||||
(U64)process.u64[0],
|
||||
page_vaddr,
|
||||
page_vaddr+KB(4),
|
||||
};
|
||||
U128 page_key = hs_hash_from_data(str8((U8 *)page_key_data, sizeof(page_key_data)));
|
||||
U128 page_hash = hs_submit_data(page_key, &page_arena, str8((U8 *)page_base, KB(4)));
|
||||
node4->page_hashes[lvl5_idx] = page_hash;
|
||||
}
|
||||
else
|
||||
{
|
||||
arena_release(page_arena);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//- rjf: fill result by skipping/chopping read memory
|
||||
U64 byte_in_page_idx = (range.min&0x0000000000000FFFull) >> 0;
|
||||
result.str = (U8*)read_out + byte_in_page_idx;
|
||||
result.size = dim_1u64(range);
|
||||
hs_scope_close(scope);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
internal String8
|
||||
ctrl_query_cached_zero_terminated_data_from_process_vaddr_limit(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, U64 limit, U64 endt_us)
|
||||
{
|
||||
String8 result = ctrl_query_cached_data_from_process_vaddr_range(arena, machine_id, process, r1u64(vaddr, vaddr+limit));
|
||||
for(U64 idx = 0; idx < result.size; idx += 1)
|
||||
{
|
||||
if(result.str[idx] == 0)
|
||||
{
|
||||
result.size = idx;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
internal B32
|
||||
ctrl_process_write_data(CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, String8 data)
|
||||
ctrl_process_write(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, void *src)
|
||||
{
|
||||
ProfBeginFunction();
|
||||
B32 result = demon_write_memory(ctrl_demon_handle_from_ctrl(process), vaddr, data.str, data.size);
|
||||
U64 size = dim_1u64(range);
|
||||
B32 result = demon_write_memory(ctrl_demon_handle_from_ctrl(process), range.min, src, size);
|
||||
if(result)
|
||||
{
|
||||
ins_atomic_u64_inc_eval(&ctrl_state->memgen_idx);
|
||||
@@ -945,6 +768,23 @@ ctrl_process_write_data(CTRL_MachineID machine_id, CTRL_Handle process, U64 vadd
|
||||
return result;
|
||||
}
|
||||
|
||||
//- rjf: process memory cache interaction
|
||||
|
||||
internal U128
|
||||
ctrl_hash_store_key_from_process_vaddr_range(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, B32 zero_terminated)
|
||||
{
|
||||
U64 key_hash_data[] =
|
||||
{
|
||||
(U64)machine_id,
|
||||
(U64)process.u64[0],
|
||||
range.min,
|
||||
range.max,
|
||||
(U64)zero_terminated,
|
||||
};
|
||||
U128 key = hs_hash_from_data(str8((U8*)key_hash_data, sizeof(key_hash_data)));
|
||||
return key;
|
||||
}
|
||||
|
||||
internal U128
|
||||
ctrl_stored_hash_from_process_vaddr_range(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, B32 zero_terminated)
|
||||
{
|
||||
@@ -1056,6 +896,132 @@ ctrl_stored_hash_from_process_vaddr_range(CTRL_MachineID machine_id, CTRL_Handle
|
||||
return result;
|
||||
}
|
||||
|
||||
//- rjf: process memory cache reading helpers
|
||||
|
||||
internal CTRL_ProcessMemorySlice
|
||||
ctrl_query_cached_data_from_process_vaddr_range(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range)
|
||||
{
|
||||
CTRL_ProcessMemorySlice result = {0};
|
||||
result.byte_bad_flags = push_array(arena, U64, (dim_1u64(range)+63)/64);
|
||||
result.byte_changed_flags = push_array(arena, U64, (dim_1u64(range)+63)/64);
|
||||
if(range.max > range.min &&
|
||||
dim_1u64(range) <= MB(256) &&
|
||||
range.min <= 0x000FFFFFFFFFFFFFull &&
|
||||
range.max <= 0x000FFFFFFFFFFFFFull)
|
||||
{
|
||||
Temp scratch = scratch_begin(&arena, 1);
|
||||
HS_Scope *scope = hs_scope_open();
|
||||
CTRL_ProcessMemoryCache *cache = &ctrl_state->process_memory_cache;
|
||||
|
||||
//- rjf: unpack address range, prepare per-touched-page info
|
||||
U64 page_size = KB(4);
|
||||
Rng1U64 page_range = r1u64(AlignDownPow2(range.min, page_size), AlignPow2(range.max, page_size));
|
||||
U64 page_count = dim_1u64(page_range)/page_size;
|
||||
U128 *page_hashes = push_array(scratch.arena, U128, page_count);
|
||||
U128 *page_last_hashes = push_array(scratch.arena, U128, page_count);
|
||||
|
||||
//- rjf: gather hashes & last-hashes for each page
|
||||
for(U64 page_idx = 0; page_idx < page_count; page_idx += 1)
|
||||
{
|
||||
U64 page_base_vaddr = page_range.min + page_idx*page_size;
|
||||
U128 page_key = ctrl_hash_store_key_from_process_vaddr_range(machine_id, process, r1u64(page_base_vaddr, page_base_vaddr+page_size), 0);
|
||||
U128 page_hash = ctrl_stored_hash_from_process_vaddr_range(machine_id, process, r1u64(page_base_vaddr, page_base_vaddr+page_size), 0);
|
||||
U128 page_last_hash = hs_hash_from_key(page_key, 1);
|
||||
page_hashes[page_idx] = page_hash;
|
||||
page_last_hashes[page_idx] = page_last_hash;
|
||||
}
|
||||
|
||||
//- rjf: setup output buffers
|
||||
void *read_out = push_array(arena, U8, dim_1u64(range));
|
||||
U64 *byte_bad_flags = result.byte_bad_flags;
|
||||
U64 *byte_changed_flags = result.byte_changed_flags;
|
||||
|
||||
//- rjf: iterate pages, fill output
|
||||
{
|
||||
U64 write_off = 0;
|
||||
for(U64 page_idx = 0; page_idx < page_count; page_idx += 1)
|
||||
{
|
||||
// rjf: read data for this page
|
||||
String8 data = hs_data_from_hash(scope, page_hashes[page_idx]);
|
||||
Rng1U64 data_vaddr_range = r1u64(page_range.min + page_idx*page_size, page_range.min + page_idx*page_size+data.size);
|
||||
|
||||
// rjf: skip/chop bytes which are irrelevant for the actual requested read
|
||||
String8 in_range_data = data;
|
||||
if(page_idx == page_count-1 && data_vaddr_range.max > range.max)
|
||||
{
|
||||
in_range_data = str8_chop(in_range_data, data_vaddr_range.max-range.max);
|
||||
}
|
||||
if(page_idx == 0 && range.min > data_vaddr_range.min)
|
||||
{
|
||||
in_range_data = str8_skip(in_range_data, range.min-data_vaddr_range.min);
|
||||
}
|
||||
|
||||
// rjf: write this chunk
|
||||
MemoryCopy((U8*)read_out+write_off, in_range_data.str, in_range_data.size);
|
||||
|
||||
// rjf: if this page's hash & last_hash don't match, diff each byte &
|
||||
// fill out changed flags
|
||||
if(!u128_match(page_hashes[page_idx], page_last_hashes[page_idx]))
|
||||
{
|
||||
String8 last_data = hs_data_from_hash(scope, page_last_hashes[page_idx]);
|
||||
String8 in_range_last_data = last_data;
|
||||
if(page_idx == page_count-1 && data_vaddr_range.max > range.max)
|
||||
{
|
||||
in_range_last_data = str8_chop(in_range_last_data, data_vaddr_range.max-range.max);
|
||||
}
|
||||
if(page_idx == 0 && range.min > data_vaddr_range.min)
|
||||
{
|
||||
in_range_last_data = str8_skip(in_range_last_data, range.min-data_vaddr_range.min);
|
||||
}
|
||||
for(U64 idx = 0; idx < in_range_data.size; idx += 1)
|
||||
{
|
||||
U8 last_byte = idx < in_range_last_data.size ? in_range_last_data.str[idx] : 0;
|
||||
U8 now_byte = idx < in_range_data.size ? in_range_data.str[idx] : 0;
|
||||
if(last_byte != now_byte)
|
||||
{
|
||||
U64 idx_in_read_out = write_off+idx;
|
||||
byte_changed_flags[idx_in_read_out/64] |= (1ull<<(idx_in_read_out%64));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: increment past this chunk
|
||||
write_off += in_range_data.size;
|
||||
if(data.size < page_size)
|
||||
{
|
||||
U64 missed_byte_count = page_size-data.size;
|
||||
write_off += missed_byte_count;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//- rjf: fill result
|
||||
result.data.str = (U8*)read_out;
|
||||
result.data.size = dim_1u64(range);
|
||||
result.byte_bad_flags = byte_bad_flags;
|
||||
result.byte_changed_flags = byte_changed_flags;
|
||||
|
||||
hs_scope_close(scope);
|
||||
scratch_end(scratch);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
internal CTRL_ProcessMemorySlice
|
||||
ctrl_query_cached_zero_terminated_data_from_process_vaddr_limit(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, U64 limit, U64 endt_us)
|
||||
{
|
||||
CTRL_ProcessMemorySlice result = ctrl_query_cached_data_from_process_vaddr_range(arena, machine_id, process, r1u64(vaddr, vaddr+limit));
|
||||
for(U64 idx = 0; idx < result.data.size; idx += 1)
|
||||
{
|
||||
if(result.data.str[idx] == 0)
|
||||
{
|
||||
result.data.size = idx;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
//- rjf: register reading/writing
|
||||
|
||||
internal void *
|
||||
@@ -1967,7 +1933,6 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
{
|
||||
ProfBeginFunction();
|
||||
Temp scratch = scratch_begin(0, 0);
|
||||
DBGI_Scope *scope = dbgi_scope_open();
|
||||
|
||||
//- rjf: launch
|
||||
OS_LaunchOptions opts = {0};
|
||||
@@ -2052,6 +2017,8 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
// rjf: done with handshake -> ready to find entry point. search launched processes
|
||||
case DEMON_EventKind_HandshakeComplete:
|
||||
{
|
||||
DBGI_Scope *scope = dbgi_scope_open();
|
||||
|
||||
// rjf: find entry point vaddr
|
||||
for(U64 process_idx = 0; process_idx < run_ctrls.run_entity_count; process_idx += 1)
|
||||
{
|
||||
@@ -2062,114 +2029,174 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
DBGI_Parse *dbgi = dbgi_parse_from_exe_path(scope, exe_path, max_U64);
|
||||
RADDBG_Parsed *rdbg = &dbgi->rdbg;
|
||||
RADDBG_NameMap *unparsed_map = raddbg_name_map_from_kind(rdbg, RADDBG_NameMapKind_Procedures);
|
||||
RADDBG_ParsedNameMap map = {0};
|
||||
raddbg_name_map_parse(rdbg, unparsed_map, &map);
|
||||
String8 default_entry_points[] =
|
||||
{
|
||||
str8_lit("WinMain"),
|
||||
str8_lit("wWinMain"),
|
||||
str8_lit("main"),
|
||||
str8_lit("wmain"),
|
||||
str8_lit("WinMainCRTStartup"),
|
||||
str8_lit("wWinMainCRTStartup"),
|
||||
str8_lit("mainCRTStartup"),
|
||||
str8_lit("wmainCRTStartup"),
|
||||
};
|
||||
|
||||
// rjf: default to picking PE header's entry
|
||||
B32 entry_is_user_defined = 0;
|
||||
U64 entry_voff = dbgi->pe.entry_point;
|
||||
if(rdbg->scope_vmap != 0 && rdbg->procedures != 0 &&
|
||||
rdbg->unit_vmap != 0 && rdbg->units != 0 &&
|
||||
rdbg->file_paths)
|
||||
{
|
||||
U64 scope_idx = raddbg_vmap_idx_from_voff(rdbg->scope_vmap, rdbg->scope_vmap_count, entry_voff);
|
||||
RADDBG_Scope *scope = &rdbg->scopes[scope_idx];
|
||||
U64 proc_idx = scope->proc_idx;
|
||||
RADDBG_Procedure *procedure = &rdbg->procedures[proc_idx];
|
||||
U64 name_size = 0;
|
||||
U8 *name_base = raddbg_string_from_idx(rdbg, procedure->name_string_idx, &name_size);
|
||||
String8 name = str8(name_base, name_size);
|
||||
U64 unit_idx = raddbg_vmap_idx_from_voff(rdbg->unit_vmap, rdbg->unit_vmap_count, entry_voff);
|
||||
RADDBG_Unit *unit = &rdbg->units[unit_idx];
|
||||
RADDBG_ParsedLineInfo unit_line_info = {0};
|
||||
raddbg_line_info_from_unit(rdbg, unit, &unit_line_info);
|
||||
U64 line_info_idx = raddbg_line_info_idx_from_voff(&unit_line_info, entry_voff);
|
||||
if(name_size != 0 && line_info_idx < unit_line_info.count)
|
||||
{
|
||||
String8 obj_path = {0};
|
||||
{
|
||||
String8List obj_path_nodes = {0};
|
||||
for(U32 idx = unit->object_file_path_node; idx != 0; idx = rdbg->file_paths[idx].parent_path_node)
|
||||
{
|
||||
RADDBG_FilePathNode *n = &rdbg->file_paths[idx];
|
||||
U64 n_name_size = 0;
|
||||
U8 *n_name_base = raddbg_string_from_idx(rdbg, n->name_string_idx, &n_name_size);
|
||||
str8_list_push_front(scratch.arena, &obj_path_nodes, str8(n_name_base, n_name_size));
|
||||
}
|
||||
StringJoin join = {0};
|
||||
join.sep = str8_lit("/");
|
||||
obj_path = str8_list_join(scratch.arena, &obj_path_nodes, &join);
|
||||
}
|
||||
FileProperties props = os_properties_from_file_path(obj_path);
|
||||
if(props.modified)
|
||||
{
|
||||
entry_is_user_defined = 1;
|
||||
}
|
||||
}
|
||||
B32 entry_point_matches_defaults = 0;
|
||||
for(U64 idx = 0; idx < ArrayCount(default_entry_points); idx += 1)
|
||||
{
|
||||
if(str8_match(name, default_entry_points[idx], 0))
|
||||
{
|
||||
entry_point_matches_defaults = 1;
|
||||
}
|
||||
}
|
||||
if(!entry_point_matches_defaults && name.size != 0)
|
||||
{
|
||||
entry_is_user_defined = 1;
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: find voff for one of the default entry points
|
||||
if(!entry_is_user_defined)
|
||||
{
|
||||
for(U64 idx = 0; idx < ArrayCount(default_entry_points); idx += 1)
|
||||
{
|
||||
U32 procedure_id = 0;
|
||||
{
|
||||
String8 name = default_entry_points[idx];
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
{
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
}
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
{
|
||||
U64 new_voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
if(new_voff != 0)
|
||||
{
|
||||
entry_voff = new_voff;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: find voff for one of the custom entry points attached to this msg
|
||||
if(rdbg->procedures != 0 && unparsed_map != 0)
|
||||
{
|
||||
// rjf: grab parsed name map
|
||||
RADDBG_ParsedNameMap map = {0};
|
||||
raddbg_name_map_parse(rdbg, unparsed_map, &map);
|
||||
|
||||
// rjf: grab entry point symbol names we might want to run to
|
||||
String8 default_entry_points[] =
|
||||
for(String8Node *n = msg->strings.first; n != 0; n = n->next)
|
||||
{
|
||||
str8_lit("WinMain"),
|
||||
str8_lit("wWinMain"),
|
||||
str8_lit("main"),
|
||||
str8_lit("wmain"),
|
||||
str8_lit("WinMainCRTStartup"),
|
||||
str8_lit("wWinMainCRTStartup"),
|
||||
str8_lit("mainCRTStartup"),
|
||||
str8_lit("wmainCRTStartup"),
|
||||
};
|
||||
|
||||
// rjf: find voff for one of the custom entry points attached to this msg
|
||||
U64 voff = 0;
|
||||
if(voff == 0)
|
||||
{
|
||||
for(String8Node *n = msg->strings.first; n != 0; n = n->next)
|
||||
U32 procedure_id = 0;
|
||||
{
|
||||
U32 procedure_id = 0;
|
||||
String8 name = n->string;
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
{
|
||||
String8 name = n->string;
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
{
|
||||
U64 new_voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
if(new_voff != 0)
|
||||
{
|
||||
voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
entry_voff = new_voff;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: find voff for one of the user's custom entry points
|
||||
if(voff == 0)
|
||||
}
|
||||
|
||||
// rjf: find voff for one of the user's custom entry points
|
||||
if(rdbg->procedures != 0 && unparsed_map != 0)
|
||||
{
|
||||
for(String8Node *n = ctrl_state->user_entry_points.first; n != 0; n = n->next)
|
||||
{
|
||||
for(String8Node *n = ctrl_state->user_entry_points.first; n != 0; n = n->next)
|
||||
U32 procedure_id = 0;
|
||||
{
|
||||
U32 procedure_id = 0;
|
||||
String8 name = n->string;
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
{
|
||||
String8 name = n->string;
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
{
|
||||
U64 new_voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
if(new_voff != 0)
|
||||
{
|
||||
voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
entry_voff = new_voff;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: find voff for one of the default entry points
|
||||
if(voff == 0)
|
||||
{
|
||||
for(U64 idx = 0; voff == 0 && idx < ArrayCount(default_entry_points); idx += 1)
|
||||
{
|
||||
U32 procedure_id = 0;
|
||||
{
|
||||
String8 name = default_entry_points[idx];
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(rdbg, &map, name.str, name.size);
|
||||
if(node != 0)
|
||||
{
|
||||
U32 id_count = 0;
|
||||
U32 *ids = raddbg_matches_from_map_node(rdbg, node, &id_count);
|
||||
if(id_count > 0)
|
||||
{
|
||||
procedure_id = ids[0];
|
||||
}
|
||||
}
|
||||
}
|
||||
if(procedure_id != 0)
|
||||
{
|
||||
voff = raddbg_first_voff_from_proc(rdbg, procedure_id);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: nonzero voff? => store
|
||||
if(voff != 0)
|
||||
{
|
||||
U64 base_vaddr = demon_base_vaddr_from_module(module);
|
||||
entry_vaddr = base_vaddr + voff;
|
||||
entry_vaddr_proc = run_ctrls.run_entities[process_idx];
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: nonzero voff? => store
|
||||
if(entry_voff != 0)
|
||||
{
|
||||
U64 base_vaddr = demon_base_vaddr_from_module(module);
|
||||
entry_vaddr = base_vaddr + entry_voff;
|
||||
entry_vaddr_proc = run_ctrls.run_entities[process_idx];
|
||||
}
|
||||
|
||||
// rjf: found entry point -> insert into trap controls
|
||||
@@ -2187,6 +2214,8 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
stop_event = event;
|
||||
}
|
||||
}
|
||||
|
||||
dbgi_scope_close(scope);
|
||||
}break;
|
||||
}
|
||||
}
|
||||
@@ -2206,16 +2235,17 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
{
|
||||
CTRL_EventList evts = {0};
|
||||
CTRL_Event *event = ctrl_event_list_push(scratch.arena, &evts);
|
||||
event->kind = CTRL_EventKind_Stopped;
|
||||
event->kind = CTRL_EventKind_Stopped;
|
||||
event->msg_id = msg->msg_id;
|
||||
if(stop_event != 0)
|
||||
{
|
||||
event->cause = ctrl_event_cause_from_demon_event_kind(stop_event->kind);
|
||||
event->machine_id = CTRL_MachineID_Client;
|
||||
event->entity = ctrl_handle_from_demon(stop_event->thread);
|
||||
event->parent = ctrl_handle_from_demon(stop_event->process);
|
||||
event->cause = ctrl_event_cause_from_demon_event_kind(stop_event->kind);
|
||||
event->machine_id = CTRL_MachineID_Client;
|
||||
event->entity = ctrl_handle_from_demon(stop_event->thread);
|
||||
event->parent = ctrl_handle_from_demon(stop_event->process);
|
||||
event->exception_code = stop_event->code;
|
||||
event->vaddr_rng = r1u64(stop_event->address, stop_event->address);
|
||||
event->rip_vaddr = stop_event->instruction_pointer;
|
||||
event->vaddr_rng = r1u64(stop_event->address, stop_event->address);
|
||||
event->rip_vaddr = stop_event->instruction_pointer;
|
||||
}
|
||||
ctrl_c2u_push_events(&evts);
|
||||
}
|
||||
@@ -2231,7 +2261,6 @@ ctrl_thread__launch_and_init(CTRL_Msg *msg)
|
||||
ctrl_c2u_push_events(&evts);
|
||||
}
|
||||
|
||||
dbgi_scope_close(scope);
|
||||
scratch_end(scratch);
|
||||
ProfEnd();
|
||||
}
|
||||
@@ -3174,6 +3203,7 @@ ctrl_mem_stream_thread__entry_point(void *p)
|
||||
Rng1U64 vaddr_range = {0};
|
||||
B32 zero_terminated = 0;
|
||||
ctrl_u2ms_dequeue_req(&machine_id, &process, &vaddr_range, &zero_terminated);
|
||||
U128 key = ctrl_hash_store_key_from_process_vaddr_range(machine_id, process, vaddr_range, zero_terminated);
|
||||
|
||||
//- rjf: unpack process memory cache key
|
||||
U64 process_hash = ctrl_hash_from_string(str8_struct(&process));
|
||||
@@ -3187,7 +3217,9 @@ ctrl_mem_stream_thread__entry_point(void *p)
|
||||
|
||||
//- rjf: take task
|
||||
B32 got_task = 0;
|
||||
OS_MutexScopeR(process_stripe->rw_mutex)
|
||||
U64 preexisting_memgen_idx = 0;
|
||||
U128 preexisting_hash = {0};
|
||||
OS_MutexScopeW(process_stripe->rw_mutex)
|
||||
{
|
||||
for(CTRL_ProcessMemoryCacheNode *n = process_slot->first; n != 0; n = n->next)
|
||||
{
|
||||
@@ -3200,6 +3232,8 @@ ctrl_mem_stream_thread__entry_point(void *p)
|
||||
if(MemoryMatchStruct(&range_n->vaddr_range, &vaddr_range) && range_n->zero_terminated == zero_terminated)
|
||||
{
|
||||
got_task = !ins_atomic_u32_eval_cond_assign(&range_n->is_taken, 1, 0);
|
||||
preexisting_memgen_idx = range_n->memgen_idx;
|
||||
preexisting_hash = range_n->hash;
|
||||
goto take_task__break_all;
|
||||
}
|
||||
}
|
||||
@@ -3214,7 +3248,7 @@ ctrl_mem_stream_thread__entry_point(void *p)
|
||||
void *range_base = 0;
|
||||
U64 zero_terminated_size = 0;
|
||||
U64 memgen_idx = ctrl_memgen_idx();
|
||||
if(got_task)
|
||||
if(got_task && memgen_idx != preexisting_memgen_idx)
|
||||
{
|
||||
range_size = dim_1u64(vaddr_range);
|
||||
U64 arena_size = AlignPow2(range_size + ARENA_HEADER_SIZE, KB(64));
|
||||
@@ -3246,16 +3280,6 @@ ctrl_mem_stream_thread__entry_point(void *p)
|
||||
}
|
||||
}
|
||||
|
||||
//- rjf: determine key for this region
|
||||
U64 key_hash_data[] =
|
||||
{
|
||||
(U64)machine_id,
|
||||
(U64)process.u64[0],
|
||||
vaddr_range.min,
|
||||
vaddr_range.min + zero_terminated_size,
|
||||
};
|
||||
U128 key = hs_hash_from_data(str8((U8 *)key_hash_data, sizeof(key_hash_data)));
|
||||
|
||||
//- rjf: read successful -> submit to hash store
|
||||
U128 hash = {0};
|
||||
if(got_task && range_base != 0)
|
||||
|
||||
+16
-46
@@ -311,48 +311,6 @@ struct CTRL_EventList
|
||||
////////////////////////////////
|
||||
//~ rjf: Process Memory Cache Types
|
||||
|
||||
// NOTE(rjf):
|
||||
//
|
||||
// Process memory is cached with a 5-level page table. Each level has 256
|
||||
// slots, and is indexed into with 8 bits. Each index is extracted from a
|
||||
// virtual address in the following manner:
|
||||
//
|
||||
// |1------||2------||3------||4------||5------||byte-n-page|
|
||||
// xxxxxxxx xxxx0000 00000000 00000000 00000000 00000000 0000xxxx xxxxxxxx
|
||||
//
|
||||
// The top 12 bits are not used (a 52-bit address space is supported at most).
|
||||
// The next 8 most-significant-bits are used to index into the level 1 table.
|
||||
// The next 8 are used to index into the level 2. Then the level 3. Then the
|
||||
// level 4. At the level 4 table, instead of pointing to other tables, each
|
||||
// slot points at the base address of a cached 4KB page. The next 8 bits are
|
||||
// used to index into that table. The final 12 bits in the address are used
|
||||
// to refer to unique bytes within each page.
|
||||
|
||||
typedef struct CTRL_ProcessMemoryCacheNode4 CTRL_ProcessMemoryCacheNode4;
|
||||
struct CTRL_ProcessMemoryCacheNode4
|
||||
{
|
||||
U64 page_memgen_idxs[256];
|
||||
U128 page_hashes[256];
|
||||
};
|
||||
|
||||
typedef struct CTRL_ProcessMemoryCacheNode3 CTRL_ProcessMemoryCacheNode3;
|
||||
struct CTRL_ProcessMemoryCacheNode3
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode4 *children[256];
|
||||
};
|
||||
|
||||
typedef struct CTRL_ProcessMemoryCacheNode2 CTRL_ProcessMemoryCacheNode2;
|
||||
struct CTRL_ProcessMemoryCacheNode2
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode3 *children[256];
|
||||
};
|
||||
|
||||
typedef struct CTRL_ProcessMemoryCacheNode1 CTRL_ProcessMemoryCacheNode1;
|
||||
struct CTRL_ProcessMemoryCacheNode1
|
||||
{
|
||||
CTRL_ProcessMemoryCacheNode2 *children[256];
|
||||
};
|
||||
|
||||
typedef struct CTRL_ProcessMemoryRangeHashNode CTRL_ProcessMemoryRangeHashNode;
|
||||
struct CTRL_ProcessMemoryRangeHashNode
|
||||
{
|
||||
@@ -379,7 +337,6 @@ struct CTRL_ProcessMemoryCacheNode
|
||||
Arena *arena;
|
||||
CTRL_MachineID machine_id;
|
||||
CTRL_Handle process;
|
||||
CTRL_ProcessMemoryCacheNode1 *children[256];
|
||||
U64 range_hash_slots_count;
|
||||
CTRL_ProcessMemoryRangeHashSlot *range_hash_slots;
|
||||
};
|
||||
@@ -406,6 +363,14 @@ struct CTRL_ProcessMemoryCache
|
||||
CTRL_ProcessMemoryCacheStripe *stripes;
|
||||
};
|
||||
|
||||
typedef struct CTRL_ProcessMemorySlice CTRL_ProcessMemorySlice;
|
||||
struct CTRL_ProcessMemorySlice
|
||||
{
|
||||
String8 data;
|
||||
U64 *byte_bad_flags;
|
||||
U64 *byte_changed_flags;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Wakeup Hook Function Types
|
||||
|
||||
@@ -560,11 +525,16 @@ internal Architecture ctrl_arch_from_handle(CTRL_MachineID machine, CTRL_Handle
|
||||
|
||||
//- rjf: process memory reading/writing
|
||||
internal U64 ctrl_process_read(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, void *dst);
|
||||
internal String8 ctrl_query_cached_data_from_process_vaddr_range(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range);
|
||||
internal String8 ctrl_query_cached_zero_terminated_data_from_process_vaddr_limit(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, U64 limit, U64 endt_us);
|
||||
internal B32 ctrl_process_write_data(CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, String8 data);
|
||||
internal B32 ctrl_process_write(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, void *src);
|
||||
|
||||
//- rjf: process memory cache interaction
|
||||
internal U128 ctrl_hash_store_key_from_process_vaddr_range(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, B32 zero_terminated);
|
||||
internal U128 ctrl_stored_hash_from_process_vaddr_range(CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range, B32 zero_terminated);
|
||||
|
||||
//- rjf: process memory cache reading helpers
|
||||
internal CTRL_ProcessMemorySlice ctrl_query_cached_data_from_process_vaddr_range(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, Rng1U64 range);
|
||||
internal CTRL_ProcessMemorySlice ctrl_query_cached_zero_terminated_data_from_process_vaddr_limit(Arena *arena, CTRL_MachineID machine_id, CTRL_Handle process, U64 vaddr, U64 limit, U64 endt_us);
|
||||
|
||||
//- rjf: register reading/writing
|
||||
internal void *ctrl_reg_block_from_thread(CTRL_MachineID machine_id, CTRL_Handle thread);
|
||||
internal B32 ctrl_thread_write_reg_block(CTRL_MachineID machine_id, CTRL_Handle thread, void *block);
|
||||
|
||||
@@ -659,6 +659,10 @@ dbgi_parse_thread_entry_point(void *p)
|
||||
raddbg_file_is_up_to_date = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
raddbg_file_is_up_to_date = 0;
|
||||
}
|
||||
os_file_map_view_close(file_map, file_base);
|
||||
os_file_map_close(file_map);
|
||||
os_file_close(file);
|
||||
|
||||
+215
-73
@@ -1621,7 +1621,7 @@ df_entity_notify_mutation(DF_Entity *entity)
|
||||
DF_CmdParams p = {0};
|
||||
df_push_cmd__root(&p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_WriteProfileData));
|
||||
}
|
||||
if(e == entity && flags & DF_EntityKindFlag_LeafMutationSoftHalt)
|
||||
if(e == entity && flags & DF_EntityKindFlag_LeafMutationSoftHalt && df_ctrl_targets_running())
|
||||
{
|
||||
df_state->entities_mut_soft_halt = 1;
|
||||
}
|
||||
@@ -1629,7 +1629,7 @@ df_entity_notify_mutation(DF_Entity *entity)
|
||||
{
|
||||
df_state->entities_mut_dbg_info_map = 1;
|
||||
}
|
||||
if(flags & DF_EntityKindFlag_TreeMutationSoftHalt)
|
||||
if(flags & DF_EntityKindFlag_TreeMutationSoftHalt && df_ctrl_targets_running())
|
||||
{
|
||||
df_state->entities_mut_soft_halt = 1;
|
||||
}
|
||||
@@ -3486,12 +3486,14 @@ df_tls_base_vaddr_from_thread(DF_Entity *thread)
|
||||
U64 thread_info_addr = ctrl_tls_root_vaddr_from_thread(thread->ctrl_machine_id, thread->ctrl_handle);
|
||||
U64 tls_addr_off = tls_index*addr_size;
|
||||
U64 tls_addr_array = 0;
|
||||
String8 tls_addr_array_data = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(thread_info_addr, thread_info_addr+addr_size));
|
||||
CTRL_ProcessMemorySlice tls_addr_array_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(thread_info_addr, thread_info_addr+addr_size));
|
||||
String8 tls_addr_array_data = tls_addr_array_slice.data;
|
||||
if(tls_addr_array_data.size >= 8)
|
||||
{
|
||||
MemoryCopy(&tls_addr_array, tls_addr_array_data.str, sizeof(U64));
|
||||
}
|
||||
String8 result_data = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(tls_addr_array + tls_addr_off, tls_addr_array + tls_addr_off + addr_size));
|
||||
CTRL_ProcessMemorySlice result_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(tls_addr_array + tls_addr_off, tls_addr_array + tls_addr_off + addr_size));
|
||||
String8 result_data = result_slice.data;
|
||||
if(result_data.size >= 8)
|
||||
{
|
||||
MemoryCopy(&base_vaddr, result_data.str, sizeof(U64));
|
||||
@@ -3953,7 +3955,8 @@ df_eval_memory_read(void *u, void *out, U64 addr, U64 size)
|
||||
Assert(process->kind == DF_EntityKind_Process);
|
||||
Temp scratch = scratch_begin(0, 0);
|
||||
B32 result = 0;
|
||||
String8 data = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(addr, addr+size));
|
||||
CTRL_ProcessMemorySlice slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, r1u64(addr, addr+size));
|
||||
String8 data = slice.data;
|
||||
if(data.size == size)
|
||||
{
|
||||
result = 1;
|
||||
@@ -4251,7 +4254,8 @@ df_value_mode_eval_from_eval(TG_Graph *graph, RADDBG_Parsed *rdbg, DF_CtrlCtx *c
|
||||
Rng1U64 vaddr_range = r1u64(eval.offset, eval.offset + type_byte_size);
|
||||
if(dim_1u64(vaddr_range) == type_byte_size)
|
||||
{
|
||||
String8 data = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, vaddr_range);
|
||||
CTRL_ProcessMemorySlice slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, vaddr_range);
|
||||
String8 data = slice.data;
|
||||
MemoryZeroArray(eval.imm_u128);
|
||||
MemoryCopy(eval.imm_u128, data.str, Min(data.size, sizeof(U64)*2));
|
||||
eval.mode = EVAL_EvalMode_Value;
|
||||
@@ -4328,14 +4332,16 @@ df_dynamically_typed_eval_from_eval(TG_Graph *graph, RADDBG_Parsed *rdbg, DF_Ctr
|
||||
{
|
||||
U64 ptr_vaddr = eval.offset;
|
||||
U64 addr_size = bit_size_from_arch(arch)/8;
|
||||
String8 ptr_value_memory = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle,
|
||||
r1u64(ptr_vaddr, ptr_vaddr+addr_size));
|
||||
CTRL_ProcessMemorySlice ptr_value_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle,
|
||||
r1u64(ptr_vaddr, ptr_vaddr+addr_size));
|
||||
String8 ptr_value_memory = ptr_value_slice.data;
|
||||
if(ptr_value_memory.size >= addr_size)
|
||||
{
|
||||
U64 class_base_vaddr = 0;
|
||||
MemoryCopy(&class_base_vaddr, ptr_value_memory.str, addr_size);
|
||||
String8 vtable_base_ptr_memory = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle,
|
||||
r1u64(class_base_vaddr, class_base_vaddr+addr_size));
|
||||
CTRL_ProcessMemorySlice vtable_base_ptr_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle,
|
||||
r1u64(class_base_vaddr, class_base_vaddr+addr_size));
|
||||
String8 vtable_base_ptr_memory = vtable_base_ptr_slice.data;
|
||||
if(vtable_base_ptr_memory.size >= addr_size)
|
||||
{
|
||||
U64 vtable_vaddr = 0;
|
||||
@@ -4872,7 +4878,7 @@ df_commit_eval_value(TG_Graph *graph, RADDBG_Parsed *rdbg, DF_CtrlCtx *ctrl_ctx,
|
||||
default:{}break;
|
||||
case EVAL_EvalMode_Addr:
|
||||
{
|
||||
ctrl_process_write_data(process->ctrl_machine_id, process->ctrl_handle, dst_eval.offset, commit_data);
|
||||
ctrl_process_write(process->ctrl_machine_id, process->ctrl_handle, r1u64(dst_eval.offset, dst_eval.offset+commit_data.size), commit_data.str);
|
||||
}break;
|
||||
case EVAL_EvalMode_Reg:
|
||||
{
|
||||
@@ -5684,6 +5690,64 @@ df_cfg_table(void)
|
||||
|
||||
//- rjf: config serialization
|
||||
|
||||
internal String8
|
||||
df_cfg_escaped_from_raw_string(Arena *arena, String8 string)
|
||||
{
|
||||
Temp scratch = scratch_begin(&arena, 1);
|
||||
String8List parts = {0};
|
||||
U64 split_start_idx = 0;
|
||||
for(U64 idx = 0; idx <= string.size; idx += 1)
|
||||
{
|
||||
U8 byte = (idx < string.size ? string.str[idx] : 0);
|
||||
if(byte == 0 || byte == '\"')
|
||||
{
|
||||
String8 part = str8_substr(string, r1u64(split_start_idx, idx));
|
||||
str8_list_push(scratch.arena, &parts, part);
|
||||
switch(byte)
|
||||
{
|
||||
default:{}break;
|
||||
case '\"':{str8_list_push(scratch.arena, &parts, str8_lit("\\\""));}break;
|
||||
}
|
||||
split_start_idx = idx+1;
|
||||
}
|
||||
}
|
||||
StringJoin join = {0};
|
||||
String8 result = str8_list_join(arena, &parts, &join);
|
||||
scratch_end(scratch);
|
||||
return result;
|
||||
}
|
||||
|
||||
internal String8
|
||||
df_cfg_raw_from_escaped_string(Arena *arena, String8 string)
|
||||
{
|
||||
Temp scratch = scratch_begin(&arena, 1);
|
||||
String8List parts = {0};
|
||||
U64 split_start_idx = 0;
|
||||
U64 extra_advance = 0;
|
||||
for(U64 idx = 0; idx <= string.size; ((idx += 1+extra_advance), extra_advance=0))
|
||||
{
|
||||
U8 byte = (idx < string.size ? string.str[idx] : 0);
|
||||
if(byte == 0 || byte == '\\')
|
||||
{
|
||||
String8 part = str8_substr(string, r1u64(split_start_idx, idx));
|
||||
str8_list_push(scratch.arena, &parts, part);
|
||||
if(byte == '\\' && idx+1 < string.size)
|
||||
{
|
||||
switch(string.str[idx+1])
|
||||
{
|
||||
default:{}break;
|
||||
case '"':{extra_advance = 1; str8_list_push(scratch.arena, &parts, str8_lit("\""));}break;
|
||||
}
|
||||
}
|
||||
split_start_idx = idx+1+extra_advance;
|
||||
}
|
||||
}
|
||||
StringJoin join = {0};
|
||||
String8 result = str8_list_join(arena, &parts, &join);
|
||||
scratch_end(scratch);
|
||||
return result;
|
||||
}
|
||||
|
||||
internal String8List
|
||||
df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source)
|
||||
{
|
||||
@@ -5718,18 +5782,21 @@ df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source)
|
||||
String8 wdir_normalized = path_normalized_from_string(scratch.arena, wdir);
|
||||
String8 wdir_normalized_rel = path_relative_dst_from_absolute_dst_src(scratch.arena, wdir_normalized, root_path);
|
||||
String8 entry_point_name = entr__ent->name;
|
||||
String8 label_escaped = df_cfg_escaped_from_raw_string(arena, label);
|
||||
String8 args_escaped = df_cfg_escaped_from_raw_string(arena, args__ent->name);
|
||||
String8 entry_escaped = df_cfg_escaped_from_raw_string(arena, entry_point_name);
|
||||
str8_list_push (arena, &strs, str8_lit("target:\n"));
|
||||
str8_list_push (arena, &strs, str8_lit("{\n"));
|
||||
if(label.size != 0)
|
||||
{
|
||||
str8_list_pushf(arena, &strs, " label: \"%S\"\n", label);
|
||||
str8_list_pushf(arena, &strs, " label: \"%S\"\n", label_escaped);
|
||||
}
|
||||
str8_list_pushf(arena, &strs, " exe: \"%S\"\n", exe_normalized_rel);
|
||||
str8_list_pushf(arena, &strs, " arguments: \"%S\"\n", args__ent->name);
|
||||
str8_list_pushf(arena, &strs, " arguments: \"%S\"\n", args_escaped);
|
||||
str8_list_pushf(arena, &strs, " working_directory: \"%S\"\n", wdir_normalized_rel);
|
||||
if(entry_point_name.size != 0)
|
||||
{
|
||||
str8_list_pushf(arena, &strs, " entry_point: \"%S\"\n", entry_point_name);
|
||||
str8_list_pushf(arena, &strs, " entry_point: \"%S\"\n", entry_escaped);
|
||||
}
|
||||
str8_list_pushf(arena, &strs, " active: %i\n", (int)target->b32);
|
||||
if(target->flags & DF_EntityFlag_HasColor)
|
||||
@@ -5806,7 +5873,8 @@ df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source)
|
||||
// rjf: function name breakpoints
|
||||
else if(!df_entity_is_nil(symb) && symb->name.size != 0)
|
||||
{
|
||||
str8_list_pushf(arena, &strs, " symbol: \"%S\"\n", symb->name);
|
||||
String8 symb_escaped = df_cfg_escaped_from_raw_string(arena, symb->name);
|
||||
str8_list_pushf(arena, &strs, " symbol: \"%S\"\n", symb_escaped);
|
||||
}
|
||||
|
||||
// rjf: address breakpoints
|
||||
@@ -5818,13 +5886,15 @@ df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source)
|
||||
// rjf: conditions
|
||||
if(!df_entity_is_nil(cond))
|
||||
{
|
||||
str8_list_pushf(arena, &strs, " condition: \"%S\"\n", cond->name);
|
||||
String8 cond_escaped = df_cfg_escaped_from_raw_string(arena, cond->name);
|
||||
str8_list_pushf(arena, &strs, " condition: \"%S\"\n", cond_escaped);
|
||||
}
|
||||
|
||||
// rjf: universal options
|
||||
str8_list_pushf(arena, &strs, " enabled: %i\n", (int)bp->b32);
|
||||
if(bp->name.size != 0)
|
||||
{
|
||||
String8 label_escaped = df_cfg_escaped_from_raw_string(arena, bp->name);
|
||||
str8_list_pushf(arena, &strs, " label: \"%S\"\n", bp->name);
|
||||
}
|
||||
if(bp->flags & DF_EntityFlag_HasColor)
|
||||
@@ -5858,7 +5928,8 @@ df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source)
|
||||
// rjf: write
|
||||
str8_list_push(arena, &strs, str8_lit("watch_pin:\n"));
|
||||
str8_list_push(arena, &strs, str8_lit("{\n"));
|
||||
str8_list_pushf(arena, &strs, " expression: \"%S\"\n", pin->name);
|
||||
String8 expr_escaped = df_cfg_escaped_from_raw_string(arena, pin->name);
|
||||
str8_list_pushf(arena, &strs, " expression: \"%S\"\n", expr_escaped);
|
||||
DF_Entity *file = df_entity_ancestor_from_kind(pin, DF_EntityKind_File);
|
||||
if(pin->flags & DF_EntityFlag_HasTextPoint && !df_entity_is_nil(file))
|
||||
{
|
||||
@@ -6440,6 +6511,23 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
DF_CmdParams params = df_cmd_params_zero();
|
||||
df_cmd_list_push(arena, cmds, ¶ms, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_Error));
|
||||
}
|
||||
|
||||
// rjf: kill all entities which are marked to die on stop
|
||||
{
|
||||
DF_Entity *request = df_entity_from_id(event->msg_id);
|
||||
if(df_entity_is_nil(request))
|
||||
{
|
||||
for(DF_Entity *entity = df_entity_root();
|
||||
!df_entity_is_nil(entity);
|
||||
entity = df_entity_rec_df_pre(entity, df_entity_root()).next)
|
||||
{
|
||||
if(entity->flags & DF_EntityFlag_DiesOnRunStop)
|
||||
{
|
||||
df_entity_mark_for_deletion(entity);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}break;
|
||||
|
||||
//- rjf: entity creation/deletion
|
||||
@@ -6877,14 +6965,6 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
String8 string = str8_substr(args, r1u64(start_split_idx, idx));
|
||||
if(string.size > 0)
|
||||
{
|
||||
if(str8_match(str8_prefix(string, 1), str8_lit("\""), 0))
|
||||
{
|
||||
string = str8_skip(string, 1);
|
||||
}
|
||||
if(str8_match(str8_postfix(string, 1), str8_lit("\""), 0))
|
||||
{
|
||||
string = str8_chop(string, 1);
|
||||
}
|
||||
str8_list_push(scratch.arena, &cmdln_strings, string);
|
||||
}
|
||||
start_split_idx = idx+1;
|
||||
@@ -7036,7 +7116,6 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
case DF_CoreCmdKind_StepIntoLine:
|
||||
case DF_CoreCmdKind_StepOverLine:
|
||||
case DF_CoreCmdKind_StepOut:
|
||||
case DF_CoreCmdKind_RunToAddress:
|
||||
{
|
||||
DF_Entity *thread = df_entity_from_handle(params.entity);
|
||||
if(df_ctrl_targets_running())
|
||||
@@ -7088,11 +7167,6 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
good = 0;
|
||||
}
|
||||
}break;
|
||||
case DF_CoreCmdKind_RunToAddress:
|
||||
{
|
||||
CTRL_Trap trap = {CTRL_TrapFlag_EndStepping|CTRL_TrapFlag_IgnoreStackPointerCheck, params.vaddr};
|
||||
ctrl_trap_list_push(scratch.arena, &traps, &trap);
|
||||
}break;
|
||||
}
|
||||
if(good && traps.count != 0)
|
||||
{
|
||||
@@ -7127,6 +7201,30 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}break;
|
||||
|
||||
//- rjf: high-level composite target control operations
|
||||
case DF_CoreCmdKind_RunToLine:
|
||||
{
|
||||
DF_Entity *file = df_entity_from_handle(params.entity);
|
||||
TxtPt point = params.text_point;
|
||||
if(file->kind == DF_EntityKind_File)
|
||||
{
|
||||
DF_Entity *bp = df_entity_alloc(0, file, DF_EntityKind_Breakpoint);
|
||||
bp->flags |= DF_EntityFlag_DiesOnRunStop;
|
||||
df_entity_equip_b32(bp, 1);
|
||||
df_entity_equip_txt_pt(bp, point);
|
||||
df_entity_equip_cfg_src(bp, DF_CfgSrc_Transient);
|
||||
DF_CmdParams p = df_cmd_params_zero();
|
||||
df_cmd_list_push(arena, cmds, &p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_Run));
|
||||
}
|
||||
}break;
|
||||
case DF_CoreCmdKind_RunToAddress:
|
||||
{
|
||||
DF_Entity *bp = df_entity_alloc(0, df_entity_root(), DF_EntityKind_Breakpoint);
|
||||
bp->flags |= DF_EntityFlag_DiesOnRunStop;
|
||||
df_entity_equip_vaddr(bp, params.vaddr);
|
||||
df_entity_equip_cfg_src(bp, DF_CfgSrc_Transient);
|
||||
DF_CmdParams p = df_cmd_params_zero();
|
||||
df_cmd_list_push(arena, cmds, &p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_Run));
|
||||
}break;
|
||||
case DF_CoreCmdKind_Run:
|
||||
{
|
||||
DF_CmdParams params = df_cmd_params_zero();
|
||||
@@ -7321,8 +7419,8 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}break;
|
||||
|
||||
//- rjf: config path saving/loading/applying
|
||||
case DF_CoreCmdKind_LoadUser:
|
||||
case DF_CoreCmdKind_LoadProfile:
|
||||
case DF_CoreCmdKind_OpenUser:
|
||||
case DF_CoreCmdKind_OpenProfile:
|
||||
{
|
||||
B32 load_cfg[DF_CfgSrc_COUNT] = {0};
|
||||
for(DF_CfgSrc src = (DF_CfgSrc)0; src < DF_CfgSrc_COUNT; src = (DF_CfgSrc)(src+1))
|
||||
@@ -7530,46 +7628,66 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
|
||||
//- rjf: apply targets
|
||||
DF_CfgVal *targets = df_cfg_val_from_string(table, str8_lit("target"));
|
||||
for(DF_CfgNode *target = targets->first;
|
||||
target != &df_g_nil_cfg_node;
|
||||
target = target->next)
|
||||
{
|
||||
if(target->source == src)
|
||||
B32 cmd_line_target_present = 0;
|
||||
{
|
||||
DF_CfgNode *label_cfg = df_cfg_node_child_from_string(target, str8_lit("label"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *exe_cfg = df_cfg_node_child_from_string(target, str8_lit("exe"), StringMatchFlag_CaseInsensitive);
|
||||
if(exe_cfg == &df_g_nil_cfg_node)
|
||||
DF_EntityList existing_target_entities = df_query_cached_entity_list_with_kind(DF_EntityKind_Target);
|
||||
for(DF_EntityNode *n = existing_target_entities.first; n != 0; n = n->next)
|
||||
{
|
||||
exe_cfg = df_cfg_node_child_from_string(target, str8_lit("name"), StringMatchFlag_CaseInsensitive);
|
||||
DF_Entity *target = n->entity;
|
||||
if(target->cfg_src == DF_CfgSrc_CommandLine && target->b32)
|
||||
{
|
||||
cmd_line_target_present = 1;
|
||||
}
|
||||
}
|
||||
DF_CfgNode *args_cfg = df_cfg_node_child_from_string(target, str8_lit("arguments"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *wdir_cfg = df_cfg_node_child_from_string(target, str8_lit("working_directory"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *entry_cfg = df_cfg_node_child_from_string(target, str8_lit("entry_point"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *active_cfg = df_cfg_node_child_from_string(target, str8_lit("active"), StringMatchFlag_CaseInsensitive);
|
||||
Vec4F32 hsva = df_hsva_from_cfg_node(target);
|
||||
U64 is_active_u64 = 0;
|
||||
try_u64_from_str8_c_rules(active_cfg->first->string, &is_active_u64);
|
||||
DF_Entity *target__ent = df_entity_alloc(0, df_entity_root(), DF_EntityKind_Target);
|
||||
DF_Entity *exe__ent = df_entity_alloc(0, target__ent, DF_EntityKind_Executable);
|
||||
DF_Entity *args__ent = df_entity_alloc(0, target__ent, DF_EntityKind_Arguments);
|
||||
DF_Entity *path__ent = df_entity_alloc(0, target__ent, DF_EntityKind_ExecutionPath);
|
||||
DF_Entity *entry__ent = df_entity_alloc(0, target__ent, DF_EntityKind_EntryPointName);
|
||||
String8 saved_label = label_cfg->first->string;
|
||||
String8 saved_exe = exe_cfg->first->string;
|
||||
String8 saved_exe_absolute = path_absolute_dst_from_relative_dst_src(scratch.arena, saved_exe, cfg_folder);
|
||||
String8 saved_wdir = wdir_cfg->first->string;
|
||||
String8 saved_wdir_absolute = path_absolute_dst_from_relative_dst_src(scratch.arena, saved_wdir, cfg_folder);
|
||||
String8 saved_entry_point = entry_cfg->first->string;
|
||||
df_entity_equip_b32(target__ent, active_cfg != &df_g_nil_cfg_node ? !!is_active_u64 : 1);
|
||||
df_entity_equip_name(0, target__ent, saved_label);
|
||||
df_entity_equip_name(0, exe__ent, saved_exe_absolute);
|
||||
df_entity_equip_name(0, args__ent, args_cfg->first->string);
|
||||
df_entity_equip_name(0, path__ent, saved_wdir_absolute);
|
||||
df_entity_equip_name(0, entry__ent, saved_entry_point);
|
||||
df_entity_equip_cfg_src(target__ent, src);
|
||||
if(!memory_is_zero(&hsva, sizeof(hsva)))
|
||||
}
|
||||
for(DF_CfgNode *target = targets->first;
|
||||
target != &df_g_nil_cfg_node;
|
||||
target = target->next)
|
||||
{
|
||||
if(target->source == src)
|
||||
{
|
||||
df_entity_equip_color_hsva(target__ent, hsva);
|
||||
DF_CfgNode *label_cfg = df_cfg_node_child_from_string(target, str8_lit("label"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *exe_cfg = df_cfg_node_child_from_string(target, str8_lit("exe"), StringMatchFlag_CaseInsensitive);
|
||||
if(exe_cfg == &df_g_nil_cfg_node)
|
||||
{
|
||||
exe_cfg = df_cfg_node_child_from_string(target, str8_lit("name"), StringMatchFlag_CaseInsensitive);
|
||||
}
|
||||
DF_CfgNode *args_cfg = df_cfg_node_child_from_string(target, str8_lit("arguments"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *wdir_cfg = df_cfg_node_child_from_string(target, str8_lit("working_directory"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *entry_cfg = df_cfg_node_child_from_string(target, str8_lit("entry_point"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *active_cfg = df_cfg_node_child_from_string(target, str8_lit("active"), StringMatchFlag_CaseInsensitive);
|
||||
Vec4F32 hsva = df_hsva_from_cfg_node(target);
|
||||
U64 is_active_u64 = 0;
|
||||
if(!cmd_line_target_present)
|
||||
{
|
||||
try_u64_from_str8_c_rules(active_cfg->first->string, &is_active_u64);
|
||||
}
|
||||
DF_Entity *target__ent = df_entity_alloc(0, df_entity_root(), DF_EntityKind_Target);
|
||||
DF_Entity *exe__ent = df_entity_alloc(0, target__ent, DF_EntityKind_Executable);
|
||||
DF_Entity *args__ent = df_entity_alloc(0, target__ent, DF_EntityKind_Arguments);
|
||||
DF_Entity *path__ent = df_entity_alloc(0, target__ent, DF_EntityKind_ExecutionPath);
|
||||
DF_Entity *entry__ent = df_entity_alloc(0, target__ent, DF_EntityKind_EntryPointName);
|
||||
String8 saved_label = label_cfg->first->string;
|
||||
String8 saved_exe = exe_cfg->first->string;
|
||||
String8 saved_exe_absolute = path_absolute_dst_from_relative_dst_src(scratch.arena, saved_exe, cfg_folder);
|
||||
String8 saved_wdir = wdir_cfg->first->string;
|
||||
String8 saved_wdir_absolute = path_absolute_dst_from_relative_dst_src(scratch.arena, saved_wdir, cfg_folder);
|
||||
String8 saved_entry_point = entry_cfg->first->string;
|
||||
String8 saved_label_raw = df_cfg_raw_from_escaped_string(scratch.arena, saved_label);
|
||||
String8 saved_entry_raw = df_cfg_raw_from_escaped_string(scratch.arena, saved_entry_point);
|
||||
String8 saved_args_raw = df_cfg_raw_from_escaped_string(scratch.arena, args_cfg->first->string);
|
||||
df_entity_equip_b32(target__ent, active_cfg != &df_g_nil_cfg_node ? !!is_active_u64 : 1);
|
||||
df_entity_equip_name(0, target__ent, saved_label_raw);
|
||||
df_entity_equip_name(0, exe__ent, saved_exe_absolute);
|
||||
df_entity_equip_name(0, args__ent, saved_args_raw);
|
||||
df_entity_equip_name(0, path__ent, saved_wdir_absolute);
|
||||
df_entity_equip_name(0, entry__ent, saved_entry_raw);
|
||||
df_entity_equip_cfg_src(target__ent, src);
|
||||
if(!memory_is_zero(&hsva, sizeof(hsva)))
|
||||
{
|
||||
df_entity_equip_color_hsva(target__ent, hsva);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7678,12 +7796,14 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}
|
||||
if(symb_cfg != &df_g_nil_cfg_node)
|
||||
{
|
||||
String8 symb_raw = df_cfg_raw_from_escaped_string(scratch.arena, symb_cfg->string);
|
||||
DF_Entity *symb = df_entity_alloc(0, bp_ent, DF_EntityKind_EntryPointName);
|
||||
df_entity_equip_name(0, symb, symb_cfg->first->string);
|
||||
df_entity_equip_name(0, symb, symb_raw);
|
||||
}
|
||||
if(labl_cfg->string.size != 0)
|
||||
{
|
||||
df_entity_equip_name(0, bp_ent, labl_cfg->first->string);
|
||||
String8 label_raw = df_cfg_raw_from_escaped_string(scratch.arena, labl_cfg->string);
|
||||
df_entity_equip_name(0, bp_ent, label_raw);
|
||||
}
|
||||
if(!memory_is_zero(&hsva, sizeof(hsva)))
|
||||
{
|
||||
@@ -7691,8 +7811,9 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}
|
||||
if(cond_cfg->string.size != 0)
|
||||
{
|
||||
String8 cond_raw = df_cfg_raw_from_escaped_string(scratch.arena, cond_cfg->string);
|
||||
DF_Entity *cond = df_entity_alloc(0, bp_ent, DF_EntityKind_Condition);
|
||||
df_entity_equip_name(0, cond, cond_cfg->first->string);
|
||||
df_entity_equip_name(0, cond, cond_raw);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7709,6 +7830,7 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}
|
||||
Vec4F32 hsva = df_hsva_from_cfg_node(pin);
|
||||
String8 string = df_string_from_cfg_node_key(pin, str8_lit("expression"), StringMatchFlag_CaseInsensitive);
|
||||
String8 string_raw = df_cfg_raw_from_escaped_string(scratch.arena, string);
|
||||
DF_CfgNode *line_cfg = df_cfg_node_child_from_string(pin, str8_lit("line"), StringMatchFlag_CaseInsensitive);
|
||||
DF_CfgNode *addr_cfg = df_cfg_node_child_from_string(pin, str8_lit("addr"), StringMatchFlag_CaseInsensitive);
|
||||
DF_Entity *pin_parent_ent = df_entity_root();
|
||||
@@ -7735,7 +7857,7 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}
|
||||
DF_Entity *pin_ent = df_entity_alloc(0, pin_parent_ent, DF_EntityKind_WatchPin);
|
||||
df_entity_equip_cfg_src(pin_ent, src);
|
||||
df_entity_equip_name(0, pin_ent, string);
|
||||
df_entity_equip_name(0, pin_ent, string_raw);
|
||||
if(!memory_is_zero(&hsva, sizeof(hsva)))
|
||||
{
|
||||
df_entity_equip_color_hsva(pin_ent, hsva);
|
||||
@@ -7930,6 +8052,7 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
//- rjf: general entity operations
|
||||
case DF_CoreCmdKind_EnableEntity:
|
||||
case DF_CoreCmdKind_EnableBreakpoint:
|
||||
case DF_CoreCmdKind_EnableTarget:
|
||||
{
|
||||
DF_Entity *entity = df_entity_from_handle(params.entity);
|
||||
df_state_delta_history_push_batch(df_state->hist, &entity->generation);
|
||||
@@ -7938,6 +8061,7 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
}break;
|
||||
case DF_CoreCmdKind_DisableEntity:
|
||||
case DF_CoreCmdKind_DisableBreakpoint:
|
||||
case DF_CoreCmdKind_DisableTarget:
|
||||
{
|
||||
DF_Entity *entity = df_entity_from_handle(params.entity);
|
||||
df_state_delta_history_push_batch(df_state->hist, &entity->generation);
|
||||
@@ -8155,7 +8279,6 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
// rjf: build target
|
||||
df_state_delta_history_push_batch(df_state_delta_history(), 0);
|
||||
DF_Entity *entity = df_entity_alloc(df_state_delta_history(), df_entity_root(), DF_EntityKind_Target);
|
||||
df_entity_equip_b32(entity, 1);
|
||||
df_entity_equip_cfg_src(entity, DF_CfgSrc_Profile);
|
||||
DF_Entity *exe = df_entity_alloc(df_state_delta_history(), entity, DF_EntityKind_Executable);
|
||||
df_entity_equip_name(df_state_delta_history(), exe, params.file_path);
|
||||
@@ -8170,6 +8293,25 @@ df_core_begin_frame(Arena *arena, DF_CmdList *cmds, F32 dt)
|
||||
p.entity = df_handle_from_entity(entity);
|
||||
df_cmd_params_mark_slot(&p, DF_CmdParamSlot_Entity);
|
||||
df_cmd_list_push(arena, cmds, &p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_EditTarget));
|
||||
df_cmd_list_push(arena, cmds, &p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_SelectTarget));
|
||||
}break;
|
||||
case DF_CoreCmdKind_SelectTarget:
|
||||
{
|
||||
DF_Entity *entity = df_entity_from_handle(params.entity);
|
||||
if(entity->kind == DF_EntityKind_Target)
|
||||
{
|
||||
DF_EntityList all_targets = df_query_cached_entity_list_with_kind(DF_EntityKind_Target);
|
||||
B32 is_selected = entity->b32;
|
||||
for(DF_EntityNode *n = all_targets.first; n != 0; n = n->next)
|
||||
{
|
||||
DF_Entity *target = n->entity;
|
||||
df_entity_equip_b32(target, 0);
|
||||
}
|
||||
if(!is_selected)
|
||||
{
|
||||
df_entity_equip_b32(entity, 1);
|
||||
}
|
||||
}
|
||||
}break;
|
||||
|
||||
//- rjf: ended processes
|
||||
|
||||
+14
-11
@@ -463,21 +463,22 @@ enum
|
||||
DF_EntityFlag_HasRng1U64 = (1<<5),
|
||||
DF_EntityFlag_HasColor = (1<<6),
|
||||
DF_EntityFlag_DiesWithTime = (1<<7),
|
||||
DF_EntityFlag_DiesOnRunStop = (1<<8),
|
||||
|
||||
//- rjf: ctrl entity equipment
|
||||
DF_EntityFlag_HasCtrlMachineID = (1<<8),
|
||||
DF_EntityFlag_HasCtrlHandle = (1<<9),
|
||||
DF_EntityFlag_HasArch = (1<<10),
|
||||
DF_EntityFlag_HasCtrlID = (1<<11),
|
||||
DF_EntityFlag_HasStackBase = (1<<12),
|
||||
DF_EntityFlag_HasTLSRoot = (1<<13),
|
||||
DF_EntityFlag_HasVAddrRng = (1<<14),
|
||||
DF_EntityFlag_HasVAddr = (1<<15),
|
||||
DF_EntityFlag_HasCtrlMachineID = (1<<9),
|
||||
DF_EntityFlag_HasCtrlHandle = (1<<10),
|
||||
DF_EntityFlag_HasArch = (1<<11),
|
||||
DF_EntityFlag_HasCtrlID = (1<<12),
|
||||
DF_EntityFlag_HasStackBase = (1<<13),
|
||||
DF_EntityFlag_HasTLSRoot = (1<<14),
|
||||
DF_EntityFlag_HasVAddrRng = (1<<15),
|
||||
DF_EntityFlag_HasVAddr = (1<<16),
|
||||
|
||||
//- rjf: file properties
|
||||
DF_EntityFlag_IsFolder = (1<<16),
|
||||
DF_EntityFlag_IsMissing = (1<<17),
|
||||
DF_EntityFlag_Output = (1<<18), // NOTE(rjf): might be missing, but written by us
|
||||
DF_EntityFlag_IsFolder = (1<<17),
|
||||
DF_EntityFlag_IsMissing = (1<<18),
|
||||
DF_EntityFlag_Output = (1<<19), // NOTE(rjf): might be missing, but written by us
|
||||
|
||||
//- rjf: deletion
|
||||
DF_EntityFlag_MarkedForDeletion = (1<<31),
|
||||
@@ -1649,6 +1650,8 @@ internal String8 df_cfg_path_from_src(DF_CfgSrc src);
|
||||
internal DF_CfgTable *df_cfg_table(void);
|
||||
|
||||
//- rjf: config serialization
|
||||
internal String8 df_cfg_escaped_from_raw_string(Arena *arena, String8 string);
|
||||
internal String8 df_cfg_raw_from_escaped_string(Arena *arena, String8 string);
|
||||
internal String8List df_cfg_strings_from_core(Arena *arena, String8 root_path, DF_CfgSrc source);
|
||||
internal void df_cfg_push_write_string(DF_CfgSrc src, String8 string);
|
||||
|
||||
|
||||
+202
-197
@@ -7,9 +7,10 @@
|
||||
@table(string, name, load_cmd, write_cmd, apply_cmd)
|
||||
DF_CfgSrcTable:
|
||||
{
|
||||
{"user" User LoadUser WriteUserData ApplyUserData }
|
||||
{"profile" Profile LoadProfile WriteProfileData ApplyProfileData }
|
||||
{"user" User OpenUser WriteUserData ApplyUserData }
|
||||
{"profile" Profile OpenProfile WriteProfileData ApplyProfileData }
|
||||
{"command_line" CommandLine Null Null Null }
|
||||
{"transient" Transient Null Null Null }
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
@@ -105,279 +106,283 @@ DF_CmdParamSlotTable:
|
||||
// / | | \ / | | | | |
|
||||
DF_CoreCmdTable:// | | | | | | | | |
|
||||
{
|
||||
{Null 1 Null Nil 0 0 0 0 0 0 Null "" "" "" "" }
|
||||
{Null 1 Null Nil 0 0 0 0 0 0 Null "" "" "" "" }
|
||||
|
||||
//- rjf: exiting
|
||||
{Exit 0 Null Nil 0 0 0 0 0 0 X "exit" "Exit" "Exits the debugger." "quit,close,abort" }
|
||||
{Exit 0 Null Nil 0 0 0 0 0 0 X "exit" "Exit" "Exits the debugger." "quit,close,abort" }
|
||||
|
||||
//- rjf: command runner
|
||||
{RunCommand 0 CmdSpec Nil 0 0 0 0 0 0 Null "run_command" "Run Command" "Runs a command from the command palette." "help,cmd" }
|
||||
{RunCommand 0 CmdSpec Nil 0 0 0 0 0 0 Null "run_command" "Run Command" "Runs a command from the command palette." "help,cmd" }
|
||||
|
||||
//- rjf: notifications
|
||||
{Error 1 Null Nil 0 0 0 0 0 0 Null "error" "Error" "Notifies of an error." "" }
|
||||
{Error 1 Null Nil 0 0 0 0 0 0 Null "error" "Error" "Notifies of an error." "" }
|
||||
|
||||
//- rjf: low-level target control operations
|
||||
{LaunchAndRun 0 EntityList Target 0 0 0 0 0 1 Play "launch_and_run" "Launch and Run" "Starts debugging a new instance of a target, then runs." "launch,start,run,target" }
|
||||
{LaunchAndInit 0 EntityList Target 0 0 0 0 0 1 PlayStepForward "launch_and_init" "Launch and Initialize" "Starts debugging a new instance of a target, then stops at the program's entry point." "launch,start,entry,point" }
|
||||
{Kill 0 EntityList Process 0 0 0 0 0 1 Stop "kill" "Kill" "Kills the specified existing debugged process(es)." "stop,kill" }
|
||||
{KillAll 0 Null Nil 0 0 0 0 0 0 Stop "kill_all" "Kill All" "Kills all debugged child processes." "stop,kill,all" }
|
||||
{Detach 0 EntityList Process 0 0 0 0 0 1 Null "detach" "Detach" "Detaches the specified debugged process." "detach" }
|
||||
{Continue 0 Null Nil 0 0 0 0 0 0 Play "continue" "Continue" "Continues all halted threads." "" }
|
||||
{StepIntoInst 0 Null Nil 0 0 0 0 0 0 StepInto "step_into_inst" "Step Into (Assembly)" "Performs a step that goes into calls, at the instruction level." "single,step,thread" }
|
||||
{StepOverInst 0 Null Nil 0 0 0 0 0 0 StepOver "step_over_inst" "Step Over (Assembly)" "Performs a step that skips calls, at the instruction level." "single,step,thread" }
|
||||
{StepIntoLine 0 Null Nil 0 0 0 0 0 0 StepInto "step_into_line" "Step Into (Line)" "Performs a step that goes into calls, at the source code line level." "step,thread" }
|
||||
{StepOverLine 0 Null Nil 0 0 0 0 0 0 StepOver "step_over_line" "Step Over (Line)" "Performs a step that skips calls, at the source code line level." "step,thread" }
|
||||
{StepOut 0 Null Nil 0 0 0 0 0 0 StepOut "step_out" "Step Out" "Runs to the end of the current function and exits it." "" }
|
||||
{RunToAddress 0 VirtualAddr Nil 0 0 0 0 1 1 PlayStepForward "run_to_address" "Run To Address" "Runs the selected thread to the specified address." "" }
|
||||
{Halt 0 Null Nil 0 0 0 0 0 0 Pause "halt" "Halt" "Halts all running processes." "pause" }
|
||||
{SoftHaltRefresh 0 Null Nil 0 0 0 0 0 0 Refresh "soft_halt_refresh" "Soft Halt Refresh" "Interrupts all running processes to collect data, and then resumes them." "" }
|
||||
{SetThreadIP 1 VirtualAddr Nil 0 0 0 0 1 1 Null "set_thread_ip" "Set Thread IP" "Sets the passed thread's instruction pointer at the passed address." "" }
|
||||
{LaunchAndRun 0 EntityList Target 0 0 0 0 0 1 Play "launch_and_run" "Launch and Run" "Starts debugging a new instance of a target, then runs." "launch,start,run,target" }
|
||||
{LaunchAndInit 0 EntityList Target 0 0 0 0 0 1 PlayStepForward "launch_and_init" "Launch and Initialize" "Starts debugging a new instance of a target, then stops at the program's entry point." "launch,start,entry,point" }
|
||||
{Kill 0 EntityList Process 0 0 0 0 0 1 Stop "kill" "Kill" "Kills the specified existing debugged process(es)." "stop,kill" }
|
||||
{KillAll 0 Null Nil 0 0 0 0 0 0 Stop "kill_all" "Kill All" "Kills all debugged child processes." "stop,kill,all" }
|
||||
{Detach 0 EntityList Process 0 0 0 0 0 1 Null "detach" "Detach" "Detaches the specified debugged process." "detach" }
|
||||
{Continue 0 Null Nil 0 0 0 0 0 0 Play "continue" "Continue" "Continues all halted threads." "" }
|
||||
{StepIntoInst 0 Null Nil 0 0 0 0 0 0 StepInto "step_into_inst" "Step Into (Assembly)" "Performs a step that goes into calls, at the instruction level." "single,step,thread" }
|
||||
{StepOverInst 0 Null Nil 0 0 0 0 0 0 StepOver "step_over_inst" "Step Over (Assembly)" "Performs a step that skips calls, at the instruction level." "single,step,thread" }
|
||||
{StepIntoLine 0 Null Nil 0 0 0 0 0 0 StepInto "step_into_line" "Step Into (Line)" "Performs a step that goes into calls, at the source code line level." "step,thread" }
|
||||
{StepOverLine 0 Null Nil 0 0 0 0 0 0 StepOver "step_over_line" "Step Over (Line)" "Performs a step that skips calls, at the source code line level." "step,thread" }
|
||||
{StepOut 0 Null Nil 0 0 0 0 0 0 StepOut "step_out" "Step Out" "Runs to the end of the current function and exits it." "" }
|
||||
{Halt 0 Null Nil 0 0 0 0 0 0 Pause "halt" "Halt" "Halts all running processes." "pause" }
|
||||
{SoftHaltRefresh 0 Null Nil 0 0 0 0 0 0 Refresh "soft_halt_refresh" "Soft Halt Refresh" "Interrupts all running processes to collect data, and then resumes them." "" }
|
||||
{SetThreadIP 1 VirtualAddr Nil 0 0 0 0 1 1 Null "set_thread_ip" "Set Thread IP" "Sets the passed thread's instruction pointer at the passed address." "" }
|
||||
|
||||
//- rjf: high-level composite target control operations
|
||||
{Run 0 Null Nil 0 0 0 0 0 0 Play "run" "Run" "Runs all targets after starting them if they have not been started yet." "play" }
|
||||
{Restart 0 Null Nil 0 0 0 0 0 0 Redo "restart" "Restart" "Kills all running processes, then restarts the targets which were used to launch all current processes (if any)." "restart,retry" }
|
||||
{StepInto 0 Null Nil 0 0 0 0 0 0 StepInto "step_into" "Step Into" "Steps once, possibly into function calls, for either line or instructions." "" }
|
||||
{StepOver 0 Null Nil 0 0 0 0 0 0 StepOver "step_over" "Step Over" "Steps once, always over function calls, for either line or instructions." "" }
|
||||
{RunToCursor 0 Null Nil 0 0 0 0 0 0 Play "run_to_cursor" "Run To Cursor" "Runs the selected thread to the current cursor." "" }
|
||||
{SetNextStatement 0 Null Nil 0 0 0 0 0 0 RightArrow "set_next_statement" "Set Next Statement" "Sets the selected thread's instruction pointer to the cursor's position." "" }
|
||||
{RunToLine 1 Null Nil 0 0 0 0 0 0 Play "run_to_line" "Run To Line" "Runs until a particular source line is hit." "" }
|
||||
{RunToAddress 0 VirtualAddr Nil 0 0 0 0 1 1 PlayStepForward "run_to_address" "Run To Address" "Runs until a particular address is hit." "" }
|
||||
{Run 0 Null Nil 0 0 0 0 0 0 Play "run" "Run" "Runs all targets after starting them if they have not been started yet." "play" }
|
||||
{Restart 0 Null Nil 0 0 0 0 0 0 Redo "restart" "Restart" "Kills all running processes, then restarts the targets which were used to launch all current processes (if any)." "restart,retry" }
|
||||
{StepInto 0 Null Nil 0 0 0 0 0 0 StepInto "step_into" "Step Into" "Steps once, possibly into function calls, for either line or instructions." "" }
|
||||
{StepOver 0 Null Nil 0 0 0 0 0 0 StepOver "step_over" "Step Over" "Steps once, always over function calls, for either line or instructions." "" }
|
||||
{RunToCursor 0 Null Nil 0 0 0 0 0 0 Play "run_to_cursor" "Run To Cursor" "Runs the selected thread to the current cursor." "" }
|
||||
{SetNextStatement 0 Null Nil 0 0 0 0 0 0 RightArrow "set_next_statement" "Set Next Statement" "Sets the selected thread's instruction pointer to the cursor's position." "" }
|
||||
|
||||
//- rjf: solo stepping mode
|
||||
{EnableSoloSteppingMode 0 Null Nil 0 0 0 0 0 0 Thread "enable_solo_stepping_mode" "Enable Solo Stepping Mode" "Enables 'solo stepping mode', which suspends all non-selected threads before stepping." "solo,stepping,mode,suspend" }
|
||||
{DisableSoloSteppingMode 0 Null Nil 0 0 0 0 0 0 Thread "disable_solo_stepping_mode" "Disable Solo Stepping Mode" "Disables 'solo stepping mode', which suspends all non-selected threads before stepping." "solo,stepping,mode,suspend" }
|
||||
{EnableSoloSteppingMode 0 Null Nil 0 0 0 0 0 0 Thread "enable_solo_stepping_mode" "Enable Solo Stepping Mode" "Enables 'solo stepping mode', which suspends all non-selected threads before stepping." "solo,stepping,mode,suspend" }
|
||||
{DisableSoloSteppingMode 0 Null Nil 0 0 0 0 0 0 Thread "disable_solo_stepping_mode" "Disable Solo Stepping Mode" "Disables 'solo stepping mode', which suspends all non-selected threads before stepping." "solo,stepping,mode,suspend" }
|
||||
|
||||
//- rjf: debug control context management operations
|
||||
{SelectThread 0 Entity Thread 0 0 0 0 0 1 Null "select_thread" "Select Thread" "Selects a thread." "" }
|
||||
{SelectThreadWindow 0 Entity Thread 0 0 0 0 0 1 Null "select_thread_window" "Select Thread On Window" "Selects a thread for the active window, overriding the global selected thread." "" }
|
||||
{SelectThreadView 0 Entity Thread 0 0 0 0 0 1 Null "select_thread_view" "Select Thread On View" "Selects a thread for the active view, overriding the global and per-window selected threads." "" }
|
||||
{SelectUnwind 1 Null Nil 0 0 0 0 0 0 Null "select_unwind" "Select Unwind" "Selects an unwind frame number for the selected thread." "" }
|
||||
{UpOneFrame 0 Null Nil 0 0 0 0 0 0 UpArrow "up_one_frame" "Up One Frame" "Selects the callstack frame above the currently selected." "" }
|
||||
{DownOneFrame 0 Null Nil 0 0 0 0 0 0 DownArrow "down_one_frame" "Down One Frame" "Selects the callstack frame below the currently selected." "" }
|
||||
{FreezeThread 0 Entity Thread 0 0 0 0 0 1 Locked "freeze_thread" "Freeze Thread" "Freezes the passed thread." "" }
|
||||
{ThawThread 0 Entity Thread 0 0 0 0 0 1 Unlocked "thaw_thread" "Thaw Thread" "Thaws the passed thread." "" }
|
||||
{FreezeProcess 0 Entity Process 0 0 0 0 0 1 Locked "freeze_process" "Freeze Process" "Freezes the passed process." "" }
|
||||
{ThawProcess 0 Entity Process 0 0 0 0 0 1 Unlocked "thaw_process" "Thaw Process" "Thaws the passed process." "" }
|
||||
{FreezeMachine 1 Entity Machine 0 0 0 0 0 1 Locked "freeze_machine" "Freeze Machine" "Freezes the passed machine." "" }
|
||||
{ThawMachine 1 Entity Machine 0 0 0 0 0 1 Unlocked "thaw_machine" "Thaw Machine" "Thaws the passed machine." "" }
|
||||
{FreezeLocalMachine 0 Null Nil 0 0 0 0 0 0 Machine "freeze_local_machine" "Freeze Local Machine" "Freezes the local machine." "" }
|
||||
{ThawLocalMachine 0 Null Nil 0 0 0 0 0 0 Machine "thaw_local_machine" "Thaw Local Machine" "Thaws the local machine." "" }
|
||||
{SelectThread 0 Entity Thread 0 0 0 0 0 1 Null "select_thread" "Select Thread" "Selects a thread." "" }
|
||||
{SelectThreadWindow 0 Entity Thread 0 0 0 0 0 1 Null "select_thread_window" "Select Thread On Window" "Selects a thread for the active window, overriding the global selected thread." "" }
|
||||
{SelectThreadView 0 Entity Thread 0 0 0 0 0 1 Null "select_thread_view" "Select Thread On View" "Selects a thread for the active view, overriding the global and per-window selected threads." "" }
|
||||
{SelectUnwind 1 Null Nil 0 0 0 0 0 0 Null "select_unwind" "Select Unwind" "Selects an unwind frame number for the selected thread." "" }
|
||||
{UpOneFrame 0 Null Nil 0 0 0 0 0 0 UpArrow "up_one_frame" "Up One Frame" "Selects the callstack frame above the currently selected." "" }
|
||||
{DownOneFrame 0 Null Nil 0 0 0 0 0 0 DownArrow "down_one_frame" "Down One Frame" "Selects the callstack frame below the currently selected." "" }
|
||||
{FreezeThread 0 Entity Thread 0 0 0 0 0 1 Locked "freeze_thread" "Freeze Thread" "Freezes the passed thread." "" }
|
||||
{ThawThread 0 Entity Thread 0 0 0 0 0 1 Unlocked "thaw_thread" "Thaw Thread" "Thaws the passed thread." "" }
|
||||
{FreezeProcess 0 Entity Process 0 0 0 0 0 1 Locked "freeze_process" "Freeze Process" "Freezes the passed process." "" }
|
||||
{ThawProcess 0 Entity Process 0 0 0 0 0 1 Unlocked "thaw_process" "Thaw Process" "Thaws the passed process." "" }
|
||||
{FreezeMachine 1 Entity Machine 0 0 0 0 0 1 Locked "freeze_machine" "Freeze Machine" "Freezes the passed machine." "" }
|
||||
{ThawMachine 1 Entity Machine 0 0 0 0 0 1 Unlocked "thaw_machine" "Thaw Machine" "Thaws the passed machine." "" }
|
||||
{FreezeLocalMachine 0 Null Nil 0 0 0 0 0 0 Machine "freeze_local_machine" "Freeze Local Machine" "Freezes the local machine." "" }
|
||||
{ThawLocalMachine 0 Null Nil 0 0 0 0 0 0 Machine "thaw_local_machine" "Thaw Local Machine" "Thaws the local machine." "" }
|
||||
|
||||
//- rjf: font sizes
|
||||
{IncUIFontScale 0 Null Nil 0 0 0 0 0 0 Null "inc_ui_font_scale" "Increase UI Font Scale" "Increases the font size used for UI." "" }
|
||||
{DecUIFontScale 0 Null Nil 0 0 0 0 0 0 Null "dec_ui_font_scale" "Decrease UI Font Scale" "Decreases the font size used for UI." "" }
|
||||
{IncCodeFontScale 0 Null Nil 0 0 0 0 0 0 Null "inc_code_font_scale" "Increase Code Font Scale" "Increases the font size used for code." "" }
|
||||
{DecCodeFontScale 0 Null Nil 0 0 0 0 0 0 Null "dec_code_font_scale" "Decrease Code Font Scale" "Decreases the font size used for code." "" }
|
||||
{IncUIFontScale 0 Null Nil 0 0 0 0 0 0 Null "inc_ui_font_scale" "Increase UI Font Scale" "Increases the font size used for UI." "" }
|
||||
{DecUIFontScale 0 Null Nil 0 0 0 0 0 0 Null "dec_ui_font_scale" "Decrease UI Font Scale" "Decreases the font size used for UI." "" }
|
||||
{IncCodeFontScale 0 Null Nil 0 0 0 0 0 0 Null "inc_code_font_scale" "Increase Code Font Scale" "Increases the font size used for code." "" }
|
||||
{DecCodeFontScale 0 Null Nil 0 0 0 0 0 0 Null "dec_code_font_scale" "Decrease Code Font Scale" "Decreases the font size used for code." "" }
|
||||
|
||||
//- rjf: windows
|
||||
{OpenWindow 0 Null Nil 0 0 0 0 0 0 Window "open_window" "Open New Window" "Opens a new window." "" }
|
||||
{CloseWindow 0 Null Nil 0 0 0 0 0 0 Window "close_window" "Close Window" "Closes an opened window." "" }
|
||||
{ToggleFullscreen 0 Null Nil 0 0 0 0 0 0 Window "toggle_fullscreen" "Toggle Fullscreen" "Toggles fullscreen view on the active window." "" }
|
||||
{OpenWindow 0 Null Nil 0 0 0 0 0 0 Window "open_window" "Open New Window" "Opens a new window." "" }
|
||||
{CloseWindow 0 Null Nil 0 0 0 0 0 0 Window "close_window" "Close Window" "Closes an opened window." "" }
|
||||
{ToggleFullscreen 0 Null Nil 0 0 0 0 0 0 Window "toggle_fullscreen" "Toggle Fullscreen" "Toggles fullscreen view on the active window." "" }
|
||||
|
||||
//- rjf: confirmations
|
||||
{ConfirmAccept 1 Null Nil 0 0 0 0 0 0 Null "confirm_accept" "Confirm Accept" "Accepts the active confirmation prompt." "" }
|
||||
{ConfirmCancel 1 Null Nil 0 0 0 0 0 0 Null "confirm_cancel" "Confirm Cancel" "Cancels the active confirmation prompt." "" }
|
||||
{ConfirmAccept 1 Null Nil 0 0 0 0 0 0 Null "confirm_accept" "Confirm Accept" "Accepts the active confirmation prompt." "" }
|
||||
{ConfirmCancel 1 Null Nil 0 0 0 0 0 0 Null "confirm_cancel" "Confirm Cancel" "Cancels the active confirmation prompt." "" }
|
||||
|
||||
//- rjf: panel splitting
|
||||
{ResetToDefaultPanels 0 Null Nil 0 0 0 0 0 0 Window "reset_to_default_panels" "Reset To Default Panel Layout" "Resets the window to the default panel layout." "panel" }
|
||||
{NewPanelRight 0 Null Nil 0 0 0 0 0 0 XSplit "new_panel_right" "Split Panel Vertically" "Creates a new panel to the right of the active panel." "panel" }
|
||||
{NewPanelDown 0 Null Nil 0 0 0 0 0 0 YSplit "new_panel_down" "Split Panel Horizontally" "Creates a new panel at the bottom of the active panel." "panel" }
|
||||
{ResetToDefaultPanels 0 Null Nil 0 0 0 0 0 0 Window "reset_to_default_panels" "Reset To Default Panel Layout" "Resets the window to the default panel layout." "panel" }
|
||||
{NewPanelRight 0 Null Nil 0 0 0 0 0 0 XSplit "new_panel_right" "Split Panel Vertically" "Creates a new panel to the right of the active panel." "panel" }
|
||||
{NewPanelDown 0 Null Nil 0 0 0 0 0 0 YSplit "new_panel_down" "Split Panel Horizontally" "Creates a new panel at the bottom of the active panel." "panel" }
|
||||
|
||||
//- rjf: panel rotation
|
||||
{RotatePanelColumns 0 Null Nil 0 0 0 0 0 0 Null "rotate_panel_columns" "Rotate Panel Columns" "Rotates all panels at the closest column level of the panel hierarchy." "" }
|
||||
{RotatePanelColumns 0 Null Nil 0 0 0 0 0 0 Null "rotate_panel_columns" "Rotate Panel Columns" "Rotates all panels at the closest column level of the panel hierarchy." "" }
|
||||
|
||||
//- rjf: focused panel changing
|
||||
{NextPanel 0 Null Nil 0 0 0 0 0 0 RightArrow "next_panel" "Focus Next Panel" "Cycles the active panel forward." "" }
|
||||
{PrevPanel 0 Null Nil 0 0 0 0 0 0 LeftArrow "prev_panel" "Focus Previous Panel" "Cycles the active panel backwards." "" }
|
||||
{FocusPanel 1 Null Nil 0 0 0 0 0 0 Null "focus_panel" "Focus Panel" "Focuses a new panel." "" }
|
||||
{FocusPanelRight 0 Null Nil 0 0 0 0 0 0 RightArrow "focus_panel_right" "Focus Panel Right" "Focuses a panel rightward of the currently focused panel." "" }
|
||||
{FocusPanelLeft 0 Null Nil 0 0 0 0 0 0 LeftArrow "focus_panel_left" "Focus Panel Left" "Focuses a panel leftward of the currently focused panel." "" }
|
||||
{FocusPanelUp 0 Null Nil 0 0 0 0 0 0 UpArrow "focus_panel_up" "Focus Panel Up" "Focuses a panel upward of the currently focused panel." "" }
|
||||
{FocusPanelDown 0 Null Nil 0 0 0 0 0 0 DownArrow "focus_panel_down" "Focus Panel Down" "Focuses a panel downward of the currently focused panel." "" }
|
||||
{NextPanel 0 Null Nil 0 0 0 0 0 0 RightArrow "next_panel" "Focus Next Panel" "Cycles the active panel forward." "" }
|
||||
{PrevPanel 0 Null Nil 0 0 0 0 0 0 LeftArrow "prev_panel" "Focus Previous Panel" "Cycles the active panel backwards." "" }
|
||||
{FocusPanel 1 Null Nil 0 0 0 0 0 0 Null "focus_panel" "Focus Panel" "Focuses a new panel." "" }
|
||||
{FocusPanelRight 0 Null Nil 0 0 0 0 0 0 RightArrow "focus_panel_right" "Focus Panel Right" "Focuses a panel rightward of the currently focused panel." "" }
|
||||
{FocusPanelLeft 0 Null Nil 0 0 0 0 0 0 LeftArrow "focus_panel_left" "Focus Panel Left" "Focuses a panel leftward of the currently focused panel." "" }
|
||||
{FocusPanelUp 0 Null Nil 0 0 0 0 0 0 UpArrow "focus_panel_up" "Focus Panel Up" "Focuses a panel upward of the currently focused panel." "" }
|
||||
{FocusPanelDown 0 Null Nil 0 0 0 0 0 0 DownArrow "focus_panel_down" "Focus Panel Down" "Focuses a panel downward of the currently focused panel." "" }
|
||||
|
||||
//- rjf: undo/redo
|
||||
{Undo 1 Null Nil 0 0 0 0 0 0 Undo "undo" "Undo" "Undoes the previous action." "" }
|
||||
{Redo 1 Null Nil 0 0 0 0 0 0 Redo "redo" "Redo" "Redoes the first previously undone action." "" }
|
||||
{Undo 1 Null Nil 0 0 0 0 0 0 Undo "undo" "Undo" "Undoes the previous action." "" }
|
||||
{Redo 1 Null Nil 0 0 0 0 0 0 Redo "redo" "Redo" "Redoes the first previously undone action." "" }
|
||||
|
||||
//- rjf: focus history
|
||||
{GoBack 1 Null Nil 0 0 0 0 0 0 LeftArrow "go_back" "Go Back" "Returns to the previously selected panel and tab in recorded history." "" }
|
||||
{GoForward 1 Null Nil 0 0 0 0 0 0 RightArrow "go_forward" "Go Forward" "Returns to the next selected panel and tab in recorded history." "" }
|
||||
{GoBack 1 Null Nil 0 0 0 0 0 0 LeftArrow "go_back" "Go Back" "Returns to the previously selected panel and tab in recorded history." "" }
|
||||
{GoForward 1 Null Nil 0 0 0 0 0 0 RightArrow "go_forward" "Go Forward" "Returns to the next selected panel and tab in recorded history." "" }
|
||||
|
||||
//- rjf: panel removal
|
||||
{ClosePanel 0 Null Nil 0 0 0 0 0 0 ClosePanel "close_panel" "Close Panel" "Closes the currently active panel." "" }
|
||||
{ClosePanel 0 Null Nil 0 0 0 0 0 0 ClosePanel "close_panel" "Close Panel" "Closes the currently active panel." "" }
|
||||
|
||||
//- rjf: panel tab
|
||||
{NextTab 0 Null Nil 0 0 0 0 0 0 RightArrow "next_tab" "Focus Next Tab" "Focuses the next tab on the active panel." "" }
|
||||
{PrevTab 0 Null Nil 0 0 0 0 0 0 LeftArrow "prev_tab" "Focus Previous Tab" "Focuses the previous tab on the active panel." "" }
|
||||
{MoveTabRight 0 Null Nil 0 0 0 0 0 0 RightArrow "move_tab_right" "Move Tab Right" "Moves the selected tab right one slot." "" }
|
||||
{MoveTabLeft 0 Null Nil 0 0 0 0 0 0 LeftArrow "move_tab_left" "Move Tab Left" "Moves the selected tab left one slot." "" }
|
||||
{OpenTab 1 Null Nil 0 0 0 0 0 0 Null "open_tab" "Open Tab" "Opens a new tab with the parameterized view specification." "" }
|
||||
{CloseTab 0 Null Nil 0 0 0 0 0 0 X "close_tab" "Close Tab" "Closes the currently opened tab." "" }
|
||||
{MoveTab 1 Null Nil 0 0 0 0 0 0 Null "move_tab" "Move Tab" "Moves a tab to a new panel." "" }
|
||||
{TabBarTop 0 Null Nil 0 0 0 0 0 0 UpArrow "tab_bar_top" "Anchor Tab Bar To Top" "Anchors a panel's tab bar to the top of the panel." "" }
|
||||
{TabBarBottom 0 Null Nil 0 0 0 0 0 0 DownArrow "tab_bar_bottom" "Anchor Tab Bar To Bottom" "Anchors a panel's tab bar to the bottom of the panel." "" }
|
||||
{NextTab 0 Null Nil 0 0 0 0 0 0 RightArrow "next_tab" "Focus Next Tab" "Focuses the next tab on the active panel." "" }
|
||||
{PrevTab 0 Null Nil 0 0 0 0 0 0 LeftArrow "prev_tab" "Focus Previous Tab" "Focuses the previous tab on the active panel." "" }
|
||||
{MoveTabRight 0 Null Nil 0 0 0 0 0 0 RightArrow "move_tab_right" "Move Tab Right" "Moves the selected tab right one slot." "" }
|
||||
{MoveTabLeft 0 Null Nil 0 0 0 0 0 0 LeftArrow "move_tab_left" "Move Tab Left" "Moves the selected tab left one slot." "" }
|
||||
{OpenTab 1 Null Nil 0 0 0 0 0 0 Null "open_tab" "Open Tab" "Opens a new tab with the parameterized view specification." "" }
|
||||
{CloseTab 0 Null Nil 0 0 0 0 0 0 X "close_tab" "Close Tab" "Closes the currently opened tab." "" }
|
||||
{MoveTab 1 Null Nil 0 0 0 0 0 0 Null "move_tab" "Move Tab" "Moves a tab to a new panel." "" }
|
||||
{TabBarTop 0 Null Nil 0 0 0 0 0 0 UpArrow "tab_bar_top" "Anchor Tab Bar To Top" "Anchors a panel's tab bar to the top of the panel." "" }
|
||||
{TabBarBottom 0 Null Nil 0 0 0 0 0 0 DownArrow "tab_bar_bottom" "Anchor Tab Bar To Bottom" "Anchors a panel's tab bar to the bottom of the panel." "" }
|
||||
|
||||
//- rjf: files
|
||||
{SetCurrentPath 1 Null Nil 0 0 0 0 0 0 FileOutline "set_current_path" "Set Current Path" "Sets the debugger's current path, which is used as a starting point when browsing for files." "" }
|
||||
{Open 0 FilePath Nil 1 0 0 0 0 1 FileOutline "open" "Open" "Opens a file." "code,source,file" }
|
||||
{Reload 0 Entity File 0 0 0 0 0 1 FileOutline "reload" "Reload" "Reloads a loaded file." "code,source,file,reload" }
|
||||
{ReloadActive 0 Null Nil 0 0 0 0 0 0 FileOutline "reload_active" "Reload Active File" "Reloads the active file." "code,source,file,reload" }
|
||||
{Switch 0 Entity File 0 0 0 0 0 1 FileOutline "switch" "Switch" "Switches to a loaded file." "code,source,file" }
|
||||
{SwitchToPartnerFile 0 Null Nil 0 0 0 0 0 0 FileOutline "switch_to_partner_file" "Switch To Partner File" "Switches to the focused file's partner; or from header to implementation or vice versa." "code,source,file" }
|
||||
{SetCurrentPath 1 Null Nil 0 0 0 0 0 0 FileOutline "set_current_path" "Set Current Path" "Sets the debugger's current path, which is used as a starting point when browsing for files." "" }
|
||||
{Open 0 FilePath Nil 1 0 0 0 0 1 FileOutline "open" "Open" "Opens a file." "code,source,file" }
|
||||
{Reload 0 Entity File 0 0 0 0 0 1 FileOutline "reload" "Reload" "Reloads a loaded file." "code,source,file,reload" }
|
||||
{ReloadActive 0 Null Nil 0 0 0 0 0 0 FileOutline "reload_active" "Reload Active File" "Reloads the active file." "code,source,file,reload" }
|
||||
{Switch 0 Entity File 0 0 0 0 0 1 FileOutline "switch" "Switch" "Switches to a loaded file." "code,source,file" }
|
||||
{SwitchToPartnerFile 0 Null Nil 0 0 0 0 0 0 FileOutline "switch_to_partner_file" "Switch To Partner File" "Switches to the focused file's partner; or from header to implementation or vice versa." "code,source,file" }
|
||||
|
||||
//- rjf: override file links
|
||||
{SetFileOverrideLinkSrc 1 Null Nil 0 0 0 0 0 0 Null "set_file_override_link_src" "Set File Override Link Source" "Sets the source path for an override file link." "" }
|
||||
{SetFileOverrideLinkDst 1 Null Nil 0 0 0 0 0 0 Null "set_file_override_link_dst" "Set File Override Link Destination" "Sets the destination path for an override file link." "" }
|
||||
{SetFileReplacementPath 1 Null Nil 0 0 0 0 0 0 Null "set_file_replacement_path" "Set File Replacement Path" "Sets the path which should be used as the replacement for the passed file." "" }
|
||||
{SetFileOverrideLinkSrc 1 Null Nil 0 0 0 0 0 0 Null "set_file_override_link_src" "Set File Override Link Source" "Sets the source path for an override file link." "" }
|
||||
{SetFileOverrideLinkDst 1 Null Nil 0 0 0 0 0 0 Null "set_file_override_link_dst" "Set File Override Link Destination" "Sets the destination path for an override file link." "" }
|
||||
{SetFileReplacementPath 1 Null Nil 0 0 0 0 0 0 Null "set_file_replacement_path" "Set File Replacement Path" "Sets the path which should be used as the replacement for the passed file." "" }
|
||||
|
||||
//- rjf: setting config paths
|
||||
{LoadUser 0 FilePath Nil 1 0 0 0 0 1 Person "load_user" "Load User" "Loads and applies a user file." "load,user,profile,layout" }
|
||||
{LoadProfile 0 FilePath Nil 1 0 0 0 0 1 Briefcase "load_profile" "Load Profile" "Loads and applies a profile file." "profile,project,session" }
|
||||
{OpenUser 0 FilePath Nil 1 0 0 0 0 1 Person "open_user" "Open User" "Opens a user file path, immediately loading it, and begins autosaving to it." "load,user,profile,layout" }
|
||||
{OpenProfile 0 FilePath Nil 1 0 0 0 0 1 Briefcase "open_profile" "Open Profile" "Opens a profile file path, immediately loading it, and begins autosaving to it." "profile,project,session" }
|
||||
|
||||
//- rjf: loading/applying stateful config changes
|
||||
{ApplyUserData 1 Null Nil 0 0 0 0 0 0 Null "apply_user_data" "Apply User Data" "Applies user data from the active user file." "" }
|
||||
{ApplyProfileData 1 Null Nil 0 0 0 0 0 0 Null "apply_profile_data" "Apply Profile Data" "Applies profile data from the active profile file." "" }
|
||||
{ApplyUserData 1 Null Nil 0 0 0 0 0 0 Null "apply_user_data" "Apply User Data" "Applies user data from the active user file." "" }
|
||||
{ApplyProfileData 1 Null Nil 0 0 0 0 0 0 Null "apply_profile_data" "Apply Profile Data" "Applies profile data from the active profile file." "" }
|
||||
|
||||
//- rjf: writing config changes
|
||||
{WriteUserData 1 Null Nil 0 0 0 0 0 0 Null "write_user_data" "Write User Data" "Writes user data to the active user file." "" }
|
||||
{WriteProfileData 1 Null Nil 0 0 0 0 0 0 Null "write_profile_data" "Write Profile Data" "Writes profile data to the active profile file." "" }
|
||||
{WriteUserData 1 Null Nil 0 0 0 0 0 0 Null "write_user_data" "Write User Data" "Writes user data to the active user file." "" }
|
||||
{WriteProfileData 1 Null Nil 0 0 0 0 0 0 Null "write_profile_data" "Write Profile Data" "Writes profile data to the active profile file." "" }
|
||||
|
||||
//- rjf: directional movement & text controls
|
||||
{MoveLeft 0 Null Nil 0 0 0 0 0 0 Null "move_left" "Move Left" "Moves the cursor or selection left." "" }
|
||||
{MoveRight 0 Null Nil 0 0 0 0 0 0 Null "move_right" "Move Right" "Moves the cursor or selection right." "" }
|
||||
{MoveUp 0 Null Nil 0 0 0 0 0 0 Null "move_up" "Move Up" "Moves the cursor or selection up." "" }
|
||||
{MoveDown 0 Null Nil 0 0 0 0 0 0 Null "move_down" "Move Down" "Moves the cursor or selection down." "" }
|
||||
{MoveLeftSelect 0 Null Nil 0 0 0 0 0 0 Null "move_left_select" "Move Left Select" "Moves the cursor or selection left, while selecting." "" }
|
||||
{MoveRightSelect 0 Null Nil 0 0 0 0 0 0 Null "move_right_select" "Move Right Select" "Moves the cursor or selection right, while selecting." "" }
|
||||
{MoveUpSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_select" "Move Up Select" "Moves the cursor or selection up, while selecting." "" }
|
||||
{MoveDownSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_select" "Move Down Select" "Moves the cursor or selection down, while selecting." "" }
|
||||
{MoveLeftChunk 0 Null Nil 0 0 0 0 0 0 Null "move_left_chunk" "Move Left Select" "Moves the cursor or selection left one chunk." "" }
|
||||
{MoveRightChunk 0 Null Nil 0 0 0 0 0 0 Null "move_right_chunk" "Move Right Select" "Moves the cursor or selection right one chunk." "" }
|
||||
{MoveUpChunk 0 Null Nil 0 0 0 0 0 0 Null "move_up_chunk" "Move Up Chunk" "Moves the cursor or selection up one chunk." "" }
|
||||
{MoveDownChunk 0 Null Nil 0 0 0 0 0 0 Null "move_down_chunk" "Move Down Chunk" "Moves the cursor or selection down one chunk." "" }
|
||||
{MoveUpPage 0 Null Nil 0 0 0 0 0 0 Null "move_up_page" "Move Up Page" "Moves the cursor or selection up one page." "" }
|
||||
{MoveDownPage 0 Null Nil 0 0 0 0 0 0 Null "move_down_page" "Move Down Page" "Moves the cursor or selection down one page." "" }
|
||||
{MoveUpWhole 0 Null Nil 0 0 0 0 0 0 Null "move_up_whole" "Move Up Whole" "Moves the cursor or selection to the beginning of the relevant content." "" }
|
||||
{MoveDownWhole 0 Null Nil 0 0 0 0 0 0 Null "move_down_whole" "Move Down Whole" "Moves the cursor or selection to the end of the relevant content." "" }
|
||||
{MoveLeftChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_left_chunk_select" "Move Left Chunk Select" "Moves the cursor or selection left one chunk." "" }
|
||||
{MoveRightChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_right_chunk_select" "Move Right Chunk Select" "Moves the cursor or selection right one chunk." "" }
|
||||
{MoveUpChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_chunk_select" "Move Up Chunk Select" "Moves the cursor or selection up one chunk." "" }
|
||||
{MoveDownChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_chunk_select" "Move Down Chunk Select" "Moves the cursor or selection down one chunk." "" }
|
||||
{MoveUpPageSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_page_select" "Move Up Page Select" "Moves the cursor or selection up one page, while selecting." "" }
|
||||
{MoveDownPageSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_page_select" "Move Down Page Select" "Moves the cursor or selection down one page, while selecting." "" }
|
||||
{MoveUpWholeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_whole_select" "Move Up Whole Select" "Moves the cursor or selection to the beginning of the relevant content, while selecting." "" }
|
||||
{MoveDownWholeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_whole_select" "Move Down Whole Select" "Moves the cursor or selection to the end of the relevant content, while selecting." "" }
|
||||
{MoveHome 0 Null Nil 0 0 0 0 0 0 Null "move_home" "Move Home" "Moves the cursor to the beginning of the line." "" }
|
||||
{MoveEnd 0 Null Nil 0 0 0 0 0 0 Null "move_end" "Move End" "Moves the cursor to the end of the line." "" }
|
||||
{MoveHomeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_home_select" "Move Home Select" "Moves the cursor to the beginning of the line, while selecting." "" }
|
||||
{MoveEndSelect 0 Null Nil 0 0 0 0 0 0 Null "move_end_select" "Move End Select" "Moves the cursor to the end of the line, while selecting." "" }
|
||||
{SelectAll 0 Null Nil 0 0 0 0 0 0 Null "select_all" "Select All" "Selects everything possible." "" }
|
||||
{DeleteSingle 0 Null Nil 0 0 0 0 0 0 Null "delete_single" "Delete Single" "Deletes a single element to the right of the cursor, or the active selection." "" }
|
||||
{DeleteChunk 0 Null Nil 0 0 0 0 0 0 Null "delete_chunk" "Delete Chunk" "Deletes a chunk to the right of the cursor, or the active selection." "" }
|
||||
{BackspaceSingle 0 Null Nil 0 0 0 0 0 0 Null "backspace_single" "Backspace Single" "Deletes a single element to the left of the cursor, or the active selection." "" }
|
||||
{BackspaceChunk 0 Null Nil 0 0 0 0 0 0 Null "backspace_chunk" "Backspace Chunk" "Deletes a chunk to the left of the cursor, or the active selection." "" }
|
||||
{Copy 0 Null Nil 0 0 0 0 0 0 Clipboard "copy" "Copy" "Copies the active selection to the clipboard." "" }
|
||||
{Cut 0 Null Nil 0 0 0 0 0 0 Clipboard "cut" "Cut" "Copies the active selection to the clipboard, then deletes it." "" }
|
||||
{Paste 0 Null Nil 0 0 0 0 0 0 Clipboard "paste" "Paste" "Pastes the current contents of the clipboard." "" }
|
||||
{InsertText 1 Null Nil 0 0 0 0 0 0 Null "insert_text" "Insert Text" "Inserts the text that was used to cause this command." "" }
|
||||
{MoveLeft 0 Null Nil 0 0 0 0 0 0 Null "move_left" "Move Left" "Moves the cursor or selection left." "" }
|
||||
{MoveRight 0 Null Nil 0 0 0 0 0 0 Null "move_right" "Move Right" "Moves the cursor or selection right." "" }
|
||||
{MoveUp 0 Null Nil 0 0 0 0 0 0 Null "move_up" "Move Up" "Moves the cursor or selection up." "" }
|
||||
{MoveDown 0 Null Nil 0 0 0 0 0 0 Null "move_down" "Move Down" "Moves the cursor or selection down." "" }
|
||||
{MoveLeftSelect 0 Null Nil 0 0 0 0 0 0 Null "move_left_select" "Move Left Select" "Moves the cursor or selection left, while selecting." "" }
|
||||
{MoveRightSelect 0 Null Nil 0 0 0 0 0 0 Null "move_right_select" "Move Right Select" "Moves the cursor or selection right, while selecting." "" }
|
||||
{MoveUpSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_select" "Move Up Select" "Moves the cursor or selection up, while selecting." "" }
|
||||
{MoveDownSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_select" "Move Down Select" "Moves the cursor or selection down, while selecting." "" }
|
||||
{MoveLeftChunk 0 Null Nil 0 0 0 0 0 0 Null "move_left_chunk" "Move Left Select" "Moves the cursor or selection left one chunk." "" }
|
||||
{MoveRightChunk 0 Null Nil 0 0 0 0 0 0 Null "move_right_chunk" "Move Right Select" "Moves the cursor or selection right one chunk." "" }
|
||||
{MoveUpChunk 0 Null Nil 0 0 0 0 0 0 Null "move_up_chunk" "Move Up Chunk" "Moves the cursor or selection up one chunk." "" }
|
||||
{MoveDownChunk 0 Null Nil 0 0 0 0 0 0 Null "move_down_chunk" "Move Down Chunk" "Moves the cursor or selection down one chunk." "" }
|
||||
{MoveUpPage 0 Null Nil 0 0 0 0 0 0 Null "move_up_page" "Move Up Page" "Moves the cursor or selection up one page." "" }
|
||||
{MoveDownPage 0 Null Nil 0 0 0 0 0 0 Null "move_down_page" "Move Down Page" "Moves the cursor or selection down one page." "" }
|
||||
{MoveUpWhole 0 Null Nil 0 0 0 0 0 0 Null "move_up_whole" "Move Up Whole" "Moves the cursor or selection to the beginning of the relevant content." "" }
|
||||
{MoveDownWhole 0 Null Nil 0 0 0 0 0 0 Null "move_down_whole" "Move Down Whole" "Moves the cursor or selection to the end of the relevant content." "" }
|
||||
{MoveLeftChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_left_chunk_select" "Move Left Chunk Select" "Moves the cursor or selection left one chunk." "" }
|
||||
{MoveRightChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_right_chunk_select" "Move Right Chunk Select" "Moves the cursor or selection right one chunk." "" }
|
||||
{MoveUpChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_chunk_select" "Move Up Chunk Select" "Moves the cursor or selection up one chunk." "" }
|
||||
{MoveDownChunkSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_chunk_select" "Move Down Chunk Select" "Moves the cursor or selection down one chunk." "" }
|
||||
{MoveUpPageSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_page_select" "Move Up Page Select" "Moves the cursor or selection up one page, while selecting." "" }
|
||||
{MoveDownPageSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_page_select" "Move Down Page Select" "Moves the cursor or selection down one page, while selecting." "" }
|
||||
{MoveUpWholeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_up_whole_select" "Move Up Whole Select" "Moves the cursor or selection to the beginning of the relevant content, while selecting." "" }
|
||||
{MoveDownWholeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_down_whole_select" "Move Down Whole Select" "Moves the cursor or selection to the end of the relevant content, while selecting." "" }
|
||||
{MoveHome 0 Null Nil 0 0 0 0 0 0 Null "move_home" "Move Home" "Moves the cursor to the beginning of the line." "" }
|
||||
{MoveEnd 0 Null Nil 0 0 0 0 0 0 Null "move_end" "Move End" "Moves the cursor to the end of the line." "" }
|
||||
{MoveHomeSelect 0 Null Nil 0 0 0 0 0 0 Null "move_home_select" "Move Home Select" "Moves the cursor to the beginning of the line, while selecting." "" }
|
||||
{MoveEndSelect 0 Null Nil 0 0 0 0 0 0 Null "move_end_select" "Move End Select" "Moves the cursor to the end of the line, while selecting." "" }
|
||||
{SelectAll 0 Null Nil 0 0 0 0 0 0 Null "select_all" "Select All" "Selects everything possible." "" }
|
||||
{DeleteSingle 0 Null Nil 0 0 0 0 0 0 Null "delete_single" "Delete Single" "Deletes a single element to the right of the cursor, or the active selection." "" }
|
||||
{DeleteChunk 0 Null Nil 0 0 0 0 0 0 Null "delete_chunk" "Delete Chunk" "Deletes a chunk to the right of the cursor, or the active selection." "" }
|
||||
{BackspaceSingle 0 Null Nil 0 0 0 0 0 0 Null "backspace_single" "Backspace Single" "Deletes a single element to the left of the cursor, or the active selection." "" }
|
||||
{BackspaceChunk 0 Null Nil 0 0 0 0 0 0 Null "backspace_chunk" "Backspace Chunk" "Deletes a chunk to the left of the cursor, or the active selection." "" }
|
||||
{Copy 0 Null Nil 0 0 0 0 0 0 Clipboard "copy" "Copy" "Copies the active selection to the clipboard." "" }
|
||||
{Cut 0 Null Nil 0 0 0 0 0 0 Clipboard "cut" "Cut" "Copies the active selection to the clipboard, then deletes it." "" }
|
||||
{Paste 0 Null Nil 0 0 0 0 0 0 Clipboard "paste" "Paste" "Pastes the current contents of the clipboard." "" }
|
||||
{InsertText 1 Null Nil 0 0 0 0 0 0 Null "insert_text" "Insert Text" "Inserts the text that was used to cause this command." "" }
|
||||
|
||||
//- rjf: code navigation
|
||||
{GoToLine 0 TextPoint Nil 0 0 0 0 1 1 Null "goto_line" "Go To Line" "Jumps to a line number in the current code file." "" }
|
||||
{GoToAddress 0 VirtualAddr Nil 0 0 0 0 1 1 Null "goto_address" "Go To Address" "Jumps to an address in the current memory or disassembly view." "" }
|
||||
{CenterCursor 0 Null Nil 0 0 0 0 0 0 Null "center_cursor" "Center Cursor" "Snaps the current code view to center the cursor." "" }
|
||||
{ContainCursor 0 Null Nil 0 0 0 0 0 0 Null "contain_cursor" "Contain Cursor" "Snaps the current code view to contain the cursor." "" }
|
||||
{FindTextForward 0 String Nil 0 0 1 1 1 1 Find "find_text_forward" "Find Text (Forward)" "Searches the current code file forward (from the cursor) for a string." "" }
|
||||
{FindTextBackward 0 String Nil 0 0 1 1 1 1 Find "find_text_backward" "Find Text (Backwards)" "Searches the current code file backwards (from the cursor) for a string." "" }
|
||||
{FindNext 0 Null Nil 0 0 1 0 0 0 Find "find_next" "Find Next" "Searches the current code file forward (from the cursor) for the last searched string." "" }
|
||||
{FindPrev 0 Null Nil 0 0 1 0 0 0 Find "find_prev" "Find Previous" "Searches the current code file backwards (from the cursor) for the last searched string." "" }
|
||||
{GoToLine 0 TextPoint Nil 0 0 0 0 1 1 Null "goto_line" "Go To Line" "Jumps to a line number in the current code file." "" }
|
||||
{GoToAddress 0 VirtualAddr Nil 0 0 0 0 1 1 Null "goto_address" "Go To Address" "Jumps to an address in the current memory or disassembly view." "" }
|
||||
{CenterCursor 0 Null Nil 0 0 0 0 0 0 Null "center_cursor" "Center Cursor" "Snaps the current code view to center the cursor." "" }
|
||||
{ContainCursor 0 Null Nil 0 0 0 0 0 0 Null "contain_cursor" "Contain Cursor" "Snaps the current code view to contain the cursor." "" }
|
||||
{FindTextForward 0 String Nil 0 0 1 1 1 1 Find "find_text_forward" "Find Text (Forward)" "Searches the current code file forward (from the cursor) for a string." "" }
|
||||
{FindTextBackward 0 String Nil 0 0 1 1 1 1 Find "find_text_backward" "Find Text (Backwards)" "Searches the current code file backwards (from the cursor) for a string." "" }
|
||||
{FindNext 0 Null Nil 0 0 1 0 0 0 Find "find_next" "Find Next" "Searches the current code file forward (from the cursor) for the last searched string." "" }
|
||||
{FindPrev 0 Null Nil 0 0 1 0 0 0 Find "find_prev" "Find Previous" "Searches the current code file backwards (from the cursor) for the last searched string." "" }
|
||||
|
||||
//- rjf: thread finding
|
||||
{FindThread 0 Entity Thread 0 0 0 0 0 1 Find "find_thread" "Find Thread" "Jumps to the passed thread in either source code, disassembly, or both if they're already open." "" }
|
||||
{FindSelectedThread 0 Null Nil 0 0 0 0 0 0 Find "find_selected_thread" "Find Selected Thread" "Jumps to the selected thread in either source code, disassembly, or both if they're already open." "" }
|
||||
{FindThread 0 Entity Thread 0 0 0 0 0 1 Find "find_thread" "Find Thread" "Jumps to the passed thread in either source code, disassembly, or both if they're already open." "" }
|
||||
{FindSelectedThread 0 Null Nil 0 0 0 0 0 0 Find "find_selected_thread" "Find Selected Thread" "Jumps to the selected thread in either source code, disassembly, or both if they're already open." "" }
|
||||
|
||||
//- rjf: name finding
|
||||
{GoToName 0 String Nil 0 0 0 0 1 1 Null "goto_name" "Go To Name" "Searches for the passed string as a file, a symbol in debug info, and more, then jumps to it if possible." "" }
|
||||
{GoToNameAtCursor 0 Null Nil 0 0 0 0 0 0 Null "goto_name_at_cursor" "Go To Name At Cursor" "Searches for the text at the cursor as a file, a symbol in debug info, and more, then jumps to it if possible." "" }
|
||||
{GoToName 0 String Nil 0 0 0 0 1 1 Null "goto_name" "Go To Name" "Searches for the passed string as a file, a symbol in debug info, and more, then jumps to it if possible." "" }
|
||||
{GoToNameAtCursor 0 Null Nil 0 0 0 0 0 0 Null "goto_name_at_cursor" "Go To Name At Cursor" "Searches for the text at the cursor as a file, a symbol in debug info, and more, then jumps to it if possible." "" }
|
||||
|
||||
//- rjf: watch expressions
|
||||
{ToggleWatchExpression 0 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_expr" "Toggle Watch Expression" "Adds or removes an expression to an opened watch view." "" }
|
||||
{ToggleWatchExpressionAtCursor 0 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_expr_at_cursor" "Toggle Watch Expression At Cursor" "Adds or removes the expression that the cursor or selection is currently over to an opened watch view." "" }
|
||||
{ToggleWatchExpression 0 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_expr" "Toggle Watch Expression" "Adds or removes an expression to an opened watch view." "" }
|
||||
{ToggleWatchExpressionAtCursor 0 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_expr_at_cursor" "Toggle Watch Expression At Cursor" "Adds or removes the expression that the cursor or selection is currently over to an opened watch view." "" }
|
||||
|
||||
//- rjf: memory view parameterization
|
||||
{SetColumns 0 Index Nil 0 0 0 0 1 1 Thumbnails "set_columns" "Set Columns" "Sets the number of columns for a memory view." "" }
|
||||
{SetColumns 0 Index Nil 0 0 0 0 1 1 Thumbnails "set_columns" "Set Columns" "Sets the number of columns for a memory view." "" }
|
||||
|
||||
//- rjf: disassembly view parameterization
|
||||
{ToggleAddressVisibility 0 Null Nil 0 0 0 0 0 0 Thumbnails "toggle_address_visibility" "Toggle Address Visibility" "Toggles the visibility of addresses in a disassembly view." "" }
|
||||
{ToggleCodeBytesVisibility 0 Null Nil 0 0 0 0 0 0 Thumbnails "toggle_code_bytes_visibility""Toggle Code Bytes Visibility" "Toggles the visibility of machine code bytes in a disassembly view." "" }
|
||||
{ToggleAddressVisibility 0 Null Nil 0 0 0 0 0 0 Thumbnails "toggle_address_visibility" "Toggle Address Visibility" "Toggles the visibility of addresses in a disassembly view." "" }
|
||||
{ToggleCodeBytesVisibility 0 Null Nil 0 0 0 0 0 0 Thumbnails "toggle_code_bytes_visibility""Toggle Code Bytes Visibility" "Toggles the visibility of machine code bytes in a disassembly view." "" }
|
||||
|
||||
//- rjf: general entity operations
|
||||
{EnableEntity 1 Null Nil 0 0 0 0 0 0 Null "enable_entity" "Enable Entity" "Enables an entity." "" }
|
||||
{DisableEntity 1 Null Nil 0 0 0 0 0 0 Null "disable_entity" "Disable Entity" "Disables an entity." "" }
|
||||
{FreezeEntity 1 Null Nil 0 0 0 0 0 0 Null "freeze_entity" "Freeze Entity" "Freezes an entity." "" }
|
||||
{ThawEntity 1 Null Nil 0 0 0 0 0 0 Null "thaw_entity" "Thaw Entity" "Thaws an entity." "" }
|
||||
{RemoveEntity 1 Null Nil 0 0 0 0 0 0 Null "remove_entity" "Remove Entity" "Removes an entity." "" }
|
||||
{NameEntity 1 Null Nil 0 0 0 0 0 0 Null "name_entity" "Name Entity" "Equips an entity with a name." "" }
|
||||
{EditEntity 1 Null Nil 0 0 0 0 0 0 Null "edit_entity" "Edit Entity" "Opens the editor for an entity." "" }
|
||||
{DuplicateEntity 1 Null Nil 0 0 0 0 0 0 Null "duplicate_entity" "Duplicate Entity" "Duplicates an entity." "" }
|
||||
{EnableEntity 1 Null Nil 0 0 0 0 0 0 Null "enable_entity" "Enable Entity" "Enables an entity." "" }
|
||||
{DisableEntity 1 Null Nil 0 0 0 0 0 0 Null "disable_entity" "Disable Entity" "Disables an entity." "" }
|
||||
{FreezeEntity 1 Null Nil 0 0 0 0 0 0 Null "freeze_entity" "Freeze Entity" "Freezes an entity." "" }
|
||||
{ThawEntity 1 Null Nil 0 0 0 0 0 0 Null "thaw_entity" "Thaw Entity" "Thaws an entity." "" }
|
||||
{RemoveEntity 1 Null Nil 0 0 0 0 0 0 Null "remove_entity" "Remove Entity" "Removes an entity." "" }
|
||||
{NameEntity 1 Null Nil 0 0 0 0 0 0 Null "name_entity" "Name Entity" "Equips an entity with a name." "" }
|
||||
{EditEntity 1 Null Nil 0 0 0 0 0 0 Null "edit_entity" "Edit Entity" "Opens the editor for an entity." "" }
|
||||
{DuplicateEntity 1 Null Nil 0 0 0 0 0 0 Null "duplicate_entity" "Duplicate Entity" "Duplicates an entity." "" }
|
||||
|
||||
//- rjf: breakpoints
|
||||
{TextBreakpoint 1 Null Nil 0 0 0 0 0 0 CircleFilled "text_breakpoint" "Text Breakpoint" "Places or removes a breakpoint on the specified line of source code." "" }
|
||||
{AddressBreakpoint 0 VirtualAddr Nil 0 0 0 0 1 1 CircleFilled "address_breakpoint" "Address Breakpoint" "Places or removes a breakpoint on the specified address." "" }
|
||||
{FunctionBreakpoint 0 String Nil 0 0 0 0 1 1 CircleFilled "function_breakpoint" "Function Breakpoint" "Places or removes a breakpoint on the first address(es) of the specified function." "" }
|
||||
{ToggleBreakpointAtCursor 0 Null Nil 0 0 0 0 0 0 CircleFilled "toggle_breakpoint_cursor" "Toggle Breakpoint At Cursor" "Places or removes a breakpoint on the line on which the active cursor sits." "" }
|
||||
{RemoveBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 Trash "remove_breakpoint" "Remove Breakpoint" "Removes an existing breakpoint." "" }
|
||||
{EnableBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 CheckFilled "enable_breakpoint" "Enable Breakpoint" "Enables a breakpoint." "" }
|
||||
{DisableBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 CheckHollow "disable_breakpoint" "Disable Breakpoint" "Disables a breakpoint." "" }
|
||||
{TextBreakpoint 1 Null Nil 0 0 0 0 0 0 CircleFilled "text_breakpoint" "Text Breakpoint" "Places or removes a breakpoint on the specified line of source code." "" }
|
||||
{AddressBreakpoint 0 VirtualAddr Nil 0 0 0 0 1 1 CircleFilled "address_breakpoint" "Address Breakpoint" "Places or removes a breakpoint on the specified address." "" }
|
||||
{FunctionBreakpoint 0 String Nil 0 0 0 0 1 1 CircleFilled "function_breakpoint" "Function Breakpoint" "Places or removes a breakpoint on the first address(es) of the specified function." "" }
|
||||
{ToggleBreakpointAtCursor 0 Null Nil 0 0 0 0 0 0 CircleFilled "toggle_breakpoint_cursor" "Toggle Breakpoint At Cursor" "Places or removes a breakpoint on the line on which the active cursor sits." "" }
|
||||
{RemoveBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 Trash "remove_breakpoint" "Remove Breakpoint" "Removes an existing breakpoint." "" }
|
||||
{EnableBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 CheckFilled "enable_breakpoint" "Enable Breakpoint" "Enables a breakpoint." "" }
|
||||
{DisableBreakpoint 0 Entity Breakpoint 0 0 0 0 0 1 CheckHollow "disable_breakpoint" "Disable Breakpoint" "Disables a breakpoint." "" }
|
||||
|
||||
//- rjf: watches
|
||||
{ToggleWatchPin 1 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_pin" "Toggle Watch Pin" "Places or removes a watch pin on a textual location on a particular entity." "" }
|
||||
{ToggleWatchPinAtCursor 0 String Nil 0 0 0 0 1 1 Binoculars "toggle_watch_pin_at_cursor" "Toggle Watch Pin At Cursor" "Places or removes a watch pin at the cursor on the currently active file." "" }
|
||||
{ToggleWatchPin 1 Null Nil 0 0 0 0 0 0 Binoculars "toggle_watch_pin" "Toggle Watch Pin" "Places or removes a watch pin on a textual location on a particular entity." "" }
|
||||
{ToggleWatchPinAtCursor 0 String Nil 0 0 0 0 1 1 Binoculars "toggle_watch_pin_at_cursor" "Toggle Watch Pin At Cursor" "Places or removes a watch pin at the cursor on the currently active file." "" }
|
||||
|
||||
//- rjf: targets
|
||||
{AddTarget 0 FilePath Nil 1 0 0 0 0 1 Target "add_target" "Add Target" "Adds a new target." "application,executable,debug" }
|
||||
{RemoveTarget 0 Entity Target 0 0 0 0 0 1 Trash "remove_target" "Remove Target" "Removes an existing target." "delete,remove,target" }
|
||||
{EditTarget 0 Entity Target 0 0 0 0 0 1 Pencil "edit_target" "Edit Target" "Edits an existing target." "" }
|
||||
{AddTarget 0 FilePath Nil 1 0 0 0 0 1 Target "add_target" "Add Target" "Adds a new target." "application,executable,debug" }
|
||||
{RemoveTarget 0 Entity Target 0 0 0 0 0 1 Trash "remove_target" "Remove Target" "Removes an existing target." "delete,remove,target" }
|
||||
{EditTarget 0 Entity Target 0 0 0 0 0 1 Pencil "edit_target" "Edit Target" "Edits an existing target." "" }
|
||||
{SelectTarget 0 Entity Target 0 0 0 0 0 1 Target "select_target" "Select Target" "Selects a target." "" }
|
||||
{EnableTarget 0 Entity Target 0 0 0 0 0 1 CheckFilled "enable_target" "Enable Target" "Enables a target, in addition to all targets currently enabled." "" }
|
||||
{DisableTarget 0 Entity Target 0 0 0 0 0 1 CheckHollow "disable_target" "Disable Target" "Disables a target." "" }
|
||||
|
||||
//- rjf: ended processes
|
||||
{RetryEndedProcess 1 Entity Process 0 0 0 0 0 0 Null "retry_ended_process" "Retry Ended Process" "Launches a new process with the same options as the passed ended process." "" }
|
||||
{RetryEndedProcess 1 Entity Process 0 0 0 0 0 0 Null "retry_ended_process" "Retry Ended Process" "Launches a new process with the same options as the passed ended process." "" }
|
||||
|
||||
//- rjf: attaching
|
||||
{Attach 0 ID Nil 0 0 0 0 1 1 Null "attach" "Attach" "Attaches to a process that is already running on the local machine." "" }
|
||||
{RegisterAsJITDebugger 0 Null Nil 0 0 0 0 0 0 Null "register_as_jit_debugger" "Register As Just-In-Time (JIT) Debugger" "Registers the RAD debugger as the just-in-time (JIT) debugger used by the operating system." "" }
|
||||
{Attach 0 ID Nil 0 0 0 0 0 1 Null "attach" "Attach" "Attaches to a process that is already running on the local machine." "" }
|
||||
{RegisterAsJITDebugger 0 Null Nil 0 0 0 0 0 0 Null "register_as_jit_debugger" "Register As Just-In-Time (JIT) Debugger" "Registers the RAD debugger as the just-in-time (JIT) debugger used by the operating system." "" }
|
||||
|
||||
//- rjf: catchall general entity activation paths (drag/drop, clicking)
|
||||
{EntityRefFastPath 1 Null Nil 0 0 0 0 0 0 Null "entity_ref_fast_path" "Entity Reference Fast Path" "Activates the default behavior when clicking an entity reference." "" }
|
||||
{SpawnEntityView 1 Null Nil 0 0 0 0 0 0 Null "spawn_entity_view" "Spawn Entity View" "Spawns a new view, given an entity and other parameterizations." "" }
|
||||
{FindCodeLocation 1 FilePath Nil 0 0 0 0 0 1 FileOutline "find_code_location" "Find Code Location" "Finds a specific source code location given file, line, and column coordinates. Opens the file if necessary." "" }
|
||||
{EntityRefFastPath 1 Null Nil 0 0 0 0 0 0 Null "entity_ref_fast_path" "Entity Reference Fast Path" "Activates the default behavior when clicking an entity reference." "" }
|
||||
{SpawnEntityView 1 Null Nil 0 0 0 0 0 0 Null "spawn_entity_view" "Spawn Entity View" "Spawns a new view, given an entity and other parameterizations." "" }
|
||||
{FindCodeLocation 1 FilePath Nil 0 0 0 0 0 1 FileOutline "find_code_location" "Find Code Location" "Finds a specific source code location given file, line, and column coordinates. Opens the file if necessary." "" }
|
||||
|
||||
//- rjf: view drivers
|
||||
{Commands 0 Null Nil 0 0 0 0 0 0 List "commands" "Commands" "Opens the list of all commands." "" }
|
||||
{Target 1 Null Nil 0 0 0 0 0 0 Target "target" "Target" "Opens the editor for a target." "" }
|
||||
{Targets 0 Null Nil 0 0 0 0 0 0 Target "targets" "Targets" "Opens the list of all targets." "" }
|
||||
{FilePathMap 0 Null Nil 0 0 0 0 0 0 FileOutline "file_path_map" "File Path Map" "Opens the file path mapping editor." "" }
|
||||
{Scheduler 0 Null Nil 0 0 0 0 0 0 Scheduler "scheduler" "Scheduler" "Opens the scheduler view, for process and thread controls." "" }
|
||||
{CallStack 0 Null Nil 0 0 0 0 0 0 Thread "call_stack" "Call Stack" "Opens the call stack view." "callstack,thread" }
|
||||
{Modules 0 Null Nil 0 0 0 0 0 0 Module "modules" "Modules" "Opens the modules view." "" }
|
||||
{PendingEntity 1 Null Nil 0 0 0 0 0 0 FileOutline "pending_entity" "Pending Entity" "Opens a view which waits for the passed entity to be completely loaded, then replaces itself with a new view." "" }
|
||||
{Code 1 Null Nil 0 0 0 0 0 0 FileOutline "code" "Code" "Opens the code view for an already-loaded file." "" }
|
||||
{Watch 0 Null Nil 0 0 0 0 0 0 Binoculars "watch" "Watch" "Opens a watch view." "" }
|
||||
{Locals 0 Null Nil 0 0 0 0 0 0 Binoculars "locals" "Locals" "Opens a locals view." "" }
|
||||
{Registers 0 Null Nil 0 0 0 0 0 0 Binoculars "registers" "Registers" "Opens a registers view for the currently selected thread." "" }
|
||||
{Output 0 Null Nil 0 0 0 0 0 0 List "output" "Output" "Opens an output view." "" }
|
||||
{Memory 0 Null Nil 0 0 0 0 0 0 Grid "memory" "Memory" "Opens a memory view." "" }
|
||||
{Disassembly 0 Null Nil 0 0 0 0 0 0 Glasses "disassembly" "Disassembly" "Opens the disassembly view." "disasm" }
|
||||
{Breakpoints 0 Null Nil 0 0 0 0 0 0 CircleFilled "breakpoints" "Breakpoints" "Opens the breakpoints view." "" }
|
||||
{WatchPins 0 Null Nil 0 0 0 0 0 0 Pin "watch_pins" "Watch Pins" "Opens the watch pins view." "" }
|
||||
{ExceptionFilters 0 Null Nil 0 0 0 0 0 0 Gear "exception_filters" "Exception Filters" "Opens the exception filters view." "exceptions,filters" }
|
||||
{Theme 0 Null Nil 0 0 0 0 0 0 Palette "theme" "Theme" "Opens the theme view." "theme,color,scheme,palette" }
|
||||
{PickFile 1 FilePath Nil 1 0 0 0 0 1 FileOutline "pick_file" "Pick File" "Opens the file browser to pick a file." "" }
|
||||
{PickFolder 1 FilePath Nil 0 1 0 0 0 1 FolderOpenFilled "pick_folder" "Pick Folder" "Opens the file browser to pick a folder." "" }
|
||||
{PickFileOrFolder 1 FilePath Nil 1 1 0 0 0 1 FileOutline "pick_file_or_folder" "Pick File/Folder" "Opens the file browser to pick a file or folder." "" }
|
||||
{Commands 0 Null Nil 0 0 0 0 0 0 List "commands" "Commands" "Opens the list of all commands." "" }
|
||||
{Target 1 Null Nil 0 0 0 0 0 0 Target "target" "Target" "Opens the editor for a target." "" }
|
||||
{Targets 0 Null Nil 0 0 0 0 0 0 Target "targets" "Targets" "Opens the list of all targets." "" }
|
||||
{FilePathMap 0 Null Nil 0 0 0 0 0 0 FileOutline "file_path_map" "File Path Map" "Opens the file path mapping editor." "" }
|
||||
{Scheduler 0 Null Nil 0 0 0 0 0 0 Scheduler "scheduler" "Scheduler" "Opens the scheduler view, for process and thread controls." "" }
|
||||
{CallStack 0 Null Nil 0 0 0 0 0 0 Thread "call_stack" "Call Stack" "Opens the call stack view." "callstack,thread" }
|
||||
{Modules 0 Null Nil 0 0 0 0 0 0 Module "modules" "Modules" "Opens the modules view." "" }
|
||||
{PendingEntity 1 Null Nil 0 0 0 0 0 0 FileOutline "pending_entity" "Pending Entity" "Opens a view which waits for the passed entity to be completely loaded, then replaces itself with a new view." "" }
|
||||
{Code 1 Null Nil 0 0 0 0 0 0 FileOutline "code" "Code" "Opens the code view for an already-loaded file." "" }
|
||||
{Watch 0 Null Nil 0 0 0 0 0 0 Binoculars "watch" "Watch" "Opens a watch view." "" }
|
||||
{Locals 0 Null Nil 0 0 0 0 0 0 Binoculars "locals" "Locals" "Opens a locals view." "" }
|
||||
{Registers 0 Null Nil 0 0 0 0 0 0 Binoculars "registers" "Registers" "Opens a registers view for the currently selected thread." "" }
|
||||
{Output 0 Null Nil 0 0 0 0 0 0 List "output" "Output" "Opens an output view." "" }
|
||||
{Memory 0 Null Nil 0 0 0 0 0 0 Grid "memory" "Memory" "Opens a memory view." "" }
|
||||
{Disassembly 0 Null Nil 0 0 0 0 0 0 Glasses "disassembly" "Disassembly" "Opens the disassembly view." "disasm" }
|
||||
{Breakpoints 0 Null Nil 0 0 0 0 0 0 CircleFilled "breakpoints" "Breakpoints" "Opens the breakpoints view." "" }
|
||||
{WatchPins 0 Null Nil 0 0 0 0 0 0 Pin "watch_pins" "Watch Pins" "Opens the watch pins view." "" }
|
||||
{ExceptionFilters 0 Null Nil 0 0 0 0 0 0 Gear "exception_filters" "Exception Filters" "Opens the exception filters view." "exceptions,filters" }
|
||||
{Theme 0 Null Nil 0 0 0 0 0 0 Palette "theme" "Theme" "Opens the theme view." "theme,color,scheme,palette" }
|
||||
{PickFile 1 FilePath Nil 1 0 0 0 0 1 FileOutline "pick_file" "Pick File" "Opens the file browser to pick a file." "" }
|
||||
{PickFolder 1 FilePath Nil 0 1 0 0 0 1 FolderOpenFilled "pick_folder" "Pick Folder" "Opens the file browser to pick a folder." "" }
|
||||
{PickFileOrFolder 1 FilePath Nil 1 1 0 0 0 1 FileOutline "pick_file_or_folder" "Pick File/Folder" "Opens the file browser to pick a file or folder." "" }
|
||||
|
||||
//- rjf: query completion
|
||||
{CompleteQuery 1 Null Nil 0 0 0 0 0 0 Null "complete_query" "Complete Query" "Completes a query." "" }
|
||||
{CancelQuery 1 Null Nil 0 0 0 0 0 0 Null "cancel_query" "Cancel Query" "Cancels a query." "" }
|
||||
{CompleteQuery 1 Null Nil 0 0 0 0 0 0 Null "complete_query" "Complete Query" "Completes a query." "" }
|
||||
{CancelQuery 1 Null Nil 0 0 0 0 0 0 Null "cancel_query" "Cancel Query" "Cancels a query." "" }
|
||||
|
||||
//- rjf: developer commands
|
||||
{ToggleDevMenu 0 Null Nil 0 0 0 0 0 0 Null "toggle_dev_menu" "Toggle Developer Menu" "Opens and closes the developer menu." "" }
|
||||
{ToggleDevMenu 0 Null Nil 0 0 0 0 0 0 Null "toggle_dev_menu" "Toggle Developer Menu" "Opens and closes the developer menu." "" }
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
|
||||
@@ -20,10 +20,11 @@ DF_CmdSpecInfo df_g_core_cmd_kind_spec_info_table[] =
|
||||
{ str8_lit_comp("step_into_line"), str8_lit_comp("Performs a step that goes into calls, at the source code line level."), str8_lit_comp("step,thread"), str8_lit_comp("Step Into (Line)"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_StepInto},
|
||||
{ str8_lit_comp("step_over_line"), str8_lit_comp("Performs a step that skips calls, at the source code line level."), str8_lit_comp("step,thread"), str8_lit_comp("Step Over (Line)"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_StepOver},
|
||||
{ str8_lit_comp("step_out"), str8_lit_comp("Runs to the end of the current function and exits it."), str8_lit_comp(""), str8_lit_comp("Step Out"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_StepOut},
|
||||
{ str8_lit_comp("run_to_address"), str8_lit_comp("Runs the selected thread to the specified address."), str8_lit_comp(""), str8_lit_comp("Run To Address"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_VirtualAddr, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*1)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_PlayStepForward},
|
||||
{ str8_lit_comp("halt"), str8_lit_comp("Halts all running processes."), str8_lit_comp("pause"), str8_lit_comp("Halt"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Pause},
|
||||
{ str8_lit_comp("soft_halt_refresh"), str8_lit_comp("Interrupts all running processes to collect data, and then resumes them."), str8_lit_comp(""), str8_lit_comp("Soft Halt Refresh"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Refresh},
|
||||
{ str8_lit_comp("set_thread_ip"), str8_lit_comp("Sets the passed thread's instruction pointer at the passed address."), str8_lit_comp(""), str8_lit_comp("Set Thread IP"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_VirtualAddr, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*1)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("run_to_line"), str8_lit_comp("Runs until a particular source line is hit."), str8_lit_comp(""), str8_lit_comp("Run To Line"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Play},
|
||||
{ str8_lit_comp("run_to_address"), str8_lit_comp("Runs until a particular address is hit."), str8_lit_comp(""), str8_lit_comp("Run To Address"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_VirtualAddr, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*1)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_PlayStepForward},
|
||||
{ str8_lit_comp("run"), str8_lit_comp("Runs all targets after starting them if they have not been started yet."), str8_lit_comp("play"), str8_lit_comp("Run"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Play},
|
||||
{ str8_lit_comp("restart"), str8_lit_comp("Kills all running processes, then restarts the targets which were used to launch all current processes (if any)."), str8_lit_comp("restart,retry"), str8_lit_comp("Restart"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Redo},
|
||||
{ str8_lit_comp("step_into"), str8_lit_comp("Steps once, possibly into function calls, for either line or instructions."), str8_lit_comp(""), str8_lit_comp("Step Into"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_StepInto},
|
||||
@@ -89,8 +90,8 @@ DF_CmdSpecInfo df_g_core_cmd_kind_spec_info_table[] =
|
||||
{ str8_lit_comp("set_file_override_link_src"), str8_lit_comp("Sets the source path for an override file link."), str8_lit_comp(""), str8_lit_comp("Set File Override Link Source"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("set_file_override_link_dst"), str8_lit_comp("Sets the destination path for an override file link."), str8_lit_comp(""), str8_lit_comp("Set File Override Link Destination"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("set_file_replacement_path"), str8_lit_comp("Sets the path which should be used as the replacement for the passed file."), str8_lit_comp(""), str8_lit_comp("Set File Replacement Path"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("load_user"), str8_lit_comp("Loads and applies a user file."), str8_lit_comp("load,user,profile,layout"), str8_lit_comp("Load User"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_FilePath, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*1)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Person},
|
||||
{ str8_lit_comp("load_profile"), str8_lit_comp("Loads and applies a profile file."), str8_lit_comp("profile,project,session"), str8_lit_comp("Load Profile"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_FilePath, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*1)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Briefcase},
|
||||
{ str8_lit_comp("open_user"), str8_lit_comp("Opens a user file path, immediately loading it, and begins autosaving to it."), str8_lit_comp("load,user,profile,layout"), str8_lit_comp("Open User"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_FilePath, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*1)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Person},
|
||||
{ str8_lit_comp("open_profile"), str8_lit_comp("Opens a profile file path, immediately loading it, and begins autosaving to it."), str8_lit_comp("profile,project,session"), str8_lit_comp("Open Profile"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_FilePath, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*1)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Briefcase},
|
||||
{ str8_lit_comp("apply_user_data"), str8_lit_comp("Applies user data from the active user file."), str8_lit_comp(""), str8_lit_comp("Apply User Data"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("apply_profile_data"), str8_lit_comp("Applies profile data from the active profile file."), str8_lit_comp(""), str8_lit_comp("Apply Profile Data"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("write_user_data"), str8_lit_comp("Writes user data to the active user file."), str8_lit_comp(""), str8_lit_comp("Write User Data"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
@@ -169,8 +170,11 @@ DF_CmdSpecInfo df_g_core_cmd_kind_spec_info_table[] =
|
||||
{ str8_lit_comp("add_target"), str8_lit_comp("Adds a new target."), str8_lit_comp("application,executable,debug"), str8_lit_comp("Add Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_FilePath, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*1)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Target},
|
||||
{ str8_lit_comp("remove_target"), str8_lit_comp("Removes an existing target."), str8_lit_comp("delete,remove,target"), str8_lit_comp("Remove Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Entity, DF_EntityKind_Target, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Trash},
|
||||
{ str8_lit_comp("edit_target"), str8_lit_comp("Edits an existing target."), str8_lit_comp(""), str8_lit_comp("Edit Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Entity, DF_EntityKind_Target, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Pencil},
|
||||
{ str8_lit_comp("select_target"), str8_lit_comp("Selects a target."), str8_lit_comp(""), str8_lit_comp("Select Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Entity, DF_EntityKind_Target, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Target},
|
||||
{ str8_lit_comp("enable_target"), str8_lit_comp("Enables a target, in addition to all targets currently enabled."), str8_lit_comp(""), str8_lit_comp("Enable Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Entity, DF_EntityKind_Target, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_CheckFilled},
|
||||
{ str8_lit_comp("disable_target"), str8_lit_comp("Disables a target."), str8_lit_comp(""), str8_lit_comp("Disable Target"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Entity, DF_EntityKind_Target, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_CheckHollow},
|
||||
{ str8_lit_comp("retry_ended_process"), str8_lit_comp("Launches a new process with the same options as the passed ended process."), str8_lit_comp(""), str8_lit_comp("Retry Ended Process"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Entity, DF_EntityKind_Process, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("attach"), str8_lit_comp("Attaches to a process that is already running on the local machine."), str8_lit_comp(""), str8_lit_comp("Attach"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_ID, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*1)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("attach"), str8_lit_comp("Attaches to a process that is already running on the local machine."), str8_lit_comp(""), str8_lit_comp("Attach"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_ID, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*1)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("register_as_jit_debugger"), str8_lit_comp("Registers the RAD debugger as the just-in-time (JIT) debugger used by the operating system."), str8_lit_comp(""), str8_lit_comp("Register As Just-In-Time (JIT) Debugger"), (DF_CmdSpecFlag_OmitFromLists*0), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("entity_ref_fast_path"), str8_lit_comp("Activates the default behavior when clicking an entity reference."), str8_lit_comp(""), str8_lit_comp("Entity Reference Fast Path"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
{ str8_lit_comp("spawn_entity_view"), str8_lit_comp("Spawns a new view, given an entity and other parameterizations."), str8_lit_comp(""), str8_lit_comp("Spawn Entity View"), (DF_CmdSpecFlag_OmitFromLists*1), {DF_CmdParamSlot_Null, DF_EntityKind_Nil, (DF_CmdQueryFlag_AllowFiles*0)|(DF_CmdQueryFlag_AllowFolders*0)|(DF_CmdQueryFlag_CodeInput*0)|(DF_CmdQueryFlag_KeepOldInput*0)|(DF_CmdQueryFlag_SelectOldInput*0)|(DF_CmdQueryFlag_Required*0)}, DF_IconKind_Null},
|
||||
|
||||
@@ -11,6 +11,7 @@ typedef enum DF_CfgSrc
|
||||
DF_CfgSrc_User,
|
||||
DF_CfgSrc_Profile,
|
||||
DF_CfgSrc_CommandLine,
|
||||
DF_CfgSrc_Transient,
|
||||
DF_CfgSrc_COUNT
|
||||
} DF_CfgSrc;
|
||||
|
||||
@@ -70,10 +71,11 @@ DF_CoreCmdKind_StepOverInst,
|
||||
DF_CoreCmdKind_StepIntoLine,
|
||||
DF_CoreCmdKind_StepOverLine,
|
||||
DF_CoreCmdKind_StepOut,
|
||||
DF_CoreCmdKind_RunToAddress,
|
||||
DF_CoreCmdKind_Halt,
|
||||
DF_CoreCmdKind_SoftHaltRefresh,
|
||||
DF_CoreCmdKind_SetThreadIP,
|
||||
DF_CoreCmdKind_RunToLine,
|
||||
DF_CoreCmdKind_RunToAddress,
|
||||
DF_CoreCmdKind_Run,
|
||||
DF_CoreCmdKind_Restart,
|
||||
DF_CoreCmdKind_StepInto,
|
||||
@@ -139,8 +141,8 @@ DF_CoreCmdKind_SwitchToPartnerFile,
|
||||
DF_CoreCmdKind_SetFileOverrideLinkSrc,
|
||||
DF_CoreCmdKind_SetFileOverrideLinkDst,
|
||||
DF_CoreCmdKind_SetFileReplacementPath,
|
||||
DF_CoreCmdKind_LoadUser,
|
||||
DF_CoreCmdKind_LoadProfile,
|
||||
DF_CoreCmdKind_OpenUser,
|
||||
DF_CoreCmdKind_OpenProfile,
|
||||
DF_CoreCmdKind_ApplyUserData,
|
||||
DF_CoreCmdKind_ApplyProfileData,
|
||||
DF_CoreCmdKind_WriteUserData,
|
||||
@@ -219,6 +221,9 @@ DF_CoreCmdKind_ToggleWatchPinAtCursor,
|
||||
DF_CoreCmdKind_AddTarget,
|
||||
DF_CoreCmdKind_RemoveTarget,
|
||||
DF_CoreCmdKind_EditTarget,
|
||||
DF_CoreCmdKind_SelectTarget,
|
||||
DF_CoreCmdKind_EnableTarget,
|
||||
DF_CoreCmdKind_DisableTarget,
|
||||
DF_CoreCmdKind_RetryEndedProcess,
|
||||
DF_CoreCmdKind_Attach,
|
||||
DF_CoreCmdKind_RegisterAsJITDebugger,
|
||||
@@ -1680,12 +1685,14 @@ String8 df_g_cfg_src_string_table[] =
|
||||
str8_lit_comp("user"),
|
||||
str8_lit_comp("profile"),
|
||||
str8_lit_comp("command_line"),
|
||||
str8_lit_comp("transient"),
|
||||
};
|
||||
|
||||
DF_CoreCmdKind df_g_cfg_src_load_cmd_kind_table[] =
|
||||
{
|
||||
DF_CoreCmdKind_LoadUser,
|
||||
DF_CoreCmdKind_LoadProfile,
|
||||
DF_CoreCmdKind_OpenUser,
|
||||
DF_CoreCmdKind_OpenProfile,
|
||||
DF_CoreCmdKind_Null,
|
||||
DF_CoreCmdKind_Null,
|
||||
};
|
||||
|
||||
@@ -1694,6 +1701,7 @@ DF_CoreCmdKind df_g_cfg_src_write_cmd_kind_table[] =
|
||||
DF_CoreCmdKind_WriteUserData,
|
||||
DF_CoreCmdKind_WriteProfileData,
|
||||
DF_CoreCmdKind_Null,
|
||||
DF_CoreCmdKind_Null,
|
||||
};
|
||||
|
||||
DF_CoreCmdKind df_g_cfg_src_apply_cmd_kind_table[] =
|
||||
@@ -1701,6 +1709,7 @@ DF_CoreCmdKind df_g_cfg_src_apply_cmd_kind_table[] =
|
||||
DF_CoreCmdKind_ApplyUserData,
|
||||
DF_CoreCmdKind_ApplyProfileData,
|
||||
DF_CoreCmdKind_Null,
|
||||
DF_CoreCmdKind_Null,
|
||||
};
|
||||
|
||||
String8 df_g_icon_kind_text_table[] =
|
||||
|
||||
+369
-393
File diff suppressed because it is too large
Load Diff
@@ -561,6 +561,7 @@ struct DF_Window
|
||||
DF_AutoCompListerFlags autocomp_lister_flags;
|
||||
U8 autocomp_lister_query_buffer[1024];
|
||||
U64 autocomp_lister_query_size;
|
||||
F32 autocomp_open_t;
|
||||
F32 autocomp_num_visible_rows_t;
|
||||
S64 autocomp_cursor_num;
|
||||
|
||||
@@ -591,6 +592,7 @@ struct DF_Window
|
||||
DF_Handle hover_eval_file;
|
||||
TxtPt hover_eval_file_pt;
|
||||
U64 hover_eval_vaddr;
|
||||
F32 hover_eval_open_t;
|
||||
F32 hover_eval_num_visible_rows_t;
|
||||
|
||||
// rjf: error state
|
||||
|
||||
+15
-7
@@ -170,7 +170,9 @@ DF_DefaultBindingTable:
|
||||
@table(old_name new_name)
|
||||
DF_BindingVersionRemapTable:
|
||||
{
|
||||
{"commands" "run_command"}
|
||||
{"commands" "run_command"}
|
||||
{"load_user" "open_user"}
|
||||
{"load_profile" "open_profile"}
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
@@ -308,7 +310,7 @@ DF_GfxViewRuleTable:
|
||||
////////////////////////////////
|
||||
//~ rjf: Theme Color Codes
|
||||
|
||||
@table(name display_name name_lower r g b a)
|
||||
@table(name display_name name_lower)
|
||||
DF_ThemeTable:
|
||||
{
|
||||
{Null "Null" null }
|
||||
@@ -410,10 +412,10 @@ DF_ThemePresetColorTable:
|
||||
(code_string 0xe5cc66ff 0xcc5a0fff 0xd69d85ff 0xc11515ff 0x2aa198ff 0x5ab4a9ff 0x6b8e23ff 0x50ff30ff 0xe5cc66ff )
|
||||
(code_meta 0xe54c4cff 0x8a0c0cff 0x9b9b9bff 0x808080ff 0xe54c4cff 0xe54c4cff 0xdab98fff 0x50ff30ff 0xffff00ff )
|
||||
(code_comment 0x7f7f7fff 0x7f7f7fff 0x6a9955ff 0x008000ff 0x7f7f7fff 0xadafb2ff 0x686868ff 0x2090f0ff 0x7f7f7fff )
|
||||
(line_info_0 0x3f72993f 0x3e71993f 0xbeb7ff3f 0x3f72993f 0x3f72993f 0x3f72993f 0xaf60103f 0x3f72993f 0x3f72993f )
|
||||
(line_info_1 0x3f72994c 0x3f72994c 0xbeb7ff4c 0x3f72994c 0x3f72994c 0x3f72994c 0xaf60104c 0x3f72994c 0x3f72994c )
|
||||
(line_info_2 0x3f729972 0x3f729972 0xbeb7ff72 0x3f729972 0x3f729972 0x3f729972 0xaf601072 0x3f729972 0x3f729972 )
|
||||
(line_info_3 0x3f72997f 0x3f72997f 0xbeb7ff7f 0x3f72997f 0x3f72997f 0x3f72997f 0xaf60107f 0x3f72997f 0x3f72997f )
|
||||
(line_info_0 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f 0x99503d3f )
|
||||
(line_info_1 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f 0xfe82493f )
|
||||
(line_info_2 0xffba173f 0xffba173f 0xffba173f 0xffba173f 0xffba173f 0xffba173f 0xffba173f 0xffba173f 0xffba173f )
|
||||
(line_info_3 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f 0xcefd693f )
|
||||
(alt_text 0xe5e5e5ff 0x535353ff 0xf1f1f1ff 0x535353ff 0xe5e5e5ff 0x535353ff 0xa08563ff 0x90b080ff 0x000000ff )
|
||||
(alt_background 0x42474c7f 0xfefefebc 0x1b1b1cff 0xfefefebc 0x002b36ff 0xfcf6e2ff 0x0c0c0cff 0x0c0c0cff 0x008184ff )
|
||||
(alt_border 0xffffff19 0xffffff19 0x333337ff 0xffffff19 0xffffff19 0xffffff19 0xffffff19 0xffffff19 0xffffff19 )
|
||||
@@ -487,6 +489,12 @@ df_g_theme_preset_display_string_table:
|
||||
@expand(DF_ThemePresetTable a) `str8_lit_comp("$(a.display_string)"),`;
|
||||
}
|
||||
|
||||
@table_gen_data(type: String8, fallback: `{0}`)
|
||||
df_g_theme_preset_code_string_table:
|
||||
{
|
||||
@expand(DF_ThemePresetTable a) `str8_lit_comp("$(a.name_lower)"),`;
|
||||
}
|
||||
|
||||
@table_gen_data(type: Vec4F32, fallback: `{1, 0, 1, 1}`)
|
||||
df_g_theme_preset_colors__default_dark:
|
||||
{
|
||||
@@ -639,7 +647,7 @@ df_g_gfx_view_kind_spec_info_table:
|
||||
@expand(DF_GfxViewTable a) ```{(0|$(a.parameterized_by_entity)*DF_ViewSpecFlag_ParameterizedByEntity|$(a.can_serialize)*DF_ViewSpecFlag_CanSerialize|$(a.can_serialize_entity_path)*DF_ViewSpecFlag_CanSerializeEntityPath), str8_lit_comp("$(a.name_lower)"), str8_lit_comp("$(a.display_string)"), DF_NameKind_$(a.name_kind), DF_IconKind_$(a.icon), DF_VIEW_SETUP_FUNCTION_NAME($(a.name)), DF_VIEW_STRING_FROM_STATE_FUNCTION_NAME($(a.name)), DF_VIEW_CMD_FUNCTION_NAME($(a.name)), DF_VIEW_UI_FUNCTION_NAME($(a.name))},```;
|
||||
}
|
||||
|
||||
//- rjf: theme color string tables
|
||||
//- rjf: theme color tables
|
||||
|
||||
@table_gen_data(type: String8, fallback: `str8_lit_comp("")`)
|
||||
df_g_theme_color_display_string_table:
|
||||
|
||||
@@ -30,7 +30,8 @@ df_view_rule_hooks__rgba_from_eval(DF_Eval eval, TG_Graph *graph, RADDBG_Parsed
|
||||
U64 array_total_size = tg_byte_size_from_graph_raddbg_key(graph, raddbg, type_key);
|
||||
U64 array_total_size_capped = ClampTop(array_total_size, 64);
|
||||
Rng1U64 array_memory_vaddr_rng = r1u64(eval.offset, eval.offset + array_total_size_capped);
|
||||
String8 array_memory = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, array_memory_vaddr_rng);
|
||||
CTRL_ProcessMemorySlice array_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, array_memory_vaddr_rng);
|
||||
String8 array_memory = array_slice.data;
|
||||
TG_Key element_type_key = tg_unwrapped_direct_from_graph_raddbg_key(graph, raddbg, type_key);
|
||||
TG_Kind element_type_kind = tg_kind_from_key(element_type_key);
|
||||
U64 element_type_size = tg_byte_size_from_graph_raddbg_key(graph, raddbg, element_type_key);
|
||||
@@ -66,7 +67,8 @@ df_view_rule_hooks__rgba_from_eval(DF_Eval eval, TG_Graph *graph, RADDBG_Parsed
|
||||
U64 struct_total_size = tg_byte_size_from_graph_raddbg_key(graph, raddbg, type_key);
|
||||
U64 struct_total_size_capped = ClampTop(struct_total_size, 64);
|
||||
Rng1U64 struct_memory_vaddr_rng = r1u64(eval.offset, eval.offset + struct_total_size_capped);
|
||||
String8 struct_memory = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, struct_memory_vaddr_rng);
|
||||
CTRL_ProcessMemorySlice struct_slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, struct_memory_vaddr_rng);
|
||||
String8 struct_memory = struct_slice.data;
|
||||
TG_Type *type = tg_type_from_graph_raddbg_key(scratch.arena, graph, raddbg, type_key);
|
||||
for(U64 element_idx = 0, member_idx = 0;
|
||||
element_idx < 4 && member_idx < type->count;
|
||||
|
||||
+54
-69
@@ -976,6 +976,28 @@ df_eval_watch_view_build(DF_Window *ws, DF_Panel *panel, DF_View *view, DF_EvalW
|
||||
B32 row_expanded = df_expand_key_is_set(&eval_view->expand_tree_table, row->key);
|
||||
DF_EvalHistoryCacheNode *history_cache_node = df_eval_history_cache_node_from_key(eval_view, row->key);
|
||||
|
||||
//- rjf: determine if row's data is fresh
|
||||
B32 row_is_fresh = 0;
|
||||
switch(row->eval.mode)
|
||||
{
|
||||
default:{}break;
|
||||
case EVAL_EvalMode_Addr:
|
||||
{
|
||||
U64 size = tg_byte_size_from_graph_raddbg_key(parse_ctx.type_graph, parse_ctx.rdbg, row->eval.type_key);
|
||||
size = Min(size, 64);
|
||||
Rng1U64 vaddr_rng = r1u64(row->eval.offset, row->eval.offset+size);
|
||||
CTRL_ProcessMemorySlice slice = ctrl_query_cached_data_from_process_vaddr_range(scratch.arena, process->ctrl_machine_id, process->ctrl_handle, vaddr_rng);
|
||||
for(U64 idx = 0; idx < (size+63)/64; idx += 1)
|
||||
{
|
||||
if(slice.byte_changed_flags[idx] != 0)
|
||||
{
|
||||
row_is_fresh = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}break;
|
||||
}
|
||||
|
||||
//- rjf: store root edit commit info
|
||||
if(row_selected)
|
||||
{
|
||||
@@ -1032,7 +1054,11 @@ df_eval_watch_view_build(DF_Window *ws, DF_Panel *panel, DF_View *view, DF_EvalW
|
||||
//- rjf: build normal row
|
||||
if(!(row->flags & DF_EvalVizRowFlag_Canvas))
|
||||
{
|
||||
ui_set_next_flags(disabled_flags);
|
||||
ui_set_next_flags(disabled_flags|(row_is_fresh*UI_BoxFlag_DrawOverlay));
|
||||
if(row_is_fresh)
|
||||
{
|
||||
ui_set_next_overlay_color(mul_4f32(df_rgba_from_theme_color(DF_ThemeColor_Highlight0), v4f32(1, 1, 1, 0.2f)));
|
||||
}
|
||||
UI_NamedTableVectorF("row_%I64x", row_hash)
|
||||
{
|
||||
//- rjf: expression
|
||||
@@ -1218,19 +1244,7 @@ df_eval_watch_view_build(DF_Window *ws, DF_Panel *panel, DF_View *view, DF_EvalW
|
||||
}
|
||||
StringJoin join = {str8_lit(""), str8_lit(" "), str8_lit("")};
|
||||
String8 error_string = str8_list_join(scratch.arena, &strings, &join);
|
||||
sig = df_error_label(error_string);
|
||||
if(sig.hovering)
|
||||
{
|
||||
UI_Tooltip
|
||||
UI_Font(df_font_from_slot(DF_FontSlot_Main))
|
||||
UI_FontSize(df_font_size_from_slot(ws, DF_FontSlot_Main))
|
||||
{
|
||||
for(EVAL_Error *error = row->errors.first; error != 0; error = error->next)
|
||||
{
|
||||
ui_label(error->text);
|
||||
}
|
||||
}
|
||||
}
|
||||
df_error_label(error_string);
|
||||
}
|
||||
|
||||
// rjf: hook -> call hook
|
||||
@@ -3191,9 +3205,20 @@ DF_VIEW_UI_FUNCTION_DEF(Targets)
|
||||
// rjf: enabled
|
||||
UI_PrefWidth(ui_em(2.25f, 1))
|
||||
UI_FocusHot((row_selected && cursor.x == 0) ? UI_FocusKind_On : UI_FocusKind_Off)
|
||||
if(df_icon_buttonf(target->b32 ? DF_IconKind_CheckFilled : DF_IconKind_CheckHollow, "###ebl_%p", target).clicked)
|
||||
{
|
||||
df_entity_equip_b32(target, !target->b32);
|
||||
UI_Signal sig = df_icon_buttonf(target->b32 ? DF_IconKind_CheckFilled : DF_IconKind_CheckHollow, "###ebl_%p", target);
|
||||
if(sig.clicked && sig.event_flags == 0)
|
||||
{
|
||||
DF_CmdParams p = df_cmd_params_from_view(ws, panel, view);
|
||||
p.entity = df_handle_from_entity(target);
|
||||
df_push_cmd__root(&p, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_SelectTarget));
|
||||
}
|
||||
else if(sig.clicked && sig.event_flags == OS_EventFlag_Ctrl)
|
||||
{
|
||||
DF_CmdParams p = df_cmd_params_from_view(ws, panel, view);
|
||||
p.entity = df_handle_from_entity(target);
|
||||
df_push_cmd__root(&p, df_cmd_spec_from_core_cmd_kind(target->b32 ? DF_CoreCmdKind_DisableTarget : DF_CoreCmdKind_EnableTarget));
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: target name
|
||||
@@ -4621,30 +4646,10 @@ DF_VIEW_CMD_FUNCTION_DEF(Code)
|
||||
}break;
|
||||
case DF_CoreCmdKind_RunToCursor:
|
||||
{
|
||||
Temp scratch = scratch_begin(0, 0);
|
||||
DF_Entity *thread = df_entity_from_handle(cmd->params.entity);
|
||||
S64 line_num = tv->cursor.line;
|
||||
DF_TextLineSrc2DasmInfoListArray src2dasm = df_text_line_src2dasm_info_list_array_from_src_line_range(scratch.arena, entity, r1s64(line_num, line_num));
|
||||
if(!df_entity_is_nil(thread) && src2dasm.count != 0)
|
||||
{
|
||||
DF_TextLineSrc2DasmInfoList *src2dasm_list = &src2dasm.v[0];
|
||||
if(src2dasm_list->first != 0)
|
||||
{
|
||||
Rng1U64 voff_rng = src2dasm_list->first->v.voff_range;
|
||||
DF_Entity *binary = src2dasm_list->first->v.binary;
|
||||
DF_EntityList possible_modules = df_modules_from_binary_file(scratch.arena, binary);
|
||||
DF_Entity *thread_dst_module = df_module_from_thread_candidates(thread, &possible_modules);
|
||||
U64 thread_dst_voff = voff_rng.min;
|
||||
if(!df_entity_is_nil(thread_dst_module) && thread_dst_voff != 0)
|
||||
{
|
||||
DF_CmdParams params = df_cmd_params_from_window(ws);
|
||||
params.vaddr = df_vaddr_from_voff(thread_dst_module, thread_dst_voff);
|
||||
df_cmd_params_mark_slot(¶ms, DF_CmdParamSlot_VirtualAddr);
|
||||
df_push_cmd__root(¶ms, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_RunToAddress));
|
||||
}
|
||||
}
|
||||
}
|
||||
scratch_end(scratch);
|
||||
DF_CmdParams params = df_cmd_params_from_view(ws, panel, view);
|
||||
params.entity = view->entity;
|
||||
params.text_point = tv->cursor;
|
||||
df_push_cmd__root(¶ms, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_RunToLine));
|
||||
}break;
|
||||
case DF_CoreCmdKind_SetNextStatement:
|
||||
{
|
||||
@@ -4985,7 +4990,6 @@ DF_VIEW_UI_FUNCTION_DEF(Code)
|
||||
ui_set_next_child_layout_axis(Axis2_Y);
|
||||
container_box = ui_build_box_from_stringf(UI_BoxFlag_Clip|
|
||||
UI_BoxFlag_Scroll|
|
||||
UI_BoxFlag_DrawBorder|
|
||||
UI_BoxFlag_AllowOverflowX|
|
||||
UI_BoxFlag_AllowOverflowY,
|
||||
"###code_area_%p", view);
|
||||
@@ -5310,29 +5314,10 @@ DF_VIEW_UI_FUNCTION_DEF(Code)
|
||||
//- rjf: run-to-line
|
||||
if(sig.run_to_line_num != 0 && contains_1s64(visible_line_num_range, sig.run_to_line_num))
|
||||
{
|
||||
U64 line_idx = (sig.run_to_line_num-visible_line_num_range.min);
|
||||
DF_TextLineSrc2DasmInfoList *src2dasm_list = &code_slice_params.line_src2dasm[line_idx];
|
||||
if(src2dasm_list->first != 0)
|
||||
{
|
||||
Rng1U64 voff_rng = src2dasm_list->first->v.voff_range;
|
||||
DF_Entity *binary = src2dasm_list->first->v.binary;
|
||||
DF_EntityList possible_modules = df_modules_from_binary_file(scratch.arena, binary);
|
||||
DF_Entity *thread = df_entity_from_handle(ctrl_ctx.thread);
|
||||
DF_Entity *thread_dst_module = df_module_from_thread_candidates(thread, &possible_modules);
|
||||
DF_Entity *module = thread_dst_module;
|
||||
if(df_entity_is_nil(module))
|
||||
{
|
||||
module = df_first_entity_from_list(&possible_modules);
|
||||
}
|
||||
U64 voff = voff_rng.min;
|
||||
if(!df_entity_is_nil(module) && voff != 0)
|
||||
{
|
||||
DF_CmdParams params = df_cmd_params_from_window(ws);
|
||||
params.vaddr = df_vaddr_from_voff(module, voff);
|
||||
df_cmd_params_mark_slot(¶ms, DF_CmdParamSlot_VirtualAddr);
|
||||
df_push_cmd__root(¶ms, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_RunToAddress));
|
||||
}
|
||||
}
|
||||
DF_CmdParams params = df_cmd_params_from_view(ws, panel, view);
|
||||
params.entity = df_handle_from_entity(entity);
|
||||
params.text_point = txt_pt(sig.run_to_line_num, 1);
|
||||
df_push_cmd__root(¶ms, df_cmd_spec_from_core_cmd_kind(DF_CoreCmdKind_RunToLine));
|
||||
}
|
||||
|
||||
//- rjf: go to disasm
|
||||
@@ -7011,7 +6996,7 @@ DF_VIEW_UI_FUNCTION_DEF(Output)
|
||||
{
|
||||
if(txti_buffer_is_ready && visible_line_num_range.max >= visible_line_num_range.min && ui_is_focus_active())
|
||||
{
|
||||
snap[Axis2_X] = snap[Axis2_Y] = df_do_txti_controls(txti_handle, ClampBot(visible_line_count, 10) - 10, &tv->cursor, &tv->mark, &tv->preferred_column);
|
||||
snap[Axis2_X] = snap[Axis2_Y] = df_do_txti_controls(txti_handle, ClampBot(num_possible_visible_lines, 10) - 10, &tv->cursor, &tv->mark, &tv->preferred_column);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7154,10 +7139,10 @@ DF_VIEW_UI_FUNCTION_DEF(Output)
|
||||
if(snap[Axis2_Y])
|
||||
{
|
||||
Rng1S64 cursor_visibility_range = r1s64(tv->cursor.line-4, tv->cursor.line+4);
|
||||
cursor_visibility_range.min = Clamp(0, cursor_visibility_range.min, (S64)txti_buffer_info.total_line_count);
|
||||
cursor_visibility_range.max = Clamp(0, cursor_visibility_range.max, (S64)txti_buffer_info.total_line_count);
|
||||
S64 min_delta = Min(0, cursor_visibility_range.min-target_visible_line_num_range.min);
|
||||
S64 max_delta = Max(0, cursor_visibility_range.max-target_visible_line_num_range.max);
|
||||
cursor_visibility_range.min = ClampBot(0, cursor_visibility_range.min);
|
||||
cursor_visibility_range.max = ClampBot(0, cursor_visibility_range.max);
|
||||
S64 min_delta = Min(0, cursor_visibility_range.min-(target_visible_line_num_range.min));
|
||||
S64 max_delta = Max(0, cursor_visibility_range.max-(target_visible_line_num_range.min+num_possible_visible_lines));
|
||||
S64 new_idx = view->scroll_pos.y.idx+min_delta+max_delta;
|
||||
new_idx = Clamp(0, new_idx, (S64)txti_buffer_info.total_line_count-1);
|
||||
ui_scroll_pt_target_idx(&view->scroll_pos.y, new_idx);
|
||||
|
||||
@@ -235,6 +235,19 @@ str8_lit_comp("4coder"),
|
||||
str8_lit_comp("Far Manager"),
|
||||
};
|
||||
|
||||
String8 df_g_theme_preset_code_string_table[] =
|
||||
{
|
||||
str8_lit_comp("default_dark"),
|
||||
str8_lit_comp("default_light"),
|
||||
str8_lit_comp("vs_dark"),
|
||||
str8_lit_comp("vs_light"),
|
||||
str8_lit_comp("solarized_dark"),
|
||||
str8_lit_comp("solarized_light"),
|
||||
str8_lit_comp("handmade_hero"),
|
||||
str8_lit_comp("four_coder"),
|
||||
str8_lit_comp("far_manager"),
|
||||
};
|
||||
|
||||
Vec4F32 df_g_theme_preset_colors__default_dark[] =
|
||||
{
|
||||
rgba_from_u32_lit_comp(0xff00ffff),
|
||||
@@ -252,10 +265,10 @@ rgba_from_u32_lit_comp(0x4ce54cff),
|
||||
rgba_from_u32_lit_comp(0xe5cc66ff),
|
||||
rgba_from_u32_lit_comp(0xe54c4cff),
|
||||
rgba_from_u32_lit_comp(0x7f7f7fff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0xe5e5e5ff),
|
||||
rgba_from_u32_lit_comp(0x42474c7f),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -309,10 +322,10 @@ rgba_from_u32_lit_comp(0x2c7d2cff),
|
||||
rgba_from_u32_lit_comp(0xcc5a0fff),
|
||||
rgba_from_u32_lit_comp(0x8a0c0cff),
|
||||
rgba_from_u32_lit_comp(0x7f7f7fff),
|
||||
rgba_from_u32_lit_comp(0x3e71993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0x535353ff),
|
||||
rgba_from_u32_lit_comp(0xfefefebc),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -366,10 +379,10 @@ rgba_from_u32_lit_comp(0xb5cea8ff),
|
||||
rgba_from_u32_lit_comp(0xd69d85ff),
|
||||
rgba_from_u32_lit_comp(0x9b9b9bff),
|
||||
rgba_from_u32_lit_comp(0x6a9955ff),
|
||||
rgba_from_u32_lit_comp(0xbeb7ff3f),
|
||||
rgba_from_u32_lit_comp(0xbeb7ff4c),
|
||||
rgba_from_u32_lit_comp(0xbeb7ff72),
|
||||
rgba_from_u32_lit_comp(0xbeb7ff7f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0xf1f1f1ff),
|
||||
rgba_from_u32_lit_comp(0x1b1b1cff),
|
||||
rgba_from_u32_lit_comp(0x333337ff),
|
||||
@@ -423,10 +436,10 @@ rgba_from_u32_lit_comp(0x000000ff),
|
||||
rgba_from_u32_lit_comp(0xc11515ff),
|
||||
rgba_from_u32_lit_comp(0x808080ff),
|
||||
rgba_from_u32_lit_comp(0x008000ff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0x535353ff),
|
||||
rgba_from_u32_lit_comp(0xfefefebc),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -480,10 +493,10 @@ rgba_from_u32_lit_comp(0xcb4b20ff),
|
||||
rgba_from_u32_lit_comp(0x2aa198ff),
|
||||
rgba_from_u32_lit_comp(0xe54c4cff),
|
||||
rgba_from_u32_lit_comp(0x7f7f7fff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0xe5e5e5ff),
|
||||
rgba_from_u32_lit_comp(0x002b36ff),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -537,10 +550,10 @@ rgba_from_u32_lit_comp(0x657b83ff),
|
||||
rgba_from_u32_lit_comp(0x5ab4a9ff),
|
||||
rgba_from_u32_lit_comp(0xe54c4cff),
|
||||
rgba_from_u32_lit_comp(0xadafb2ff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0x535353ff),
|
||||
rgba_from_u32_lit_comp(0xfcf6e2ff),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -594,10 +607,10 @@ rgba_from_u32_lit_comp(0x6b8e23ff),
|
||||
rgba_from_u32_lit_comp(0x6b8e23ff),
|
||||
rgba_from_u32_lit_comp(0xdab98fff),
|
||||
rgba_from_u32_lit_comp(0x686868ff),
|
||||
rgba_from_u32_lit_comp(0xaf60103f),
|
||||
rgba_from_u32_lit_comp(0xaf60104c),
|
||||
rgba_from_u32_lit_comp(0xaf601072),
|
||||
rgba_from_u32_lit_comp(0xaf60107f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0xa08563ff),
|
||||
rgba_from_u32_lit_comp(0x0c0c0cff),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -651,10 +664,10 @@ rgba_from_u32_lit_comp(0x50ff30ff),
|
||||
rgba_from_u32_lit_comp(0x50ff30ff),
|
||||
rgba_from_u32_lit_comp(0x50ff30ff),
|
||||
rgba_from_u32_lit_comp(0x2090f0ff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0x90b080ff),
|
||||
rgba_from_u32_lit_comp(0x0c0c0cff),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -708,10 +721,10 @@ rgba_from_u32_lit_comp(0x2cff50ff),
|
||||
rgba_from_u32_lit_comp(0xe5cc66ff),
|
||||
rgba_from_u32_lit_comp(0xffff00ff),
|
||||
rgba_from_u32_lit_comp(0x7f7f7fff),
|
||||
rgba_from_u32_lit_comp(0x3f72993f),
|
||||
rgba_from_u32_lit_comp(0x3f72994c),
|
||||
rgba_from_u32_lit_comp(0x3f729972),
|
||||
rgba_from_u32_lit_comp(0x3f72997f),
|
||||
rgba_from_u32_lit_comp(0x99503d3f),
|
||||
rgba_from_u32_lit_comp(0xfe82493f),
|
||||
rgba_from_u32_lit_comp(0xffba173f),
|
||||
rgba_from_u32_lit_comp(0xcefd693f),
|
||||
rgba_from_u32_lit_comp(0x000000ff),
|
||||
rgba_from_u32_lit_comp(0x008184ff),
|
||||
rgba_from_u32_lit_comp(0xffffff19),
|
||||
@@ -1002,11 +1015,15 @@ DF_StringBindingPair df_g_default_binding_table[] =
|
||||
String8 df_g_binding_version_remap_old_name_table[] =
|
||||
{
|
||||
str8_lit_comp("commands"),
|
||||
str8_lit_comp("load_user"),
|
||||
str8_lit_comp("load_profile"),
|
||||
};
|
||||
|
||||
String8 df_g_binding_version_remap_new_name_table[] =
|
||||
{
|
||||
str8_lit_comp("run_command"),
|
||||
str8_lit_comp("open_user"),
|
||||
str8_lit_comp("open_profile"),
|
||||
};
|
||||
|
||||
DF_ViewSpecInfo df_g_gfx_view_kind_spec_info_table[] =
|
||||
|
||||
@@ -90,6 +90,22 @@ d_fancy_run_list_from_fancy_string_list(Arena *arena, D_FancyStringList *strs)
|
||||
return run_list;
|
||||
}
|
||||
|
||||
internal D_FancyRunList
|
||||
d_fancy_run_list_copy(Arena *arena, D_FancyRunList *src)
|
||||
{
|
||||
D_FancyRunList dst = {0};
|
||||
for(D_FancyRunNode *src_n = src->first; src_n != 0; src_n = src_n->next)
|
||||
{
|
||||
D_FancyRunNode *dst_n = push_array(arena, D_FancyRunNode, 1);
|
||||
SLLQueuePush(dst.first, dst.last, dst_n);
|
||||
MemoryCopyStruct(&dst_n->v, &src_n->v);
|
||||
dst_n->v.run.pieces = f_piece_array_copy(arena, &src_n->v.run.pieces);
|
||||
dst.node_count += 1;
|
||||
}
|
||||
dst.dim = src->dim;
|
||||
return dst;
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Top-Level API
|
||||
//
|
||||
|
||||
@@ -111,6 +111,7 @@ internal U64 d_hash_from_string(String8 string);
|
||||
internal void d_fancy_string_list_push(Arena *arena, D_FancyStringList *list, D_FancyString *str);
|
||||
internal String8 d_string_from_fancy_string_list(Arena *arena, D_FancyStringList *list);
|
||||
internal D_FancyRunList d_fancy_run_list_from_fancy_string_list(Arena *arena, D_FancyStringList *strs);
|
||||
internal D_FancyRunList d_fancy_run_list_copy(Arena *arena, D_FancyRunList *src);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Top-Level API
|
||||
|
||||
+23
-18
@@ -834,8 +834,8 @@ eval_parse_expr_from_text_tokens__prec(Arena *arena, EVAL_ParseCtx *ctx, String8
|
||||
TG_Key type_key = zero_struct;
|
||||
String8 local_lookup_string = token_string;
|
||||
|
||||
//- rjf: form namespaceify fallback
|
||||
String8 namespaceified_token_string = token_string;
|
||||
//- rjf: form namespaceified fallback versions of this lookup string
|
||||
String8List namespaceified_token_strings = {0};
|
||||
if(ctx->rdbg->procedures != 0 && ctx->rdbg->scopes != 0 && ctx->rdbg->scope_vmap != 0)
|
||||
{
|
||||
U64 scope_idx = raddbg_vmap_idx_from_voff(ctx->rdbg->scope_vmap, ctx->rdbg->scope_vmap_count, ctx->ip_voff);
|
||||
@@ -844,23 +844,22 @@ eval_parse_expr_from_text_tokens__prec(Arena *arena, EVAL_ParseCtx *ctx, String8
|
||||
RADDBG_Procedure *procedure = &ctx->rdbg->procedures[proc_idx];
|
||||
U64 name_size = 0;
|
||||
U8 *name_ptr = raddbg_string_from_idx(ctx->rdbg, procedure->name_string_idx, &name_size);
|
||||
String8 name = str8(name_ptr, name_size);
|
||||
U64 past_scope_resolution_pos = 0;
|
||||
String8 containing_procedure_name = str8(name_ptr, name_size);
|
||||
U64 last_past_scope_resolution_pos = 0;
|
||||
for(;;)
|
||||
{
|
||||
U64 past_next_dbl_colon_pos = str8_find_needle(name, past_scope_resolution_pos, str8_lit("::"), 0)+2;
|
||||
U64 past_next_dot_pos = str8_find_needle(name, past_scope_resolution_pos, str8_lit("."), 0)+1;
|
||||
U64 past_next_dbl_colon_pos = str8_find_needle(containing_procedure_name, last_past_scope_resolution_pos, str8_lit("::"), 0)+2;
|
||||
U64 past_next_dot_pos = str8_find_needle(containing_procedure_name, last_past_scope_resolution_pos, str8_lit("."), 0)+1;
|
||||
U64 past_next_scope_resolution_pos = Min(past_next_dbl_colon_pos, past_next_dot_pos);
|
||||
if(past_next_scope_resolution_pos < name.size)
|
||||
{
|
||||
past_scope_resolution_pos = past_next_scope_resolution_pos;
|
||||
}
|
||||
else
|
||||
if(past_next_scope_resolution_pos >= containing_procedure_name.size)
|
||||
{
|
||||
break;
|
||||
}
|
||||
String8 new_namespace_prefix_possibility = str8_prefix(containing_procedure_name, past_next_scope_resolution_pos);
|
||||
String8 namespaceified_token_string = push_str8f(scratch.arena, "%S%S", new_namespace_prefix_possibility, token_string);
|
||||
str8_list_push_front(scratch.arena, &namespaceified_token_strings, namespaceified_token_string);
|
||||
last_past_scope_resolution_pos = past_next_scope_resolution_pos;
|
||||
}
|
||||
namespaceified_token_string = push_str8f(scratch.arena, "%S%S", str8_prefix(name, past_scope_resolution_pos), token_string);
|
||||
}
|
||||
|
||||
//- rjf: try members
|
||||
@@ -974,9 +973,11 @@ eval_parse_expr_from_text_tokens__prec(Arena *arena, EVAL_ParseCtx *ctx, String8
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, token_string.str, token_string.size);
|
||||
U32 matches_count = 0;
|
||||
U32 *matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
if(matches_count == 0)
|
||||
for(String8Node *n = namespaceified_token_strings.first;
|
||||
n != 0 && matches_count == 0;
|
||||
n = n->next)
|
||||
{
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, namespaceified_token_string.str, namespaceified_token_string.size);
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, n->string.str, n->string.size);
|
||||
matches_count = 0;
|
||||
matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
}
|
||||
@@ -1014,9 +1015,11 @@ eval_parse_expr_from_text_tokens__prec(Arena *arena, EVAL_ParseCtx *ctx, String8
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, token_string.str, token_string.size);
|
||||
U32 matches_count = 0;
|
||||
U32 *matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
if(matches_count == 0)
|
||||
for(String8Node *n = namespaceified_token_strings.first;
|
||||
n != 0 && matches_count == 0;
|
||||
n = n->next)
|
||||
{
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, namespaceified_token_string.str, namespaceified_token_string.size);
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, n->string.str, n->string.size);
|
||||
matches_count = 0;
|
||||
matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
}
|
||||
@@ -1050,9 +1053,11 @@ eval_parse_expr_from_text_tokens__prec(Arena *arena, EVAL_ParseCtx *ctx, String8
|
||||
RADDBG_NameMapNode *node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, token_string.str, token_string.size);
|
||||
U32 matches_count = 0;
|
||||
U32 *matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
if(matches_count == 0)
|
||||
for(String8Node *n = namespaceified_token_strings.first;
|
||||
n != 0 && matches_count == 0;
|
||||
n = n->next)
|
||||
{
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, namespaceified_token_string.str, namespaceified_token_string.size);
|
||||
node = raddbg_name_map_lookup(ctx->rdbg, &parsed_name_map, n->string.str, n->string.size);
|
||||
matches_count = 0;
|
||||
matches = raddbg_matches_from_map_node(ctx->rdbg, node, &matches_count);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,192 @@
|
||||
// Copyright (c) 2024 Epic Games Tools
|
||||
// Licensed under the MIT license (https://opensource.org/license/mit/)
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Top-Level API
|
||||
|
||||
internal void
|
||||
fs_init(void)
|
||||
{
|
||||
Arena *arena = arena_alloc();
|
||||
fs_shared = push_array(arena, FS_Shared, 1);
|
||||
fs_shared->arena = arena;
|
||||
fs_shared->slots_count = 1024;
|
||||
fs_shared->stripes_count = 64;
|
||||
fs_shared->slots = push_array(arena, FS_Slot, fs_shared->slots_count);
|
||||
fs_shared->stripes = push_array(arena, FS_Stripe, fs_shared->stripes_count);
|
||||
for(U64 idx = 0; idx < fs_shared->stripes_count; idx += 1)
|
||||
{
|
||||
fs_shared->stripes[idx].arena = arena_alloc();
|
||||
fs_shared->stripes[idx].cv = os_condition_variable_alloc();
|
||||
fs_shared->stripes[idx].rw_mutex = os_rw_mutex_alloc();
|
||||
}
|
||||
fs_shared->u2s_ring_size = KB(64);
|
||||
fs_shared->u2s_ring_base = push_array_no_zero(arena, U8, fs_shared->u2s_ring_size);
|
||||
fs_shared->u2s_ring_cv = os_condition_variable_alloc();
|
||||
fs_shared->u2s_ring_mutex = os_mutex_alloc();
|
||||
fs_shared->streamer_count = Min(4, os_logical_core_count()-1);
|
||||
fs_shared->streamers = push_array(arena, OS_Handle, 1);
|
||||
for(U64 idx = 0; idx < fs_shared->streamer_count; idx += 1)
|
||||
{
|
||||
fs_shared->streamers[idx] = os_launch_thread(fs_streamer_thread__entry_point, &idx, 0);
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Cache Interaction
|
||||
|
||||
internal U128
|
||||
fs_hash_from_path(String8 path, U64 rewind_count, U64 endt_us)
|
||||
{
|
||||
Temp scratch = scratch_begin(0, 0);
|
||||
path = path_normalized_from_string(scratch.arena, path);
|
||||
U128 path_key = hs_hash_from_data(path);
|
||||
U128 result = hs_hash_from_key(path_key, rewind_count);
|
||||
if(u128_match(result, u128_zero()))
|
||||
{
|
||||
U64 slot_idx = path_key.u64[0]%fs_shared->slots_count;
|
||||
U64 stripe_idx = slot_idx%fs_shared->stripes_count;
|
||||
FS_Slot *slot = &fs_shared->slots[slot_idx];
|
||||
FS_Stripe *stripe = &fs_shared->stripes[stripe_idx];
|
||||
OS_MutexScopeR(stripe->rw_mutex) for(;;)
|
||||
{
|
||||
FS_Node *node = 0;
|
||||
for(FS_Node *n = slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(str8_match(path, n->path, 0))
|
||||
{
|
||||
node = n;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(node == 0) OS_MutexScopeRWPromote(stripe->rw_mutex)
|
||||
{
|
||||
node = push_array(stripe->arena, FS_Node, 1);
|
||||
SLLQueuePush(slot->first, slot->last, node);
|
||||
node->path = push_str8_copy(stripe->arena, path);
|
||||
}
|
||||
if(os_now_microseconds() >= ins_atomic_u64_eval(&node->last_time_requested_us)+1000000 &&
|
||||
fs_u2s_enqueue_path(path, endt_us))
|
||||
{
|
||||
ins_atomic_u64_eval_assign(&node->last_time_requested_us, os_now_microseconds());
|
||||
}
|
||||
result = hs_hash_from_key(path_key, rewind_count);
|
||||
if(u128_match(result, u128_zero()) && os_now_microseconds() <= endt_us)
|
||||
{
|
||||
os_condition_variable_wait_rw_r(stripe->cv, stripe->rw_mutex, endt_us);
|
||||
}
|
||||
else
|
||||
{
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
scratch_end(scratch);
|
||||
return result;
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Streamer Threads
|
||||
|
||||
internal B32
|
||||
fs_u2s_enqueue_path(String8 path, U64 endt_us)
|
||||
{
|
||||
B32 result = 0;
|
||||
path.size = Min(path.size, fs_shared->u2s_ring_size);
|
||||
OS_MutexScope(fs_shared->u2s_ring_mutex) for(;;)
|
||||
{
|
||||
U64 unconsumed_size = fs_shared->u2s_ring_write_pos - fs_shared->u2s_ring_read_pos;
|
||||
U64 available_size = fs_shared->u2s_ring_size - unconsumed_size;
|
||||
if(available_size >= sizeof(U64) + path.size)
|
||||
{
|
||||
result = 1;
|
||||
fs_shared->u2s_ring_write_pos += ring_write_struct(fs_shared->u2s_ring_base, fs_shared->u2s_ring_size, fs_shared->u2s_ring_write_pos, &path.size);
|
||||
fs_shared->u2s_ring_write_pos += ring_write(fs_shared->u2s_ring_base, fs_shared->u2s_ring_size, fs_shared->u2s_ring_write_pos, path.str, path.size);
|
||||
fs_shared->u2s_ring_write_pos += 7;
|
||||
fs_shared->u2s_ring_write_pos -= fs_shared->u2s_ring_write_pos%8;
|
||||
break;
|
||||
}
|
||||
os_condition_variable_wait(fs_shared->u2s_ring_cv, fs_shared->u2s_ring_mutex, endt_us);
|
||||
}
|
||||
if(result)
|
||||
{
|
||||
os_condition_variable_broadcast(fs_shared->u2s_ring_cv);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
internal String8
|
||||
fs_u2s_dequeue_path(Arena *arena)
|
||||
{
|
||||
String8 path = {0};
|
||||
OS_MutexScope(fs_shared->u2s_ring_mutex) for(;;)
|
||||
{
|
||||
U64 unconsumed_size = fs_shared->u2s_ring_write_pos - fs_shared->u2s_ring_read_pos;
|
||||
if(unconsumed_size >= sizeof(U64))
|
||||
{
|
||||
fs_shared->u2s_ring_read_pos += ring_read_struct(fs_shared->u2s_ring_base, fs_shared->u2s_ring_size, fs_shared->u2s_ring_read_pos, &path.size);
|
||||
path.str = push_array(arena, U8, path.size);
|
||||
fs_shared->u2s_ring_read_pos += ring_read(fs_shared->u2s_ring_base, fs_shared->u2s_ring_size, fs_shared->u2s_ring_read_pos, path.str, path.size);
|
||||
fs_shared->u2s_ring_read_pos += 7;
|
||||
fs_shared->u2s_ring_read_pos -= fs_shared->u2s_ring_read_pos%8;
|
||||
break;
|
||||
}
|
||||
os_condition_variable_wait(fs_shared->u2s_ring_cv, fs_shared->u2s_ring_mutex, max_U64);
|
||||
}
|
||||
os_condition_variable_broadcast(fs_shared->u2s_ring_cv);
|
||||
return path;
|
||||
}
|
||||
|
||||
internal void
|
||||
fs_streamer_thread__entry_point(void *p)
|
||||
{
|
||||
TCTX tctx_;
|
||||
tctx_init_and_equip(&tctx_);
|
||||
ThreadName("[fs] streamer #%I64u", (U64)p);
|
||||
for(;;)
|
||||
{
|
||||
Temp scratch = scratch_begin(0, 0);
|
||||
String8 path = fs_u2s_dequeue_path(scratch.arena);
|
||||
FileProperties pre_props = os_properties_from_file_path(path);
|
||||
OS_Handle file = os_file_open(OS_AccessFlag_Read|OS_AccessFlag_ShareRead|OS_AccessFlag_ShareWrite, path);
|
||||
U64 data_arena_size = pre_props.size+ARENA_HEADER_SIZE;
|
||||
data_arena_size += KB(4)-1;
|
||||
data_arena_size -= data_arena_size%KB(4);
|
||||
Arena *data_arena = arena_alloc__sized(data_arena_size, data_arena_size);
|
||||
String8 data = os_string_from_file_range(data_arena, file, r1u64(0, pre_props.size));
|
||||
os_file_close(file);
|
||||
FileProperties post_props = os_properties_from_file_path(path);
|
||||
if(pre_props.modified != post_props.modified)
|
||||
{
|
||||
arena_release(data_arena);
|
||||
MemoryZeroStruct(&data);
|
||||
}
|
||||
else
|
||||
{
|
||||
U128 key = hs_hash_from_data(path);
|
||||
hs_submit_data(key, &data_arena, data);
|
||||
U64 slot_idx = key.u64[0]%fs_shared->slots_count;
|
||||
U64 stripe_idx = slot_idx%fs_shared->stripes_count;
|
||||
FS_Slot *slot = &fs_shared->slots[slot_idx];
|
||||
FS_Stripe *stripe = &fs_shared->stripes[stripe_idx];
|
||||
OS_MutexScopeW(stripe->rw_mutex)
|
||||
{
|
||||
FS_Node *node = 0;
|
||||
for(FS_Node *n = slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(str8_match(n->path, path, 0))
|
||||
{
|
||||
node = n;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(node != 0)
|
||||
{
|
||||
node->timestamp = post_props.modified;
|
||||
}
|
||||
}
|
||||
os_condition_variable_broadcast(stripe->cv);
|
||||
}
|
||||
scratch_end(scratch);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
// Copyright (c) 2024 Epic Games Tools
|
||||
// Licensed under the MIT license (https://opensource.org/license/mit/)
|
||||
|
||||
#ifndef FILE_STREAM_H
|
||||
#define FILE_STREAM_H
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Per-Path Info Cache Types
|
||||
|
||||
typedef struct FS_Node FS_Node;
|
||||
struct FS_Node
|
||||
{
|
||||
FS_Node *next;
|
||||
String8 path;
|
||||
U64 timestamp;
|
||||
U64 last_time_requested_us;
|
||||
};
|
||||
|
||||
typedef struct FS_Slot FS_Slot;
|
||||
struct FS_Slot
|
||||
{
|
||||
FS_Node *first;
|
||||
FS_Node *last;
|
||||
};
|
||||
|
||||
typedef struct FS_Stripe FS_Stripe;
|
||||
struct FS_Stripe
|
||||
{
|
||||
Arena *arena;
|
||||
OS_Handle cv;
|
||||
OS_Handle rw_mutex;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Shared State Bundle
|
||||
|
||||
typedef struct FS_Shared FS_Shared;
|
||||
struct FS_Shared
|
||||
{
|
||||
Arena *arena;
|
||||
|
||||
// rjf: path info cache
|
||||
U64 slots_count;
|
||||
U64 stripes_count;
|
||||
FS_Slot *slots;
|
||||
FS_Stripe *stripes;
|
||||
|
||||
// rjf: user -> streamer ring buffer
|
||||
U64 u2s_ring_size;
|
||||
U8 *u2s_ring_base;
|
||||
U64 u2s_ring_write_pos;
|
||||
U64 u2s_ring_read_pos;
|
||||
OS_Handle u2s_ring_cv;
|
||||
OS_Handle u2s_ring_mutex;
|
||||
|
||||
// rjf: streamer threads
|
||||
U64 streamer_count;
|
||||
OS_Handle *streamers;
|
||||
};
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Globals
|
||||
|
||||
global FS_Shared *fs_shared = 0;
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Top-Level API
|
||||
|
||||
internal void fs_init(void);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Cache Interaction
|
||||
|
||||
internal U128 fs_hash_from_path(String8 path, U64 rewind_count, U64 endt_us);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Streamer Threads
|
||||
|
||||
internal B32 fs_u2s_enqueue_path(String8 path, U64 endt_us);
|
||||
internal String8 fs_u2s_dequeue_path(Arena *arena);
|
||||
|
||||
internal void fs_streamer_thread__entry_point(void *p);
|
||||
|
||||
#endif // FILE_STREAM_H
|
||||
@@ -502,6 +502,16 @@ f_piece_array_from_chunk_list(Arena *arena, F_PieceChunkList *list)
|
||||
return array;
|
||||
}
|
||||
|
||||
internal F_PieceArray
|
||||
f_piece_array_copy(Arena *arena, F_PieceArray *src)
|
||||
{
|
||||
F_PieceArray dst = {0};
|
||||
dst.count = src->count;
|
||||
dst.v = push_array_no_zero(arena, F_Piece, dst.count);
|
||||
MemoryCopy(dst.v, src->v, sizeof(F_Piece)*dst.count);
|
||||
return dst;
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Rasterization Cache
|
||||
|
||||
|
||||
@@ -241,6 +241,7 @@ internal void f_atlas_region_release(F_Atlas *atlas, Rng2S16 region);
|
||||
internal F_Piece *f_piece_chunk_list_push_new(Arena *arena, F_PieceChunkList *list, U64 cap);
|
||||
internal void f_piece_chunk_list_push(Arena *arena, F_PieceChunkList *list, U64 cap, F_Piece *piece);
|
||||
internal F_PieceArray f_piece_array_from_chunk_list(Arena *arena, F_PieceChunkList *list);
|
||||
internal F_PieceArray f_piece_array_copy(Arena *arena, F_PieceArray *src);
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Rasterization Cache
|
||||
|
||||
+14
-10
@@ -122,7 +122,7 @@ hs_submit_data(U128 key, Arena **data_arena, String8 data)
|
||||
}
|
||||
|
||||
//- rjf: commit this hash to key cache
|
||||
U128 key_old_hash = {0};
|
||||
U128 key_expired_hash = {0};
|
||||
OS_MutexScopeW(key_stripe->rw_mutex)
|
||||
{
|
||||
HS_KeyNode *key_node = 0;
|
||||
@@ -142,15 +142,19 @@ hs_submit_data(U128 key, Arena **data_arena, String8 data)
|
||||
}
|
||||
if(key_node)
|
||||
{
|
||||
key_old_hash = key_node->hash;
|
||||
key_node->hash = hash;
|
||||
if(key_node->hash_history_gen >= ArrayCount(key_node->hash_history))
|
||||
{
|
||||
key_expired_hash = key_node->hash_history[key_node->hash_history_gen%ArrayCount(key_node->hash_history)];
|
||||
}
|
||||
key_node->hash_history[key_node->hash_history_gen%ArrayCount(key_node->hash_history)] = hash;
|
||||
key_node->hash_history_gen += 1;
|
||||
}
|
||||
}
|
||||
|
||||
//- rjf: if this key was correllated with an old hash, dec key ref count of old hash
|
||||
if(!u128_match(key_old_hash, u128_zero()))
|
||||
//- rjf: if this key's history cache was full, dec key ref count of oldest hash
|
||||
if(!u128_match(key_expired_hash, u128_zero()))
|
||||
{
|
||||
U64 old_hash_slot_idx = key_old_hash.u64[1]%hs_shared->slots_count;
|
||||
U64 old_hash_slot_idx = key_expired_hash.u64[1]%hs_shared->slots_count;
|
||||
U64 old_hash_stripe_idx = old_hash_slot_idx%hs_shared->stripes_count;
|
||||
HS_Slot *old_hash_slot = &hs_shared->slots[old_hash_slot_idx];
|
||||
HS_Stripe *old_hash_stripe = &hs_shared->stripes[old_hash_stripe_idx];
|
||||
@@ -158,7 +162,7 @@ hs_submit_data(U128 key, Arena **data_arena, String8 data)
|
||||
{
|
||||
for(HS_Node *n = old_hash_slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(u128_match(n->hash, key_old_hash))
|
||||
if(u128_match(n->hash, key_expired_hash))
|
||||
{
|
||||
ins_atomic_u64_dec_eval(&n->key_ref_count);
|
||||
break;
|
||||
@@ -239,7 +243,7 @@ hs_scope_touch_node__stripe_r_guarded(HS_Scope *scope, HS_Node *node)
|
||||
//~ rjf: Cache Lookup
|
||||
|
||||
internal U128
|
||||
hs_hash_from_key(U128 key)
|
||||
hs_hash_from_key(U128 key, U64 rewind_count)
|
||||
{
|
||||
U128 result = {0};
|
||||
U64 key_slot_idx = key.u64[1]%hs_shared->key_slots_count;
|
||||
@@ -250,9 +254,9 @@ hs_hash_from_key(U128 key)
|
||||
{
|
||||
for(HS_KeyNode *n = key_slot->first; n != 0; n = n->next)
|
||||
{
|
||||
if(u128_match(n->key, key))
|
||||
if(u128_match(n->key, key) && n->hash_history_gen > 0 && n->hash_history_gen-1 >= rewind_count)
|
||||
{
|
||||
result = n->hash;
|
||||
result = n->hash_history[(n->hash_history_gen-1-rewind_count)%ArrayCount(n->hash_history)];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,7 +12,8 @@ struct HS_KeyNode
|
||||
{
|
||||
HS_KeyNode *next;
|
||||
U128 key;
|
||||
U128 hash;
|
||||
U128 hash_history[2];
|
||||
U64 hash_history_gen;
|
||||
};
|
||||
|
||||
typedef struct HS_KeySlot HS_KeySlot;
|
||||
@@ -138,7 +139,7 @@ internal void hs_scope_touch_node__stripe_r_guarded(HS_Scope *scope, HS_Node *no
|
||||
////////////////////////////////
|
||||
//~ rjf: Cache Lookups
|
||||
|
||||
internal U128 hs_hash_from_key(U128 key);
|
||||
internal U128 hs_hash_from_key(U128 key, U64 rewind_count);
|
||||
internal String8 hs_data_from_hash(HS_Scope *scope, U128 hash);
|
||||
|
||||
////////////////////////////////
|
||||
|
||||
@@ -199,6 +199,7 @@ internal void os_condition_variable_broadcast(OS_Handle cv);
|
||||
#define OS_MutexScope(mutex) DeferLoop(os_mutex_take(mutex), os_mutex_drop(mutex))
|
||||
#define OS_MutexScopeR(mutex) DeferLoop(os_rw_mutex_take_r(mutex), os_rw_mutex_drop_r(mutex))
|
||||
#define OS_MutexScopeW(mutex) DeferLoop(os_rw_mutex_take_w(mutex), os_rw_mutex_drop_w(mutex))
|
||||
#define OS_MutexScopeRWPromote(mutex) DeferLoop((os_rw_mutex_drop_r(mutex), os_rw_mutex_take_w(mutex)), (os_rw_mutex_drop_w(mutex), os_rw_mutex_take_r(mutex)))
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: @os_hooks Main Initialization API (Implemented Per-OS)
|
||||
|
||||
@@ -493,6 +493,10 @@ w32_wnd_proc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
if(character >= 32 && character != 127)
|
||||
{
|
||||
OS_Event *event = w32_push_event(OS_EventKind_Text, window);
|
||||
if(lParam & bit29)
|
||||
{
|
||||
event->flags |= OS_EventFlag_Alt;
|
||||
}
|
||||
event->character = character;
|
||||
}
|
||||
}break;
|
||||
|
||||
+13
-11
@@ -167,6 +167,10 @@ update_and_render(OS_Handle repaint_window_handle, void *user_data)
|
||||
df_push_cmd__root(¶ms, spec);
|
||||
df_gfx_request_frame();
|
||||
os_eat_event(&events, event);
|
||||
if(event->flags & OS_EventFlag_Alt)
|
||||
{
|
||||
window->menu_bar_focus_press_started = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -182,7 +186,7 @@ update_and_render(OS_Handle repaint_window_handle, void *user_data)
|
||||
continue;
|
||||
}
|
||||
B32 take = 0;
|
||||
if(event->kind == OS_EventKind_Press && event->key == OS_Key_Alt && event->is_repeat == 0)
|
||||
if(event->kind == OS_EventKind_Press && event->key == OS_Key_Alt && event->flags == 0 && event->is_repeat == 0)
|
||||
{
|
||||
take = 1;
|
||||
df_gfx_request_frame();
|
||||
@@ -190,19 +194,19 @@ update_and_render(OS_Handle repaint_window_handle, void *user_data)
|
||||
ws->menu_bar_key_held = 1;
|
||||
ws->menu_bar_focus_press_started = 1;
|
||||
}
|
||||
if(event->kind == OS_EventKind_Release && event->key == OS_Key_Alt && event->is_repeat == 0)
|
||||
if(event->kind == OS_EventKind_Release && event->key == OS_Key_Alt && event->flags == 0 && event->is_repeat == 0)
|
||||
{
|
||||
take = 1;
|
||||
df_gfx_request_frame();
|
||||
ws->menu_bar_key_held = 0;
|
||||
}
|
||||
if(ws->menu_bar_focused && event->kind == OS_EventKind_Press && event->key == OS_Key_Alt && event->is_repeat == 0)
|
||||
if(ws->menu_bar_focused && event->kind == OS_EventKind_Press && event->key == OS_Key_Alt && event->flags == 0 && event->is_repeat == 0)
|
||||
{
|
||||
take = 1;
|
||||
df_gfx_request_frame();
|
||||
ws->menu_bar_focused = 0;
|
||||
}
|
||||
else if(ws->menu_bar_focus_press_started && !ws->menu_bar_focused && event->kind == OS_EventKind_Release && event->key == OS_Key_Alt && event->is_repeat == 0)
|
||||
else if(ws->menu_bar_focus_press_started && !ws->menu_bar_focused && event->kind == OS_EventKind_Release && event->flags == 0 && event->key == OS_Key_Alt && event->is_repeat == 0)
|
||||
{
|
||||
take = 1;
|
||||
df_gfx_request_frame();
|
||||
@@ -318,7 +322,8 @@ update_and_render(OS_Handle repaint_window_handle, void *user_data)
|
||||
}
|
||||
|
||||
//- rjf: gather leftover events for subsequent frame
|
||||
if(events.count != 0)
|
||||
// TODO(rjf): need to prevent spurious unconsumed events in UI layer & other event handling paths
|
||||
if(events.count != 0 && 0)
|
||||
{
|
||||
arena_clear(leftover_events_arena);
|
||||
leftover_events = os_event_list_copy(leftover_events_arena, &events);
|
||||
@@ -327,12 +332,8 @@ update_and_render(OS_Handle repaint_window_handle, void *user_data)
|
||||
next = ev->next;
|
||||
if(ev->timestamp_us+1000000 < os_now_microseconds() ||
|
||||
ev->kind == OS_EventKind_Text ||
|
||||
(ev->kind == OS_EventKind_Press && ev->key != OS_Key_LeftMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Press && ev->key != OS_Key_RightMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Press && ev->key != OS_Key_MiddleMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Release && ev->key != OS_Key_LeftMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Release && ev->key != OS_Key_RightMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Release && ev->key != OS_Key_MiddleMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Press && ev->key != OS_Key_LeftMouseButton && ev->key != OS_Key_RightMouseButton && ev->key != OS_Key_MiddleMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Release && ev->key != OS_Key_LeftMouseButton && ev->key != OS_Key_RightMouseButton && ev->key != OS_Key_MiddleMouseButton) ||
|
||||
(ev->kind == OS_EventKind_Scroll))
|
||||
{
|
||||
os_eat_event(&leftover_events, ev);
|
||||
@@ -454,6 +455,7 @@ entry_point(int argc, char **argv)
|
||||
//- rjf: initialize stuff we depend on
|
||||
{
|
||||
hs_init();
|
||||
fs_init();
|
||||
txt_init();
|
||||
dbgi_init();
|
||||
txti_init();
|
||||
|
||||
+6
-34
@@ -4,17 +4,16 @@
|
||||
////////////////////////////////
|
||||
//~ rjf: Frontend/UI Pass Tasks
|
||||
//
|
||||
// [ ] committing needs to happen when navigating focus away for any reason
|
||||
//
|
||||
// [ ] source view -> floating margin/line-nums
|
||||
// [ ] theme colors -> more explicit about e.g. opaque backgrounds vs. floating
|
||||
// & scrollbars etc.
|
||||
// [ ] drag/drop tab cleanup
|
||||
// [ ] target/breakpoint/watch-pin reordering
|
||||
// [ ] watch window reordering
|
||||
// [x] query views, cleanup & floating - maybe merge "applies to view" vs. not
|
||||
// [ ] standard way to filter
|
||||
// [ ] visualize remapped files (via path map)
|
||||
// [ ] hovering truncated string for a short time -> tooltip with full wrapped
|
||||
// string
|
||||
// [ ] theme lister -> fonts & font sizes
|
||||
// [ ] font lister
|
||||
// [ ] per-panel font size overrides
|
||||
@@ -34,8 +33,6 @@
|
||||
//
|
||||
// [ ] it would be nice to have "show in explorer" for right click on source
|
||||
// file tab (opens explorer & selects the file)
|
||||
// [x] it would be nice if Alt+o in source file would switch between .h and
|
||||
// .c/cpp file (just look for same name in same folder)
|
||||
//
|
||||
// [ ] what's up with decimal number coloring where every group of 3 are in
|
||||
// different color? can I turn it off? And why sometimes digits in number
|
||||
@@ -79,10 +76,7 @@
|
||||
// [ ] investigate /DEBUG:FASTLINK - can we somehow alert that we do not
|
||||
// support it?
|
||||
//
|
||||
// [ ] escaping in config files - breakpoint labels etc.
|
||||
// [ ] focus changing between query bar & panel content via mouse
|
||||
//
|
||||
// [ ] ** while typing, "Alt" Windows menu things should not happen
|
||||
// [x] escaping in config files - breakpoint labels etc.
|
||||
//
|
||||
// [ ] visualize conversion failures
|
||||
//
|
||||
@@ -149,10 +143,6 @@
|
||||
// (partial) matches as you type, so you can stop typing once it gets the
|
||||
// right function instead of having to type the entire function name.
|
||||
//
|
||||
// [ ] Hovering over a source tab that is clipped should probably display the
|
||||
// full thing that was in that tab (like the whole filename, etc.). Right
|
||||
// now, hovering does nothing AFAICT.
|
||||
//
|
||||
// [ ] ** I couldn't figure out how to really view threads in the debugger.
|
||||
// The only place I found a thread list was in "The Scheduler", but it
|
||||
// only lists threads by ID, which is hard to use. I can hover over them
|
||||
@@ -185,18 +175,6 @@
|
||||
// [ ] I had to go into the user file to change the font. That should probably
|
||||
// be in the theme window?
|
||||
//
|
||||
// [ ] The way the "commands" view worked was idiosyncratic. All the other
|
||||
// views stay up, but that one goes away whenever I select a command for
|
||||
// some reason.
|
||||
// [ ] Also, I could not move the commands window anywhere AFAICT. It seems
|
||||
// to just pop up over whatever window I currently have selected. This
|
||||
// would make sense for a hotkey (which I assume is the way it was
|
||||
// designed), but it seems like it should be permanent if you can select
|
||||
// it from the View menu.
|
||||
// [ ] If the command window is not wide enough, you cannot read the
|
||||
// description of a command because it doesn't word-wrap, nor can you
|
||||
// hover over it to get the description in a tooltip (AFAICT).
|
||||
//
|
||||
// [ ] It'd be nice to have a "goto byte" option for source views, for jumping
|
||||
// to error messages that are byte-based instead of line-based.
|
||||
//
|
||||
@@ -219,7 +197,7 @@
|
||||
// opens the context window. It seems like maybe menus should be right,
|
||||
// and left should do the default action, more consistently?
|
||||
//
|
||||
// [ ] Hovering over disassembly highlights blocks of instructions, which I
|
||||
// [x] Hovering over disassembly highlights blocks of instructions, which I
|
||||
// assume correspond to source lines. But perhaps it should also highlight
|
||||
// the source lines? The inverse hover works (you hover over source, and
|
||||
// it highlights ASM), but ASM->source doesn't.
|
||||
@@ -230,8 +208,6 @@
|
||||
// "save" option in the menus.
|
||||
//
|
||||
// [ ] @cleanup @feature double & triple click select in source views
|
||||
// [ ] @feature hovering truncated text in UI for some amount of time -> show
|
||||
// tooltip with full text
|
||||
// [ ] @feature disasm keyboard navigation & copy/paste
|
||||
// [ ] @feature debug info overrides (both path-based AND module-based)
|
||||
// [ ] configure tab size
|
||||
@@ -239,15 +215,11 @@
|
||||
// - place temp bp, attach "die on hit" flag or something like that?
|
||||
// [ ] auto-scroll output window
|
||||
//
|
||||
// [ ] C++ single & multi inheritance member visualization in watch window
|
||||
// [ ] C++ virtual inheritance member visualization in watch window
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Hot, Low Priority Tasks (UI Opinions, Less-Serious Jank, Preferences, Cleanup)
|
||||
//
|
||||
// [ ] ** Directory picking is kind of busted, as it goes through the same
|
||||
// path as file picking, and this doesn't give the user a clean path to
|
||||
// actually pick a folder, just navigate with them
|
||||
//
|
||||
// [ ] ** In the call stack, I would like to be able to click quickly and move
|
||||
// around the stack. Right now, you can do that with the first and third
|
||||
// column, but the second column drops down a context menu. Since right
|
||||
@@ -446,7 +418,7 @@
|
||||
|
||||
#define RADDBG_VERSION_MAJOR 0
|
||||
#define RADDBG_VERSION_MINOR 9
|
||||
#define RADDBG_VERSION_PATCH 6
|
||||
#define RADDBG_VERSION_PATCH 7
|
||||
#define RADDBG_VERSION_STRING_LITERAL Stringify(RADDBG_VERSION_MAJOR) "." Stringify(RADDBG_VERSION_MINOR) "." Stringify(RADDBG_VERSION_PATCH)
|
||||
#if defined(NDEBUG)
|
||||
# define RADDBG_TITLE_STRING_LITERAL "The RAD Debugger (" RADDBG_VERSION_STRING_LITERAL " ALPHA) - " __DATE__ ""
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "os/os_inc.h"
|
||||
#include "mdesk/mdesk.h"
|
||||
#include "hash_store/hash_store.h"
|
||||
#include "file_stream/file_stream.h"
|
||||
#include "text_cache/text_cache.h"
|
||||
#include "path/path.h"
|
||||
#include "txti/txti.h"
|
||||
@@ -49,6 +50,7 @@
|
||||
#include "os/os_inc.c"
|
||||
#include "mdesk/mdesk.c"
|
||||
#include "hash_store/hash_store.c"
|
||||
#include "file_stream/file_stream.c"
|
||||
#include "text_cache/text_cache.c"
|
||||
#include "path/path.c"
|
||||
#include "txti/txti.c"
|
||||
|
||||
@@ -399,8 +399,6 @@ cons_bake_file(Arena *arena, CONS_Root *root, String8List *out){
|
||||
MemoryCopy(out_ptr, node->idx_run, sizeof(*node->idx_run)*node->count);
|
||||
out_ptr += node->count;
|
||||
}
|
||||
// both iterators should reach the end at the same time
|
||||
Assert(node == 0);
|
||||
Assert(out_ptr == opl);
|
||||
}
|
||||
|
||||
|
||||
@@ -2709,7 +2709,7 @@ typedef struct CV_LeafVFPath{
|
||||
// CV_TypeId[count] base;
|
||||
} CV_LeafVFPath;
|
||||
|
||||
// (LeafKind: CLASS2, CLASS2)
|
||||
// (LeafKind: CLASS2, STRUCT2)
|
||||
typedef struct CV_LeafStruct2{
|
||||
// NOTE: still reverse engineering this - if you find docs please help!
|
||||
CV_TypeProps props;
|
||||
@@ -2718,12 +2718,11 @@ typedef struct CV_LeafStruct2{
|
||||
CV_TypeId derived_itype;
|
||||
CV_TypeId vshape_itype;
|
||||
U16 unknown2;
|
||||
U16 size;
|
||||
// CV_Numeric size
|
||||
// U8[] name (null terminated)
|
||||
// U8[] unique_name (null terminated)
|
||||
} CV_LeafStruct2;
|
||||
|
||||
|
||||
// (LeafIDKind: FUNC_ID)
|
||||
typedef struct CV_LeafFuncId{
|
||||
CV_ItemId scope_string_id;
|
||||
|
||||
@@ -2054,7 +2054,7 @@ cv_stringize_leaf_range(Arena *arena, String8List *out,
|
||||
str8_list_pushf(arena, out, " derived_itype=%u\n", struct2->derived_itype);
|
||||
str8_list_pushf(arena, out, " vshape_itype=%u\n", struct2->vshape_itype);
|
||||
str8_list_pushf(arena, out, " unknown2=0x%x\n", struct2->unknown2);
|
||||
str8_list_pushf(arena, out, " size=%u\n", struct2->size);
|
||||
//str8_list_pushf(arena, out, " size=%u\n", struct2->size);
|
||||
|
||||
String8 name = str8_cstring_capped((U8*)(struct2 + 1), first + cap);
|
||||
str8_list_pushf(arena, out, " name='%.*s'\n", str8_varg(name));
|
||||
|
||||
@@ -294,6 +294,38 @@ pdbconv_type_resolve_fwd(PDBCONV_Ctx *ctx, CV_TypeId itype){
|
||||
}
|
||||
}break;
|
||||
|
||||
case CV_LeafKind_CLASS2:
|
||||
case CV_LeafKind_STRUCT2:
|
||||
{
|
||||
// TODO(allen): error if bad range
|
||||
if (sizeof(CV_LeafStruct2) <= cap){
|
||||
CV_LeafStruct2 *lf_struct = (CV_LeafStruct2*)first;
|
||||
|
||||
// size
|
||||
U8 *numeric_ptr = (U8*)(lf_struct + 1);
|
||||
CV_NumericParsed size = cv_numeric_from_data_range(numeric_ptr, first + cap);
|
||||
|
||||
// name
|
||||
U8 *name_ptr = (U8 *)numeric_ptr + size.encoded_size;
|
||||
String8 name = str8_cstring_capped((char*)name_ptr, first + cap);
|
||||
|
||||
// unique name
|
||||
U8 *unique_name_ptr = name_ptr + name.size + 1;
|
||||
String8 unique_name = str8_cstring_capped((char*)unique_name_ptr, first + cap);
|
||||
|
||||
if (lf_struct->props & CV_TypeProp_FwdRef){
|
||||
B32 do_unique_name_lookup = ((lf_struct->props & CV_TypeProp_Scoped) != 0) &&
|
||||
((lf_struct->props & CV_TypeProp_HasUniqueName) != 0);
|
||||
if (do_unique_name_lookup){
|
||||
result = pdb_tpi_first_itype_from_name(ctx->hash, ctx->leaf, unique_name, 1);
|
||||
}
|
||||
else{
|
||||
result = pdb_tpi_first_itype_from_name(ctx->hash, ctx->leaf, name, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
}break;
|
||||
|
||||
case CV_LeafKind_UNION:
|
||||
{
|
||||
// TODO(allen): error if bad range
|
||||
@@ -1371,10 +1403,20 @@ pdbconv_type_cons_leaf_record(PDBCONV_Ctx *ctx, CV_TypeId itype){
|
||||
|
||||
// TODO(allen): handle props
|
||||
|
||||
// size
|
||||
U8 *numeric_ptr = (U8*)(lf_struct + 1);
|
||||
CV_NumericParsed size = cv_numeric_from_data_range(numeric_ptr, first + cap);
|
||||
U64 size_u64 = cv_u64_from_numeric(&size);
|
||||
|
||||
// name
|
||||
U8 *name_ptr = (U8*)(lf_struct + 1);
|
||||
U8 *name_ptr = numeric_ptr + size.encoded_size;
|
||||
String8 name = str8_cstring_capped((char*)name_ptr, first + cap);
|
||||
|
||||
if(str8_match(name, str8_lit("Foo"), 0))
|
||||
{
|
||||
int x = 0;
|
||||
}
|
||||
|
||||
// incomplete type
|
||||
if (lf_struct->props & CV_TypeProp_FwdRef){
|
||||
RADDBG_TypeKind type_kind = RADDBG_TypeKind_IncompleteStruct;
|
||||
@@ -1390,7 +1432,7 @@ pdbconv_type_cons_leaf_record(PDBCONV_Ctx *ctx, CV_TypeId itype){
|
||||
if (range->hdr.kind == CV_LeafKind_CLASS2){
|
||||
type_kind = RADDBG_TypeKind_Class;
|
||||
}
|
||||
result = cons_type_udt(ctx->root, type_kind, name, lf_struct->size);
|
||||
result = cons_type_udt(ctx->root, type_kind, name, size_u64);
|
||||
|
||||
// remember to revisit this for members
|
||||
{
|
||||
@@ -3243,7 +3285,7 @@ str8_list_pushf(arena, &out->errors, fmt, __VA_ARGS__);\
|
||||
{
|
||||
if(sym_for_unit[comp_unit_idx] != 0)
|
||||
{
|
||||
architecture = raddbg_arch_from_cv_arch(sym_for_unit[0]->info.arch);
|
||||
architecture = raddbg_arch_from_cv_arch(sym_for_unit[comp_unit_idx]->info.arch);
|
||||
if(architecture != 0)
|
||||
{
|
||||
break;
|
||||
|
||||
@@ -846,6 +846,36 @@ pdb_tpi_itypes_from_name(Arena *arena, PDB_TpiHashParsed *tpi_hash, CV_LeafParse
|
||||
}
|
||||
}break;
|
||||
|
||||
case CV_LeafKind_CLASS2:
|
||||
case CV_LeafKind_STRUCT2:
|
||||
{
|
||||
if (sizeof(CV_LeafStruct2) <= cap){
|
||||
CV_LeafStruct2 *lf_struct = (CV_LeafStruct2*)first;
|
||||
|
||||
if (!(lf_struct->props & CV_TypeProp_FwdRef)){
|
||||
// size
|
||||
U8 *numeric_ptr = (U8*)(lf_struct + 1);
|
||||
CV_NumericParsed size = cv_numeric_from_data_range(numeric_ptr, first + cap);
|
||||
|
||||
// name
|
||||
U8 *name_ptr = numeric_ptr + size.encoded_size;
|
||||
String8 name = str8_cstring_capped((char*)name_ptr, (char *)(first + cap));
|
||||
|
||||
// unique name
|
||||
if (compare_unique_name){
|
||||
if (lf_struct->props & CV_TypeProp_HasUniqueName) {
|
||||
U8 *unique_name_ptr = name_ptr + name.size + 1;
|
||||
String8 unique_name = str8_cstring_capped((char*)unique_name_ptr, (char *)(first + cap));
|
||||
extracted_name = unique_name;
|
||||
}
|
||||
}
|
||||
else{
|
||||
extracted_name = name;
|
||||
}
|
||||
}
|
||||
}
|
||||
}break;
|
||||
|
||||
case CV_LeafKind_UNION:
|
||||
{
|
||||
if (sizeof(CV_LeafUnion) <= cap){
|
||||
|
||||
@@ -168,30 +168,34 @@ str8_lit_comp(
|
||||
" // rjf: determine SDF sample position\n"
|
||||
" float2 sdf_sample_pos = vertex2pixel.sdf_sample_pos;\n"
|
||||
" \n"
|
||||
" // rjf: sample for corners\n"
|
||||
" float corner_sdf_s = rect_sdf(sdf_sample_pos,\n"
|
||||
" vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f),\n"
|
||||
" vertex2pixel.corner_radius_px);\n"
|
||||
" float corner_sdf_t = 1-smoothstep(0, 2*vertex2pixel.softness_px, corner_sdf_s);\n"
|
||||
" \n"
|
||||
" // rjf: sample for borders\n"
|
||||
" float border_sdf_s = rect_sdf(sdf_sample_pos,\n"
|
||||
" vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f) - vertex2pixel.border_thickness_px,\n"
|
||||
" max(vertex2pixel.corner_radius_px-vertex2pixel.border_thickness_px, 0));\n"
|
||||
" float border_sdf_t = smoothstep(0, 2*vertex2pixel.softness_px, border_sdf_s);\n"
|
||||
" if(vertex2pixel.border_thickness_px == 0)\n"
|
||||
" float border_sdf_t = 1;\n"
|
||||
" if(vertex2pixel.border_thickness_px > 0)\n"
|
||||
" {\n"
|
||||
" border_sdf_t = 1;\n"
|
||||
" float border_sdf_s = rect_sdf(sdf_sample_pos,\n"
|
||||
" vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f) - vertex2pixel.border_thickness_px,\n"
|
||||
" max(vertex2pixel.corner_radius_px-vertex2pixel.border_thickness_px, 0));\n"
|
||||
" border_sdf_t = smoothstep(0, 2*vertex2pixel.softness_px, border_sdf_s);\n"
|
||||
" }\n"
|
||||
" if(border_sdf_t < 0.001f)\n"
|
||||
" {\n"
|
||||
" discard;\n"
|
||||
" }\n"
|
||||
" \n"
|
||||
" // rjf: sample for corners\n"
|
||||
" float corner_sdf_t = 1;\n"
|
||||
" if(vertex2pixel.corner_radius_px > 0 || vertex2pixel.softness_px > 0.75f)\n"
|
||||
" {\n"
|
||||
" float corner_sdf_s = rect_sdf(sdf_sample_pos,\n"
|
||||
" vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f),\n"
|
||||
" vertex2pixel.corner_radius_px);\n"
|
||||
" corner_sdf_t = 1-smoothstep(0, 2*vertex2pixel.softness_px, corner_sdf_s);\n"
|
||||
" }\n"
|
||||
" \n"
|
||||
" // rjf: form+return final color\n"
|
||||
" float4 final_color = albedo_sample;\n"
|
||||
" final_color *= tint;\n"
|
||||
" final_color *= opacity;\n"
|
||||
" final_color.a *= opacity;\n"
|
||||
" final_color.a *= corner_sdf_t;\n"
|
||||
" final_color.a *= border_sdf_t;\n"
|
||||
" return final_color;\n"
|
||||
|
||||
@@ -1300,8 +1300,8 @@ r_window_submit(OS_Handle window, R_Handle window_equip, R_PassList *passes)
|
||||
|
||||
U32 uniform_offset[Axis2_COUNT][2] =
|
||||
{
|
||||
{ 0 * sizeof(R_D3D11_Uniforms_BlurPass) / 16, OffsetOf(R_D3D11_Uniforms_Blur, kernel) / 16 },
|
||||
{ 1 * sizeof(R_D3D11_Uniforms_BlurPass) / 16, OffsetOf(R_D3D11_Uniforms_Blur, kernel) / 16 },
|
||||
{ 0 * sizeof(R_D3D11_Uniforms_BlurPass) / 16, (U32)OffsetOf(R_D3D11_Uniforms_Blur, kernel) / 16 },
|
||||
{ 1 * sizeof(R_D3D11_Uniforms_BlurPass) / 16, (U32)OffsetOf(R_D3D11_Uniforms_Blur, kernel) / 16 },
|
||||
};
|
||||
|
||||
U32 uniform_count[Axis2_COUNT][2] =
|
||||
|
||||
@@ -167,30 +167,34 @@ ps_main(Vertex2Pixel vertex2pixel) : SV_TARGET
|
||||
// rjf: determine SDF sample position
|
||||
float2 sdf_sample_pos = vertex2pixel.sdf_sample_pos;
|
||||
|
||||
// rjf: sample for corners
|
||||
float corner_sdf_s = rect_sdf(sdf_sample_pos,
|
||||
vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f),
|
||||
vertex2pixel.corner_radius_px);
|
||||
float corner_sdf_t = 1-smoothstep(0, 2*vertex2pixel.softness_px, corner_sdf_s);
|
||||
|
||||
// rjf: sample for borders
|
||||
float border_sdf_s = rect_sdf(sdf_sample_pos,
|
||||
vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f) - vertex2pixel.border_thickness_px,
|
||||
max(vertex2pixel.corner_radius_px-vertex2pixel.border_thickness_px, 0));
|
||||
float border_sdf_t = smoothstep(0, 2*vertex2pixel.softness_px, border_sdf_s);
|
||||
if(vertex2pixel.border_thickness_px == 0)
|
||||
float border_sdf_t = 1;
|
||||
if(vertex2pixel.border_thickness_px > 0)
|
||||
{
|
||||
border_sdf_t = 1;
|
||||
float border_sdf_s = rect_sdf(sdf_sample_pos,
|
||||
vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f) - vertex2pixel.border_thickness_px,
|
||||
max(vertex2pixel.corner_radius_px-vertex2pixel.border_thickness_px, 0));
|
||||
border_sdf_t = smoothstep(0, 2*vertex2pixel.softness_px, border_sdf_s);
|
||||
}
|
||||
if(border_sdf_t < 0.001f)
|
||||
{
|
||||
discard;
|
||||
}
|
||||
|
||||
// rjf: sample for corners
|
||||
float corner_sdf_t = 1;
|
||||
if(vertex2pixel.corner_radius_px > 0 || vertex2pixel.softness_px > 0.75f)
|
||||
{
|
||||
float corner_sdf_s = rect_sdf(sdf_sample_pos,
|
||||
vertex2pixel.rect_half_size_px - float2(vertex2pixel.softness_px*2.f, vertex2pixel.softness_px*2.f),
|
||||
vertex2pixel.corner_radius_px);
|
||||
corner_sdf_t = 1-smoothstep(0, 2*vertex2pixel.softness_px, corner_sdf_s);
|
||||
}
|
||||
|
||||
// rjf: form+return final color
|
||||
float4 final_color = albedo_sample;
|
||||
final_color *= tint;
|
||||
final_color *= opacity;
|
||||
final_color.a *= opacity;
|
||||
final_color.a *= corner_sdf_t;
|
||||
final_color.a *= border_sdf_t;
|
||||
return final_color;
|
||||
|
||||
@@ -1,20 +1,30 @@
|
||||
#include <fstream>
|
||||
|
||||
namespace SomeWeirdNamespace
|
||||
struct Bar
|
||||
{
|
||||
int X = 0;
|
||||
int Y = 0;
|
||||
void Foo(void)
|
||||
{
|
||||
X = 123;
|
||||
Y = 456;
|
||||
int x = 0;
|
||||
}
|
||||
}
|
||||
int x;
|
||||
int y;
|
||||
int z;
|
||||
};
|
||||
|
||||
int main()
|
||||
struct BarContainer
|
||||
{
|
||||
std::fstream temp;
|
||||
SomeWeirdNamespace::Foo();
|
||||
Bar *bar;
|
||||
int bar_count;
|
||||
int bar_cap;
|
||||
};
|
||||
|
||||
struct Foo
|
||||
{
|
||||
BarContainer bar;
|
||||
int a;
|
||||
int b;
|
||||
int c;
|
||||
};
|
||||
|
||||
int main(void)
|
||||
{
|
||||
Bar bar[100] = {0};
|
||||
Foo foo_ = {bar, 50, sizeof(bar)/sizeof(Bar)};
|
||||
Foo &foo = foo_;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,17 +1,25 @@
|
||||
// Copyright (c) 2024 Epic Games Tools
|
||||
// Licensed under the MIT license (https://opensource.org/license/mit/)
|
||||
|
||||
int Foo(int x, int y)
|
||||
{
|
||||
return x + y;
|
||||
}
|
||||
#include <Windows.h>
|
||||
|
||||
int main(void)
|
||||
{
|
||||
for(int i = 0; i < 1000; i += 1)
|
||||
{
|
||||
int x = 23;
|
||||
int y = 45;
|
||||
Foo(x, y);
|
||||
OutputDebugStringA("Hello, this is a long string which is being output in loop #1.\n");
|
||||
}
|
||||
for(int i = 0; i < 1000; i += 1)
|
||||
{
|
||||
OutputDebugStringA("Hello, this is a long string which is being output in loop #2.\n");
|
||||
}
|
||||
for(int i = 0; i < 1000; i += 1)
|
||||
{
|
||||
OutputDebugStringA("Hello, this is a long string which is being output in loop #3.\n");
|
||||
}
|
||||
for(int i = 0; i < 1000; i += 1)
|
||||
{
|
||||
OutputDebugStringA("Hello, this is a long string which is being output in loop #4.\n");
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
+29
-21
@@ -821,13 +821,15 @@ txti_expr_range_from_line_off_range_string_tokens(U64 off, Rng1U64 line_range, S
|
||||
default:{}break;
|
||||
case TXTI_TokenKind_Symbol:
|
||||
{
|
||||
B32 is_scope_resolution = str8_match(wb_token_string, str8_lit("::"), 0);
|
||||
B32 is_dot = str8_match(wb_token_string, str8_lit("."), 0);
|
||||
B32 is_arrow = str8_match(wb_token_string, str8_lit("->"), 0);
|
||||
B32 is_open_bracket = str8_match(wb_token_string, str8_lit("["), 0);
|
||||
B32 is_close_bracket = str8_match(wb_token_string, str8_lit("]"), 0);
|
||||
nest -= !!(is_open_bracket);
|
||||
nest += !!(is_close_bracket);
|
||||
if(is_dot ||
|
||||
if(is_scope_resolution ||
|
||||
is_dot ||
|
||||
is_arrow ||
|
||||
is_open_bracket||
|
||||
is_close_bracket)
|
||||
@@ -980,7 +982,7 @@ txti_mut_thread_entry_point(void *p)
|
||||
String8 file_contents = {0};
|
||||
TXTI_LangKind lang_kind = TXTI_LangKind_Null;
|
||||
U64 timestamp = 0;
|
||||
if(msg->kind == TXTI_MsgKind_Reload)
|
||||
if(msg->kind == TXTI_MsgKind_Reload) ProfScope("reload file")
|
||||
{
|
||||
FileProperties pre_load_props = os_properties_from_file_path(msg->string);
|
||||
OS_Handle file = os_file_open(OS_AccessFlag_Read|OS_AccessFlag_ShareRead|OS_AccessFlag_ShareWrite, msg->string);
|
||||
@@ -1036,7 +1038,7 @@ txti_mut_thread_entry_point(void *p)
|
||||
|
||||
//- rjf: obtain initial buffer_apply_gen, reset byte processing counters
|
||||
U64 initial_buffer_apply_gen = 0;
|
||||
if(load_valid) OS_MutexScopeR(stripe->rw_mutex)
|
||||
ProfScope("obtain initial buffer_apply_gen") OS_MutexScopeR(stripe->rw_mutex)
|
||||
{
|
||||
TXTI_Entity *entity = 0;
|
||||
for(TXTI_Entity *e = slot->first; e != 0; e = e->next)
|
||||
@@ -1059,17 +1061,19 @@ txti_mut_thread_entry_point(void *p)
|
||||
}
|
||||
|
||||
//- rjf: apply edits
|
||||
ProfScope("apply edits")
|
||||
{
|
||||
for(U64 buffer_apply_idx = 0;
|
||||
buffer_apply_idx < TXTI_ENTITY_BUFFER_COUNT;
|
||||
buffer_apply_idx += 1)
|
||||
ProfScope("apply edit #%i", (int)buffer_apply_idx)
|
||||
{
|
||||
// rjf: last buffer we're going to edit? -> bump buffer_apply_gen,
|
||||
// so that before we touch this last buffer, all readers of this
|
||||
// entity will get the already-modified buffers.
|
||||
if(buffer_apply_idx == TXTI_ENTITY_BUFFER_COUNT-1)
|
||||
{
|
||||
OS_MutexScopeW(stripe->rw_mutex)
|
||||
ProfScope("exclusive lock -> buffer swap") OS_MutexScopeW(stripe->rw_mutex)
|
||||
{
|
||||
TXTI_Entity *entity = 0;
|
||||
for(TXTI_Entity *e = slot->first; e != 0; e = e->next)
|
||||
@@ -1107,7 +1111,7 @@ txti_mut_thread_entry_point(void *p)
|
||||
// exclusive lock to bump the buffer_apply_gen (to change the
|
||||
// actively viewable buffer).
|
||||
//
|
||||
OS_MutexScopeR(stripe->rw_mutex)
|
||||
ProfScope("apply edit") OS_MutexScopeR(stripe->rw_mutex)
|
||||
{
|
||||
TXTI_Entity *entity = 0;
|
||||
for(TXTI_Entity *e = slot->first; e != 0; e = e->next)
|
||||
@@ -1162,6 +1166,7 @@ txti_mut_thread_entry_point(void *p)
|
||||
}
|
||||
|
||||
// rjf: parse & store line range info
|
||||
ProfScope("parse & store line range info")
|
||||
{
|
||||
// rjf: count # of lines
|
||||
U64 line_count = 1;
|
||||
@@ -1184,31 +1189,34 @@ txti_mut_thread_entry_point(void *p)
|
||||
}
|
||||
|
||||
// rjf: allocate & store line ranges
|
||||
buffer->lines_count = line_count;
|
||||
buffer->lines_ranges = push_array_no_zero(buffer->analysis_arena, Rng1U64, buffer->lines_count);
|
||||
U64 line_idx = 0;
|
||||
U64 line_start_idx = 0;
|
||||
for(U64 idx = 0; idx <= buffer->data.size; idx += 1)
|
||||
ProfScope("allocate & store line ranges")
|
||||
{
|
||||
if(idx == buffer->data.size || buffer->data.str[idx] == '\n' || buffer->data.str[idx] == '\r')
|
||||
buffer->lines_count = line_count;
|
||||
buffer->lines_ranges = push_array_no_zero(buffer->analysis_arena, Rng1U64, buffer->lines_count);
|
||||
U64 line_idx = 0;
|
||||
U64 line_start_idx = 0;
|
||||
for(U64 idx = 0; idx <= buffer->data.size; idx += 1)
|
||||
{
|
||||
Rng1U64 line_range = r1u64(line_start_idx, idx);
|
||||
U64 line_size = dim_1u64(line_range);
|
||||
buffer->lines_ranges[line_idx] = line_range;
|
||||
buffer->lines_max_size = Max(buffer->lines_max_size, line_size);
|
||||
line_idx += 1;
|
||||
line_start_idx = idx+1;
|
||||
if(idx < buffer->data.size && buffer->data.str[idx] == '\r')
|
||||
if(idx == buffer->data.size || buffer->data.str[idx] == '\n' || buffer->data.str[idx] == '\r')
|
||||
{
|
||||
line_start_idx += 1;
|
||||
idx += 1;
|
||||
Rng1U64 line_range = r1u64(line_start_idx, idx);
|
||||
U64 line_size = dim_1u64(line_range);
|
||||
buffer->lines_ranges[line_idx] = line_range;
|
||||
buffer->lines_max_size = Max(buffer->lines_max_size, line_size);
|
||||
line_idx += 1;
|
||||
line_start_idx = idx+1;
|
||||
if(idx < buffer->data.size && buffer->data.str[idx] == '\r')
|
||||
{
|
||||
line_start_idx += 1;
|
||||
idx += 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// rjf: lex file contents
|
||||
if(lex_function != 0)
|
||||
if(lex_function != 0) ProfScope("lex text")
|
||||
{
|
||||
buffer->tokens = lex_function(buffer->analysis_arena, buffer_apply_idx == 0 ? &entity->bytes_processed : 0, buffer->data);
|
||||
}
|
||||
|
||||
@@ -16,12 +16,14 @@
|
||||
#define UI_FocusHot(v) DeferLoop(ui_push_focus_hot(v), ui_pop_focus_hot())
|
||||
#define UI_FocusActive(v) DeferLoop(ui_push_focus_active(v), ui_pop_focus_active())
|
||||
#define UI_FastpathCodepoint(v) DeferLoop(ui_push_fastpath_codepoint(v), ui_pop_fastpath_codepoint())
|
||||
#define UI_Transparency(v) DeferLoop(ui_push_transparency(v), ui_pop_transparency())
|
||||
#define UI_BackgroundColor(v) DeferLoop(ui_push_background_color(v), ui_pop_background_color())
|
||||
#define UI_TextColor(v) DeferLoop(ui_push_text_color(v), ui_pop_text_color())
|
||||
#define UI_BorderColor(v) DeferLoop(ui_push_border_color(v), ui_pop_border_color())
|
||||
#define UI_OverlayColor(v) DeferLoop(ui_push_overlay_color(v), ui_pop_overlay_color())
|
||||
#define UI_TextSelectColor(v) DeferLoop(ui_push_text_select_color(v), ui_pop_text_select_color())
|
||||
#define UI_TextCursorColor(v) DeferLoop(ui_push_text_cursor_color(v), ui_pop_text_cursor_color())
|
||||
#define UI_Squish(v) DeferLoop(ui_push_squish(v), ui_pop_squish())
|
||||
#define UI_HoverCursor(v) DeferLoop(ui_push_hover_cursor(v), ui_pop_hover_cursor())
|
||||
#define UI_Font(v) DeferLoop(ui_push_font(v), ui_pop_font())
|
||||
#define UI_FontSize(v) DeferLoop(ui_push_font_size(v), ui_pop_font_size())
|
||||
@@ -45,12 +47,14 @@ internal UI_BoxFlags ui_top_flags(void) { UI_StackTopImpl(ui_state, Flags, flags
|
||||
internal UI_FocusKind ui_top_focus_hot(void) { UI_StackTopImpl(ui_state, FocusHot, focus_hot) }
|
||||
internal UI_FocusKind ui_top_focus_active(void) { UI_StackTopImpl(ui_state, FocusActive, focus_active) }
|
||||
internal U32 ui_top_fastpath_codepoint(void) { UI_StackTopImpl(ui_state, FastpathCodepoint, fastpath_codepoint) }
|
||||
internal F32 ui_top_transparency(void) { UI_StackTopImpl(ui_state, Transparency, transparency) }
|
||||
internal Vec4F32 ui_top_background_color(void) { UI_StackTopImpl(ui_state, BackgroundColor, background_color) }
|
||||
internal Vec4F32 ui_top_text_color(void) { UI_StackTopImpl(ui_state, TextColor, text_color) }
|
||||
internal Vec4F32 ui_top_border_color(void) { UI_StackTopImpl(ui_state, BorderColor, border_color) }
|
||||
internal Vec4F32 ui_top_overlay_color(void) { UI_StackTopImpl(ui_state, OverlayColor, overlay_color) }
|
||||
internal Vec4F32 ui_top_text_select_color(void) { UI_StackTopImpl(ui_state, TextSelectColor, text_select_color) }
|
||||
internal Vec4F32 ui_top_text_cursor_color(void) { UI_StackTopImpl(ui_state, TextCursorColor, text_cursor_color) }
|
||||
internal F32 ui_top_squish(void) { UI_StackTopImpl(ui_state, Squish, squish) }
|
||||
internal OS_Cursor ui_top_hover_cursor(void) { UI_StackTopImpl(ui_state, HoverCursor, hover_cursor) }
|
||||
internal F_Tag ui_top_font(void) { UI_StackTopImpl(ui_state, Font, font) }
|
||||
internal F32 ui_top_font_size(void) { UI_StackTopImpl(ui_state, FontSize, font_size) }
|
||||
@@ -73,12 +77,14 @@ internal UI_BoxFlags ui_bottom_flags(void) { UI_StackBottomImpl(ui_state, Flags,
|
||||
internal UI_FocusKind ui_bottom_focus_hot(void) { UI_StackBottomImpl(ui_state, FocusHot, focus_hot) }
|
||||
internal UI_FocusKind ui_bottom_focus_active(void) { UI_StackBottomImpl(ui_state, FocusActive, focus_active) }
|
||||
internal U32 ui_bottom_fastpath_codepoint(void) { UI_StackBottomImpl(ui_state, FastpathCodepoint, fastpath_codepoint) }
|
||||
internal F32 ui_bottom_transparency(void) { UI_StackBottomImpl(ui_state, Transparency, transparency) }
|
||||
internal Vec4F32 ui_bottom_background_color(void) { UI_StackBottomImpl(ui_state, BackgroundColor, background_color) }
|
||||
internal Vec4F32 ui_bottom_text_color(void) { UI_StackBottomImpl(ui_state, TextColor, text_color) }
|
||||
internal Vec4F32 ui_bottom_border_color(void) { UI_StackBottomImpl(ui_state, BorderColor, border_color) }
|
||||
internal Vec4F32 ui_bottom_overlay_color(void) { UI_StackBottomImpl(ui_state, OverlayColor, overlay_color) }
|
||||
internal Vec4F32 ui_bottom_text_select_color(void) { UI_StackBottomImpl(ui_state, TextSelectColor, text_select_color) }
|
||||
internal Vec4F32 ui_bottom_text_cursor_color(void) { UI_StackBottomImpl(ui_state, TextCursorColor, text_cursor_color) }
|
||||
internal F32 ui_bottom_squish(void) { UI_StackBottomImpl(ui_state, Squish, squish) }
|
||||
internal OS_Cursor ui_bottom_hover_cursor(void) { UI_StackBottomImpl(ui_state, HoverCursor, hover_cursor) }
|
||||
internal F_Tag ui_bottom_font(void) { UI_StackBottomImpl(ui_state, Font, font) }
|
||||
internal F32 ui_bottom_font_size(void) { UI_StackBottomImpl(ui_state, FontSize, font_size) }
|
||||
@@ -101,12 +107,14 @@ internal UI_BoxFlags ui_push_flags(UI_BoxFlags v) { UI_StackPushImpl(ui_state, F
|
||||
internal UI_FocusKind ui_push_focus_hot(UI_FocusKind v) { UI_StackPushImpl(ui_state, FocusHot, focus_hot, UI_FocusKind, v) }
|
||||
internal UI_FocusKind ui_push_focus_active(UI_FocusKind v) { UI_StackPushImpl(ui_state, FocusActive, focus_active, UI_FocusKind, v) }
|
||||
internal U32 ui_push_fastpath_codepoint(U32 v) { UI_StackPushImpl(ui_state, FastpathCodepoint, fastpath_codepoint, U32, v) }
|
||||
internal F32 ui_push_transparency(F32 v) { UI_StackPushImpl(ui_state, Transparency, transparency, F32, v) }
|
||||
internal Vec4F32 ui_push_background_color(Vec4F32 v) { UI_StackPushImpl(ui_state, BackgroundColor, background_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_push_text_color(Vec4F32 v) { UI_StackPushImpl(ui_state, TextColor, text_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_push_border_color(Vec4F32 v) { UI_StackPushImpl(ui_state, BorderColor, border_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_push_overlay_color(Vec4F32 v) { UI_StackPushImpl(ui_state, OverlayColor, overlay_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_push_text_select_color(Vec4F32 v) { UI_StackPushImpl(ui_state, TextSelectColor, text_select_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_push_text_cursor_color(Vec4F32 v) { UI_StackPushImpl(ui_state, TextCursorColor, text_cursor_color, Vec4F32, v) }
|
||||
internal F32 ui_push_squish(F32 v) { UI_StackPushImpl(ui_state, Squish, squish, F32, v) }
|
||||
internal OS_Cursor ui_push_hover_cursor(OS_Cursor v) { UI_StackPushImpl(ui_state, HoverCursor, hover_cursor, OS_Cursor, v) }
|
||||
internal F_Tag ui_push_font(F_Tag v) { UI_StackPushImpl(ui_state, Font, font, F_Tag, v) }
|
||||
internal F32 ui_push_font_size(F32 v) { UI_StackPushImpl(ui_state, FontSize, font_size, F32, v) }
|
||||
@@ -129,12 +137,14 @@ internal UI_BoxFlags ui_pop_flags(void) { UI_StackPopImpl(ui_state, Flags, flags
|
||||
internal UI_FocusKind ui_pop_focus_hot(void) { UI_StackPopImpl(ui_state, FocusHot, focus_hot) }
|
||||
internal UI_FocusKind ui_pop_focus_active(void) { UI_StackPopImpl(ui_state, FocusActive, focus_active) }
|
||||
internal U32 ui_pop_fastpath_codepoint(void) { UI_StackPopImpl(ui_state, FastpathCodepoint, fastpath_codepoint) }
|
||||
internal F32 ui_pop_transparency(void) { UI_StackPopImpl(ui_state, Transparency, transparency) }
|
||||
internal Vec4F32 ui_pop_background_color(void) { UI_StackPopImpl(ui_state, BackgroundColor, background_color) }
|
||||
internal Vec4F32 ui_pop_text_color(void) { UI_StackPopImpl(ui_state, TextColor, text_color) }
|
||||
internal Vec4F32 ui_pop_border_color(void) { UI_StackPopImpl(ui_state, BorderColor, border_color) }
|
||||
internal Vec4F32 ui_pop_overlay_color(void) { UI_StackPopImpl(ui_state, OverlayColor, overlay_color) }
|
||||
internal Vec4F32 ui_pop_text_select_color(void) { UI_StackPopImpl(ui_state, TextSelectColor, text_select_color) }
|
||||
internal Vec4F32 ui_pop_text_cursor_color(void) { UI_StackPopImpl(ui_state, TextCursorColor, text_cursor_color) }
|
||||
internal F32 ui_pop_squish(void) { UI_StackPopImpl(ui_state, Squish, squish) }
|
||||
internal OS_Cursor ui_pop_hover_cursor(void) { UI_StackPopImpl(ui_state, HoverCursor, hover_cursor) }
|
||||
internal F_Tag ui_pop_font(void) { UI_StackPopImpl(ui_state, Font, font) }
|
||||
internal F32 ui_pop_font_size(void) { UI_StackPopImpl(ui_state, FontSize, font_size) }
|
||||
@@ -157,12 +167,14 @@ internal UI_BoxFlags ui_set_next_flags(UI_BoxFlags v) { UI_StackSetNextImpl(ui_s
|
||||
internal UI_FocusKind ui_set_next_focus_hot(UI_FocusKind v) { UI_StackSetNextImpl(ui_state, FocusHot, focus_hot, UI_FocusKind, v) }
|
||||
internal UI_FocusKind ui_set_next_focus_active(UI_FocusKind v) { UI_StackSetNextImpl(ui_state, FocusActive, focus_active, UI_FocusKind, v) }
|
||||
internal U32 ui_set_next_fastpath_codepoint(U32 v) { UI_StackSetNextImpl(ui_state, FastpathCodepoint, fastpath_codepoint, U32, v) }
|
||||
internal F32 ui_set_next_transparency(F32 v) { UI_StackSetNextImpl(ui_state, Transparency, transparency, F32, v) }
|
||||
internal Vec4F32 ui_set_next_background_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, BackgroundColor, background_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_set_next_text_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, TextColor, text_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_set_next_border_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, BorderColor, border_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_set_next_overlay_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, OverlayColor, overlay_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_set_next_text_select_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, TextSelectColor, text_select_color, Vec4F32, v) }
|
||||
internal Vec4F32 ui_set_next_text_cursor_color(Vec4F32 v) { UI_StackSetNextImpl(ui_state, TextCursorColor, text_cursor_color, Vec4F32, v) }
|
||||
internal F32 ui_set_next_squish(F32 v) { UI_StackSetNextImpl(ui_state, Squish, squish, F32, v) }
|
||||
internal OS_Cursor ui_set_next_hover_cursor(OS_Cursor v) { UI_StackSetNextImpl(ui_state, HoverCursor, hover_cursor, OS_Cursor, v) }
|
||||
internal F_Tag ui_set_next_font(F_Tag v) { UI_StackSetNextImpl(ui_state, Font, font, F_Tag, v) }
|
||||
internal F32 ui_set_next_font_size(F32 v) { UI_StackSetNextImpl(ui_state, FontSize, font_size, F32, v) }
|
||||
|
||||
@@ -18,12 +18,14 @@ typedef struct UI_FlagsNode UI_FlagsNode; struct UI_FlagsNode{UI_FlagsNode *next
|
||||
typedef struct UI_FocusHotNode UI_FocusHotNode; struct UI_FocusHotNode{UI_FocusHotNode *next; UI_FocusKind v;};
|
||||
typedef struct UI_FocusActiveNode UI_FocusActiveNode; struct UI_FocusActiveNode{UI_FocusActiveNode *next; UI_FocusKind v;};
|
||||
typedef struct UI_FastpathCodepointNode UI_FastpathCodepointNode; struct UI_FastpathCodepointNode{UI_FastpathCodepointNode *next; U32 v;};
|
||||
typedef struct UI_TransparencyNode UI_TransparencyNode; struct UI_TransparencyNode{UI_TransparencyNode *next; F32 v;};
|
||||
typedef struct UI_BackgroundColorNode UI_BackgroundColorNode; struct UI_BackgroundColorNode{UI_BackgroundColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_TextColorNode UI_TextColorNode; struct UI_TextColorNode{UI_TextColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_BorderColorNode UI_BorderColorNode; struct UI_BorderColorNode{UI_BorderColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_OverlayColorNode UI_OverlayColorNode; struct UI_OverlayColorNode{UI_OverlayColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_TextSelectColorNode UI_TextSelectColorNode; struct UI_TextSelectColorNode{UI_TextSelectColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_TextCursorColorNode UI_TextCursorColorNode; struct UI_TextCursorColorNode{UI_TextCursorColorNode *next; Vec4F32 v;};
|
||||
typedef struct UI_SquishNode UI_SquishNode; struct UI_SquishNode{UI_SquishNode *next; F32 v;};
|
||||
typedef struct UI_HoverCursorNode UI_HoverCursorNode; struct UI_HoverCursorNode{UI_HoverCursorNode *next; OS_Cursor v;};
|
||||
typedef struct UI_FontNode UI_FontNode; struct UI_FontNode{UI_FontNode *next; F_Tag v;};
|
||||
typedef struct UI_FontSizeNode UI_FontSizeNode; struct UI_FontSizeNode{UI_FontSizeNode *next; F32 v;};
|
||||
@@ -49,12 +51,14 @@ UI_FlagsNode flags_nil_stack_top;\
|
||||
UI_FocusHotNode focus_hot_nil_stack_top;\
|
||||
UI_FocusActiveNode focus_active_nil_stack_top;\
|
||||
UI_FastpathCodepointNode fastpath_codepoint_nil_stack_top;\
|
||||
UI_TransparencyNode transparency_nil_stack_top;\
|
||||
UI_BackgroundColorNode background_color_nil_stack_top;\
|
||||
UI_TextColorNode text_color_nil_stack_top;\
|
||||
UI_BorderColorNode border_color_nil_stack_top;\
|
||||
UI_OverlayColorNode overlay_color_nil_stack_top;\
|
||||
UI_TextSelectColorNode text_select_color_nil_stack_top;\
|
||||
UI_TextCursorColorNode text_cursor_color_nil_stack_top;\
|
||||
UI_SquishNode squish_nil_stack_top;\
|
||||
UI_HoverCursorNode hover_cursor_nil_stack_top;\
|
||||
UI_FontNode font_nil_stack_top;\
|
||||
UI_FontSizeNode font_size_nil_stack_top;\
|
||||
@@ -79,12 +83,14 @@ state->flags_nil_stack_top.v = 0;\
|
||||
state->focus_hot_nil_stack_top.v = UI_FocusKind_Null;\
|
||||
state->focus_active_nil_stack_top.v = UI_FocusKind_Null;\
|
||||
state->fastpath_codepoint_nil_stack_top.v = 0;\
|
||||
state->transparency_nil_stack_top.v = 0;\
|
||||
state->background_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->text_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->border_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->overlay_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->text_select_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->text_cursor_color_nil_stack_top.v = v4f32(1, 0, 1, 1);\
|
||||
state->squish_nil_stack_top.v = 0;\
|
||||
state->hover_cursor_nil_stack_top.v = OS_Cursor_Pointer;\
|
||||
state->font_nil_stack_top.v = f_tag_zero();\
|
||||
state->font_size_nil_stack_top.v = 24.f;\
|
||||
@@ -111,12 +117,14 @@ struct { UI_FlagsNode *top; UI_BoxFlags bottom_val; UI_FlagsNode *free; B32 auto
|
||||
struct { UI_FocusHotNode *top; UI_FocusKind bottom_val; UI_FocusHotNode *free; B32 auto_pop; } focus_hot_stack;\
|
||||
struct { UI_FocusActiveNode *top; UI_FocusKind bottom_val; UI_FocusActiveNode *free; B32 auto_pop; } focus_active_stack;\
|
||||
struct { UI_FastpathCodepointNode *top; U32 bottom_val; UI_FastpathCodepointNode *free; B32 auto_pop; } fastpath_codepoint_stack;\
|
||||
struct { UI_TransparencyNode *top; F32 bottom_val; UI_TransparencyNode *free; B32 auto_pop; } transparency_stack;\
|
||||
struct { UI_BackgroundColorNode *top; Vec4F32 bottom_val; UI_BackgroundColorNode *free; B32 auto_pop; } background_color_stack;\
|
||||
struct { UI_TextColorNode *top; Vec4F32 bottom_val; UI_TextColorNode *free; B32 auto_pop; } text_color_stack;\
|
||||
struct { UI_BorderColorNode *top; Vec4F32 bottom_val; UI_BorderColorNode *free; B32 auto_pop; } border_color_stack;\
|
||||
struct { UI_OverlayColorNode *top; Vec4F32 bottom_val; UI_OverlayColorNode *free; B32 auto_pop; } overlay_color_stack;\
|
||||
struct { UI_TextSelectColorNode *top; Vec4F32 bottom_val; UI_TextSelectColorNode *free; B32 auto_pop; } text_select_color_stack;\
|
||||
struct { UI_TextCursorColorNode *top; Vec4F32 bottom_val; UI_TextCursorColorNode *free; B32 auto_pop; } text_cursor_color_stack;\
|
||||
struct { UI_SquishNode *top; F32 bottom_val; UI_SquishNode *free; B32 auto_pop; } squish_stack;\
|
||||
struct { UI_HoverCursorNode *top; OS_Cursor bottom_val; UI_HoverCursorNode *free; B32 auto_pop; } hover_cursor_stack;\
|
||||
struct { UI_FontNode *top; F_Tag bottom_val; UI_FontNode *free; B32 auto_pop; } font_stack;\
|
||||
struct { UI_FontSizeNode *top; F32 bottom_val; UI_FontSizeNode *free; B32 auto_pop; } font_size_stack;\
|
||||
@@ -141,12 +149,14 @@ state->flags_stack.top = &state->flags_nil_stack_top; state->flags_stack.bottom_
|
||||
state->focus_hot_stack.top = &state->focus_hot_nil_stack_top; state->focus_hot_stack.bottom_val = UI_FocusKind_Null; state->focus_hot_stack.free = 0; state->focus_hot_stack.auto_pop = 0;\
|
||||
state->focus_active_stack.top = &state->focus_active_nil_stack_top; state->focus_active_stack.bottom_val = UI_FocusKind_Null; state->focus_active_stack.free = 0; state->focus_active_stack.auto_pop = 0;\
|
||||
state->fastpath_codepoint_stack.top = &state->fastpath_codepoint_nil_stack_top; state->fastpath_codepoint_stack.bottom_val = 0; state->fastpath_codepoint_stack.free = 0; state->fastpath_codepoint_stack.auto_pop = 0;\
|
||||
state->transparency_stack.top = &state->transparency_nil_stack_top; state->transparency_stack.bottom_val = 0; state->transparency_stack.free = 0; state->transparency_stack.auto_pop = 0;\
|
||||
state->background_color_stack.top = &state->background_color_nil_stack_top; state->background_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->background_color_stack.free = 0; state->background_color_stack.auto_pop = 0;\
|
||||
state->text_color_stack.top = &state->text_color_nil_stack_top; state->text_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->text_color_stack.free = 0; state->text_color_stack.auto_pop = 0;\
|
||||
state->border_color_stack.top = &state->border_color_nil_stack_top; state->border_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->border_color_stack.free = 0; state->border_color_stack.auto_pop = 0;\
|
||||
state->overlay_color_stack.top = &state->overlay_color_nil_stack_top; state->overlay_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->overlay_color_stack.free = 0; state->overlay_color_stack.auto_pop = 0;\
|
||||
state->text_select_color_stack.top = &state->text_select_color_nil_stack_top; state->text_select_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->text_select_color_stack.free = 0; state->text_select_color_stack.auto_pop = 0;\
|
||||
state->text_cursor_color_stack.top = &state->text_cursor_color_nil_stack_top; state->text_cursor_color_stack.bottom_val = v4f32(1, 0, 1, 1); state->text_cursor_color_stack.free = 0; state->text_cursor_color_stack.auto_pop = 0;\
|
||||
state->squish_stack.top = &state->squish_nil_stack_top; state->squish_stack.bottom_val = 0; state->squish_stack.free = 0; state->squish_stack.auto_pop = 0;\
|
||||
state->hover_cursor_stack.top = &state->hover_cursor_nil_stack_top; state->hover_cursor_stack.bottom_val = OS_Cursor_Pointer; state->hover_cursor_stack.free = 0; state->hover_cursor_stack.auto_pop = 0;\
|
||||
state->font_stack.top = &state->font_nil_stack_top; state->font_stack.bottom_val = f_tag_zero(); state->font_stack.free = 0; state->font_stack.auto_pop = 0;\
|
||||
state->font_size_stack.top = &state->font_size_nil_stack_top; state->font_size_stack.bottom_val = 24.f; state->font_size_stack.free = 0; state->font_size_stack.auto_pop = 0;\
|
||||
@@ -171,12 +181,14 @@ if(state->flags_stack.auto_pop) { ui_pop_flags(); state->flags_stack.auto_pop =
|
||||
if(state->focus_hot_stack.auto_pop) { ui_pop_focus_hot(); state->focus_hot_stack.auto_pop = 0; }\
|
||||
if(state->focus_active_stack.auto_pop) { ui_pop_focus_active(); state->focus_active_stack.auto_pop = 0; }\
|
||||
if(state->fastpath_codepoint_stack.auto_pop) { ui_pop_fastpath_codepoint(); state->fastpath_codepoint_stack.auto_pop = 0; }\
|
||||
if(state->transparency_stack.auto_pop) { ui_pop_transparency(); state->transparency_stack.auto_pop = 0; }\
|
||||
if(state->background_color_stack.auto_pop) { ui_pop_background_color(); state->background_color_stack.auto_pop = 0; }\
|
||||
if(state->text_color_stack.auto_pop) { ui_pop_text_color(); state->text_color_stack.auto_pop = 0; }\
|
||||
if(state->border_color_stack.auto_pop) { ui_pop_border_color(); state->border_color_stack.auto_pop = 0; }\
|
||||
if(state->overlay_color_stack.auto_pop) { ui_pop_overlay_color(); state->overlay_color_stack.auto_pop = 0; }\
|
||||
if(state->text_select_color_stack.auto_pop) { ui_pop_text_select_color(); state->text_select_color_stack.auto_pop = 0; }\
|
||||
if(state->text_cursor_color_stack.auto_pop) { ui_pop_text_cursor_color(); state->text_cursor_color_stack.auto_pop = 0; }\
|
||||
if(state->squish_stack.auto_pop) { ui_pop_squish(); state->squish_stack.auto_pop = 0; }\
|
||||
if(state->hover_cursor_stack.auto_pop) { ui_pop_hover_cursor(); state->hover_cursor_stack.auto_pop = 0; }\
|
||||
if(state->font_stack.auto_pop) { ui_pop_font(); state->font_stack.auto_pop = 0; }\
|
||||
if(state->font_size_stack.auto_pop) { ui_pop_font_size(); state->font_size_stack.auto_pop = 0; }\
|
||||
@@ -200,12 +212,14 @@ internal UI_BoxFlags ui_top_flags(void);
|
||||
internal UI_FocusKind ui_top_focus_hot(void);
|
||||
internal UI_FocusKind ui_top_focus_active(void);
|
||||
internal U32 ui_top_fastpath_codepoint(void);
|
||||
internal F32 ui_top_transparency(void);
|
||||
internal Vec4F32 ui_top_background_color(void);
|
||||
internal Vec4F32 ui_top_text_color(void);
|
||||
internal Vec4F32 ui_top_border_color(void);
|
||||
internal Vec4F32 ui_top_overlay_color(void);
|
||||
internal Vec4F32 ui_top_text_select_color(void);
|
||||
internal Vec4F32 ui_top_text_cursor_color(void);
|
||||
internal F32 ui_top_squish(void);
|
||||
internal OS_Cursor ui_top_hover_cursor(void);
|
||||
internal F_Tag ui_top_font(void);
|
||||
internal F32 ui_top_font_size(void);
|
||||
@@ -228,12 +242,14 @@ internal UI_BoxFlags ui_bottom_flags(void);
|
||||
internal UI_FocusKind ui_bottom_focus_hot(void);
|
||||
internal UI_FocusKind ui_bottom_focus_active(void);
|
||||
internal U32 ui_bottom_fastpath_codepoint(void);
|
||||
internal F32 ui_bottom_transparency(void);
|
||||
internal Vec4F32 ui_bottom_background_color(void);
|
||||
internal Vec4F32 ui_bottom_text_color(void);
|
||||
internal Vec4F32 ui_bottom_border_color(void);
|
||||
internal Vec4F32 ui_bottom_overlay_color(void);
|
||||
internal Vec4F32 ui_bottom_text_select_color(void);
|
||||
internal Vec4F32 ui_bottom_text_cursor_color(void);
|
||||
internal F32 ui_bottom_squish(void);
|
||||
internal OS_Cursor ui_bottom_hover_cursor(void);
|
||||
internal F_Tag ui_bottom_font(void);
|
||||
internal F32 ui_bottom_font_size(void);
|
||||
@@ -256,12 +272,14 @@ internal UI_BoxFlags ui_push_flags(UI_BoxFlags v);
|
||||
internal UI_FocusKind ui_push_focus_hot(UI_FocusKind v);
|
||||
internal UI_FocusKind ui_push_focus_active(UI_FocusKind v);
|
||||
internal U32 ui_push_fastpath_codepoint(U32 v);
|
||||
internal F32 ui_push_transparency(F32 v);
|
||||
internal Vec4F32 ui_push_background_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_border_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_overlay_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_select_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_cursor_color(Vec4F32 v);
|
||||
internal F32 ui_push_squish(F32 v);
|
||||
internal OS_Cursor ui_push_hover_cursor(OS_Cursor v);
|
||||
internal F_Tag ui_push_font(F_Tag v);
|
||||
internal F32 ui_push_font_size(F32 v);
|
||||
@@ -284,12 +302,14 @@ internal UI_BoxFlags ui_pop_flags(void);
|
||||
internal UI_FocusKind ui_pop_focus_hot(void);
|
||||
internal UI_FocusKind ui_pop_focus_active(void);
|
||||
internal U32 ui_pop_fastpath_codepoint(void);
|
||||
internal F32 ui_pop_transparency(void);
|
||||
internal Vec4F32 ui_pop_background_color(void);
|
||||
internal Vec4F32 ui_pop_text_color(void);
|
||||
internal Vec4F32 ui_pop_border_color(void);
|
||||
internal Vec4F32 ui_pop_overlay_color(void);
|
||||
internal Vec4F32 ui_pop_text_select_color(void);
|
||||
internal Vec4F32 ui_pop_text_cursor_color(void);
|
||||
internal F32 ui_pop_squish(void);
|
||||
internal OS_Cursor ui_pop_hover_cursor(void);
|
||||
internal F_Tag ui_pop_font(void);
|
||||
internal F32 ui_pop_font_size(void);
|
||||
@@ -312,12 +332,14 @@ internal UI_BoxFlags ui_set_next_flags(UI_BoxFlags v);
|
||||
internal UI_FocusKind ui_set_next_focus_hot(UI_FocusKind v);
|
||||
internal UI_FocusKind ui_set_next_focus_active(UI_FocusKind v);
|
||||
internal U32 ui_set_next_fastpath_codepoint(U32 v);
|
||||
internal F32 ui_set_next_transparency(F32 v);
|
||||
internal Vec4F32 ui_set_next_background_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_border_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_overlay_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_select_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_cursor_color(Vec4F32 v);
|
||||
internal F32 ui_set_next_squish(F32 v);
|
||||
internal OS_Cursor ui_set_next_hover_cursor(OS_Cursor v);
|
||||
internal F_Tag ui_set_next_font(F_Tag v);
|
||||
internal F32 ui_set_next_font_size(F32 v);
|
||||
|
||||
@@ -29,6 +29,7 @@ UI_StackTable:
|
||||
{ FastpathCodepoint fastpath_codepoint U32 0 }
|
||||
|
||||
//- rjf: colors
|
||||
{ Transparency transparency F32 0 }
|
||||
{ BackgroundColor background_color Vec4F32 `v4f32(1, 0, 1, 1)`}
|
||||
{ TextColor text_color Vec4F32 `v4f32(1, 0, 1, 1)`}
|
||||
{ BorderColor border_color Vec4F32 `v4f32(1, 0, 1, 1)`}
|
||||
@@ -36,6 +37,9 @@ UI_StackTable:
|
||||
{ TextSelectColor text_select_color Vec4F32 `v4f32(1, 0, 1, 1)`}
|
||||
{ TextCursorColor text_cursor_color Vec4F32 `v4f32(1, 0, 1, 1)`}
|
||||
|
||||
//- rjf: squish
|
||||
{ Squish squish F32 0 }
|
||||
|
||||
//- rjf: hover cursor
|
||||
{ HoverCursor hover_cursor OS_Cursor OS_Cursor_Pointer }
|
||||
|
||||
|
||||
@@ -525,19 +525,17 @@ internal UI_BOX_CUSTOM_DRAW(ui_sat_val_picker_draw)
|
||||
// rjf: hue => rgb
|
||||
Vec3F32 hue_rgb = rgb_from_hsv(v3f32(data->hue, 1, 1));
|
||||
|
||||
// rjf: value
|
||||
// rjf: white -> rgb background
|
||||
{
|
||||
R_Rect2DInst *inst = d_rect(pad_2f32(box->rect, -1.f), v4f32(0, 0, 0, 1), 4.f, 0, 1.f);
|
||||
inst->colors[Corner_00] = inst->colors[Corner_10] = v4f32(1, 1, 1, 1);
|
||||
R_Rect2DInst *inst = d_rect(pad_2f32(box->rect, -1.f), v4f32(hue_rgb.x, hue_rgb.y, hue_rgb.z, 1), 4.f, 0, 1.f);
|
||||
inst->colors[Corner_00] = inst->colors[Corner_01] = v4f32(1, 1, 1, 1);
|
||||
}
|
||||
|
||||
// rjf: saturation
|
||||
// rjf: black gradient overlay
|
||||
{
|
||||
R_Rect2DInst *inst = d_rect(pad_2f32(box->rect, -1.f), v4f32(0, 0, 0, 0), 4.f, 0, 1.f);
|
||||
inst->colors[Corner_00] = v4f32(1, 1, 1, 1);
|
||||
inst->colors[Corner_01] = v4f32(0, 0, 0, 0);
|
||||
inst->colors[Corner_10] = v4f32(hue_rgb.x, hue_rgb.y, hue_rgb.z, 1);
|
||||
inst->colors[Corner_11] = v4f32(hue_rgb.x, hue_rgb.y, hue_rgb.z, 0);
|
||||
inst->colors[Corner_01] = v4f32(0, 0, 0, 1);
|
||||
inst->colors[Corner_11] = v4f32(0, 0, 0, 1);
|
||||
}
|
||||
|
||||
// rjf: indicator
|
||||
|
||||
+134
-9
@@ -428,6 +428,7 @@ ui_state_alloc(void)
|
||||
ui->build_arenas[0] = arena_alloc();
|
||||
ui->build_arenas[1] = arena_alloc();
|
||||
ui->drag_state_arena = arena_alloc();
|
||||
ui->string_hover_arena = arena_alloc();
|
||||
ui->box_table_size = 4096;
|
||||
ui->box_table = push_array(arena, UI_BoxHashSlot, ui->box_table_size);
|
||||
UI_InitStackNils(ui);
|
||||
@@ -437,6 +438,7 @@ ui_state_alloc(void)
|
||||
internal void
|
||||
ui_state_release(UI_State *state)
|
||||
{
|
||||
arena_release(state->string_hover_arena);
|
||||
arena_release(state->drag_state_arena);
|
||||
for(int i = 0; i < ArrayCount(state->build_arenas); i += 1)
|
||||
{
|
||||
@@ -551,6 +553,35 @@ ui_get_drag_data(U64 min_required_size)
|
||||
return ui_state->drag_state_data;
|
||||
}
|
||||
|
||||
//- rjf: hovered string info
|
||||
|
||||
internal B32
|
||||
ui_string_hover_active(void)
|
||||
{
|
||||
return (ui_state->build_index > 0 && ui_state->string_hover_build_index >= ui_state->build_index-1 &&
|
||||
os_now_microseconds() >= ui_state->string_hover_begin_us + 500000);
|
||||
}
|
||||
|
||||
internal U64
|
||||
ui_string_hover_begin_time_us(void)
|
||||
{
|
||||
return ui_state->string_hover_begin_us;
|
||||
}
|
||||
|
||||
internal String8
|
||||
ui_string_hover_string(Arena *arena)
|
||||
{
|
||||
String8 result = push_str8_copy(arena, ui_state->string_hover_string);
|
||||
return result;
|
||||
}
|
||||
|
||||
internal D_FancyRunList
|
||||
ui_string_hover_runs(Arena *arena)
|
||||
{
|
||||
D_FancyRunList result = d_fancy_run_list_copy(arena, &ui_state->string_hover_fancy_runs);
|
||||
return result;
|
||||
}
|
||||
|
||||
//- rjf: interaction keys
|
||||
|
||||
internal UI_Key
|
||||
@@ -611,6 +642,8 @@ ui_begin_build(OS_EventList *events, OS_Handle window, UI_NavActionList *nav_act
|
||||
ui_state->clipboard_copy_key = ui_key_zero();
|
||||
ui_state->last_build_box_count = ui_state->build_box_count;
|
||||
ui_state->build_box_count = 0;
|
||||
ui_state->tooltip_open = 0;
|
||||
ui_state->ctx_menu_changed = 0;
|
||||
}
|
||||
|
||||
//- rjf: fill build phase parameters
|
||||
@@ -908,6 +941,8 @@ ui_begin_build(OS_EventList *events, OS_Handle window, UI_NavActionList *nav_act
|
||||
Vec2F32 anchor = add_2f32(ui_state->ctx_menu_anchor_box_last_pos, ui_state->ctx_menu_anchor_off);
|
||||
UI_FixedX(anchor.x) UI_FixedY(anchor.y) UI_PrefWidth(ui_children_sum(1.f)) UI_PrefHeight(ui_children_sum(1.f))
|
||||
UI_Focus(UI_FocusKind_On)
|
||||
UI_Squish(0.25f-ui_state->ctx_menu_open_t*0.25f)
|
||||
UI_Transparency(1-ui_state->ctx_menu_open_t)
|
||||
{
|
||||
ui_set_next_child_layout_axis(Axis2_Y);
|
||||
ui_state->ctx_menu_root = ui_build_box_from_stringf(UI_BoxFlag_Clickable|UI_BoxFlag_DrawDropShadow|(ui_state->ctx_menu_open*UI_BoxFlag_DefaultFocusNavY), "###ctx_menu_%I64x", window.u64[0]);
|
||||
@@ -1014,7 +1049,7 @@ ui_end_build(void)
|
||||
}
|
||||
|
||||
//- rjf: stick ctx menu to anchor
|
||||
if(ui_state->ctx_menu_touched_this_frame)
|
||||
if(ui_state->ctx_menu_touched_this_frame && !ui_state->ctx_menu_changed)
|
||||
{
|
||||
UI_Box *anchor_box = ui_box_from_key(ui_state->ctx_menu_anchor_key);
|
||||
if(!ui_box_is_nil(anchor_box))
|
||||
@@ -1085,18 +1120,24 @@ ui_end_build(void)
|
||||
//- rjf: animate
|
||||
{
|
||||
ProfBegin("ui animate");
|
||||
F32 vast_rate = 1 - pow_f32(2, (-100.f* ui_state->animation_dt));
|
||||
F32 vast_rate = 1 - pow_f32(2, (-60.f * ui_state->animation_dt));
|
||||
F32 fast_rate = 1 - pow_f32(2, (-50.f * ui_state->animation_dt));
|
||||
F32 fish_rate = 1 - pow_f32(2, (-40.f * ui_state->animation_dt));
|
||||
F32 slow_rate = 1 - pow_f32(2, (-30.f * ui_state->animation_dt));
|
||||
F32 slug_rate = 1 - pow_f32(2, (-15.f * ui_state->animation_dt));
|
||||
F32 slaf_rate = 1 - pow_f32(2, (-8.f * ui_state->animation_dt));
|
||||
ui_state->ctx_menu_open_t += ((F32)!!ui_state->ctx_menu_open - ui_state->ctx_menu_open_t) * fish_rate;
|
||||
ui_state->is_animating = (ui_state->is_animating || fabsf((F32)!!ui_state->ctx_menu_open - ui_state->ctx_menu_open_t) > 0.01f);
|
||||
if(ui_state->ctx_menu_open_t >= 0.99f)
|
||||
ui_state->ctx_menu_open_t += ((F32)!!ui_state->ctx_menu_open - ui_state->ctx_menu_open_t) * vast_rate;
|
||||
ui_state->is_animating = (ui_state->is_animating || abs_f32((F32)!!ui_state->ctx_menu_open - ui_state->ctx_menu_open_t) > 0.01f);
|
||||
if(ui_state->ctx_menu_open_t >= 0.99f && ui_state->ctx_menu_open)
|
||||
{
|
||||
ui_state->ctx_menu_open_t = 1.f;
|
||||
}
|
||||
ui_state->tooltip_open_t += ((F32)!!ui_state->tooltip_open - ui_state->tooltip_open_t) * vast_rate;
|
||||
ui_state->is_animating = (ui_state->is_animating || abs_f32((F32)!!ui_state->tooltip_open - ui_state->tooltip_open_t) > 0.01f);
|
||||
if(ui_state->tooltip_open_t >= 0.99f && ui_state->tooltip_open)
|
||||
{
|
||||
ui_state->tooltip_open_t = 1.f;
|
||||
}
|
||||
for(U64 slot_idx = 0; slot_idx < ui_state->box_table_size; slot_idx += 1)
|
||||
{
|
||||
for(UI_Box *box = ui_state->box_table[slot_idx].hash_first;
|
||||
@@ -1195,7 +1236,7 @@ ui_end_build(void)
|
||||
}
|
||||
|
||||
//- rjf: animate context menu
|
||||
if(ui_state->ctx_menu_open && !ui_box_is_nil(ui_state->ctx_menu_root))
|
||||
if(ui_state->ctx_menu_open && !ui_box_is_nil(ui_state->ctx_menu_root) && !ui_state->ctx_menu_changed)
|
||||
{
|
||||
UI_Box *root = ui_state->ctx_menu_root;
|
||||
Rng2F32 rect = root->rect;
|
||||
@@ -1260,6 +1301,59 @@ ui_end_build(void)
|
||||
scratch_end(scratch);
|
||||
}
|
||||
|
||||
//- rjf: hovering possibly-truncated drawn text -> store text
|
||||
{
|
||||
B32 found = 0;
|
||||
for(UI_Box *box = ui_state->root, *next = 0; !ui_box_is_nil(box); box = next)
|
||||
{
|
||||
UI_BoxRec rec = ui_box_rec_df_pre(box, ui_state->root);
|
||||
next = rec.next;
|
||||
S32 pop_idx = 0;
|
||||
for(UI_Box *b = box; !ui_box_is_nil(b) && pop_idx <= rec.pop_count; b = b->parent, pop_idx += 1)
|
||||
{
|
||||
if(b->flags & UI_BoxFlag_DrawText && !(b->flags & UI_BoxFlag_DisableTextTrunc))
|
||||
{
|
||||
String8 box_display_string = ui_box_display_string(b);
|
||||
Vec2F32 text_pos = ui_box_text_position(b);
|
||||
Vec2F32 drawn_text_dim = b->display_string_runs.dim;
|
||||
if(drawn_text_dim.x > dim_2f32(b->rect).x &&
|
||||
contains_2f32(r2f32p(text_pos.x,
|
||||
b->rect.y0,
|
||||
Min(text_pos.x+drawn_text_dim.x, b->rect.x1),
|
||||
b->rect.y1),
|
||||
ui_state->mouse))
|
||||
{
|
||||
if(!str8_match(box_display_string, ui_state->string_hover_string, 0))
|
||||
{
|
||||
arena_clear(ui_state->string_hover_arena);
|
||||
ui_state->string_hover_string = push_str8_copy(ui_state->string_hover_arena, box_display_string);
|
||||
ui_state->string_hover_fancy_runs = d_fancy_run_list_copy(ui_state->string_hover_arena, &b->display_string_runs);
|
||||
ui_state->string_hover_begin_us = os_now_microseconds();
|
||||
}
|
||||
ui_state->string_hover_build_index = ui_state->build_index;
|
||||
found = 1;
|
||||
goto break_all_hover_string;
|
||||
}
|
||||
}
|
||||
if(b != box && contains_2f32(b->rect, ui_state->mouse))
|
||||
{
|
||||
goto break_all_hover_string;
|
||||
}
|
||||
}
|
||||
}
|
||||
break_all_hover_string:;
|
||||
if(!found)
|
||||
{
|
||||
arena_clear(ui_state->string_hover_arena);
|
||||
ui_state->string_hover_build_index = 0;
|
||||
MemoryZeroStruct(&ui_state->string_hover_string);
|
||||
}
|
||||
if(found && !ui_string_hover_active())
|
||||
{
|
||||
ui_state->is_animating = 1;
|
||||
}
|
||||
}
|
||||
|
||||
ui_state->build_index += 1;
|
||||
arena_clear(ui_build_arena());
|
||||
ProfEnd();
|
||||
@@ -1578,13 +1672,17 @@ ui_layout_root(UI_Box *root, Axis2 axis)
|
||||
internal void
|
||||
ui_tooltip_begin_base(void)
|
||||
{
|
||||
ui_state->tooltip_open = 1;
|
||||
ui_push_parent(ui_root_from_state(ui_state));
|
||||
ui_push_parent(ui_state->tooltip_root);
|
||||
ui_push_flags(0);
|
||||
}
|
||||
|
||||
internal void
|
||||
ui_tooltip_end_base(void)
|
||||
{
|
||||
ui_pop_flags();
|
||||
ui_pop_transparency();
|
||||
ui_pop_parent();
|
||||
ui_pop_parent();
|
||||
}
|
||||
@@ -1593,11 +1691,21 @@ internal void
|
||||
ui_tooltip_begin(void)
|
||||
{
|
||||
ui_tooltip_begin_base();
|
||||
UI_Flags(UI_BoxFlag_DrawBorder|UI_BoxFlag_DrawBackground|UI_BoxFlag_DrawBackgroundBlur|UI_BoxFlag_DrawDropShadow|UI_BoxFlag_RoundChildrenByParent)
|
||||
ui_set_next_squish(0.25f-ui_state->tooltip_open_t*0.25f);
|
||||
ui_set_next_transparency(1-ui_state->tooltip_open_t);
|
||||
UI_Flags(UI_BoxFlag_DrawBorder|UI_BoxFlag_DrawBackground|UI_BoxFlag_DrawBackgroundBlur|UI_BoxFlag_DrawDropShadow)
|
||||
UI_PrefWidth(ui_children_sum(1))
|
||||
UI_PrefHeight(ui_children_sum(1))
|
||||
UI_CornerRadius(ui_top_font_size()*0.25f)
|
||||
ui_column_begin();
|
||||
UI_PrefWidth(ui_px(0, 1)) ui_spacer(ui_em(0.5f, 1.f));
|
||||
UI_PrefWidth(ui_children_sum(1))
|
||||
UI_PrefHeight(ui_children_sum(1))
|
||||
ui_row_begin();
|
||||
UI_PrefHeight(ui_px(0, 1)) ui_spacer(ui_em(0.5f, 1.f));
|
||||
UI_PrefWidth(ui_children_sum(1))
|
||||
UI_PrefHeight(ui_children_sum(1))
|
||||
ui_column_begin();
|
||||
ui_push_pref_width(ui_text_dim(10.f, 1.f));
|
||||
ui_push_pref_height(ui_em(2.f, 1.f));
|
||||
ui_push_text_alignment(UI_TextAlign_Center);
|
||||
@@ -1610,6 +1718,10 @@ ui_tooltip_end(void)
|
||||
ui_pop_pref_width();
|
||||
ui_pop_pref_height();
|
||||
ui_column_end();
|
||||
UI_PrefHeight(ui_px(0, 1)) ui_spacer(ui_em(0.5f, 1.f));
|
||||
ui_row_end();
|
||||
UI_PrefWidth(ui_px(0, 1)) ui_spacer(ui_em(0.5f, 1.f));
|
||||
ui_column_end();
|
||||
ui_tooltip_end_base();
|
||||
}
|
||||
|
||||
@@ -1621,6 +1733,7 @@ ui_ctx_menu_open(UI_Key key, UI_Key anchor_box_key, Vec2F32 anchor_off)
|
||||
anchor_off.x = (F32)(int)anchor_off.x;
|
||||
anchor_off.y = (F32)(int)anchor_off.y;
|
||||
ui_state->next_ctx_menu_open = 1;
|
||||
ui_state->ctx_menu_changed = 1;
|
||||
ui_state->ctx_menu_open_t = 0;
|
||||
ui_state->ctx_menu_key = key;
|
||||
ui_state->next_ctx_menu_anchor_key = anchor_box_key;
|
||||
@@ -1955,6 +2068,8 @@ ui_build_box_from_key(UI_BoxFlags flags, UI_Key key)
|
||||
box->corner_radii[Corner_10] = ui_state->corner_radius_10_stack.top->v;
|
||||
box->corner_radii[Corner_11] = ui_state->corner_radius_11_stack.top->v;
|
||||
box->blur_size = ui_state->blur_size_stack.top->v;
|
||||
box->transparency = ui_state->transparency_stack.top->v;
|
||||
box->squish = ui_state->squish_stack.top->v;
|
||||
box->text_padding = ui_state->text_padding_stack.top->v;
|
||||
box->hover_cursor = ui_state->hover_cursor_stack.top->v;
|
||||
box->custom_draw = 0;
|
||||
@@ -2072,6 +2187,14 @@ ui_box_equip_display_fancy_strings(UI_Box *box, D_FancyStringList *strings)
|
||||
box->display_string_runs = d_fancy_run_list_from_fancy_string_list(ui_build_arena(), strings);
|
||||
}
|
||||
|
||||
internal inline void
|
||||
ui_box_equip_display_string_fancy_runs(UI_Box *box, String8 string, D_FancyRunList *runs)
|
||||
{
|
||||
box->flags |= UI_BoxFlag_HasDisplayString;
|
||||
box->string = push_str8_copy(ui_build_arena(), string);
|
||||
box->display_string_runs = d_fancy_run_list_copy(ui_build_arena(), runs);
|
||||
}
|
||||
|
||||
internal void
|
||||
ui_box_equip_draw_bucket(UI_Box *box, D_Bucket *bucket)
|
||||
{
|
||||
@@ -2443,8 +2566,10 @@ ui_signal_from_box(UI_Box *box)
|
||||
B32 keyboard_click = 0;
|
||||
if(!disabled && is_focused && box->flags & UI_BoxFlag_KeyboardClickable)
|
||||
{
|
||||
if(os_key_press(ui_events(), ui_window(), 0, OS_Key_Return) != 0 ||
|
||||
os_key_press(ui_events(), ui_window(), 0, OS_Key_Space) != 0)
|
||||
if(os_key_press(ui_events(), ui_window(), 0, OS_Key_Return) != 0)
|
||||
// TODO(rjf): need to handle case where this would conflict with typing.
|
||||
// if(os_key_press(ui_events(), ui_window(), 0, OS_Key_Return) != 0 ||
|
||||
// os_key_press(ui_events(), ui_window(), 0, OS_Key_Space) != 0)
|
||||
{
|
||||
keyboard_click = 1;
|
||||
result.clicked = 1;
|
||||
|
||||
@@ -281,6 +281,8 @@ struct UI_Box
|
||||
F32 font_size;
|
||||
F32 corner_radii[Corner_COUNT];
|
||||
F32 blur_size;
|
||||
F32 transparency;
|
||||
F32 squish;
|
||||
F32 text_padding;
|
||||
|
||||
//- rjf: per-build artifacts
|
||||
@@ -414,6 +416,15 @@ struct UI_State
|
||||
Vec2F32 drag_start_mouse;
|
||||
Arena *drag_state_arena;
|
||||
String8 drag_state_data;
|
||||
Arena *string_hover_arena;
|
||||
String8 string_hover_string;
|
||||
D_FancyRunList string_hover_fancy_runs;
|
||||
U64 string_hover_begin_us;
|
||||
U64 string_hover_build_index;
|
||||
|
||||
//- rjf: tooltip state
|
||||
F32 tooltip_open_t;
|
||||
B32 tooltip_open;
|
||||
|
||||
//- rjf: context menu state
|
||||
UI_Key ctx_menu_anchor_key;
|
||||
@@ -424,6 +435,7 @@ struct UI_State
|
||||
B32 next_ctx_menu_open;
|
||||
F32 ctx_menu_open_t;
|
||||
UI_Key ctx_menu_key;
|
||||
B32 ctx_menu_changed;
|
||||
|
||||
//- rjf: build phase stacks
|
||||
UI_DeclStackNils;
|
||||
@@ -526,6 +538,10 @@ internal String8 ui_get_drag_data(U64 min_required_size);
|
||||
#define ui_store_drag_struct(ptr) ui_store_drag_data(str8_struct(ptr))
|
||||
#define ui_get_drag_struct(type) ((type *)ui_get_drag_data(sizeof(type)).str)
|
||||
|
||||
//- rjf: hovered string info
|
||||
internal B32 ui_string_hover_active(void);
|
||||
internal D_FancyRunList ui_string_hover_runs(Arena *arena);
|
||||
|
||||
//- rjf: interaction keys
|
||||
internal UI_Key ui_hot_key(void);
|
||||
internal UI_Key ui_active_key(Side side);
|
||||
@@ -584,6 +600,7 @@ internal UI_Box * ui_build_box_from_stringf(UI_BoxFlags flags, char *fm
|
||||
//- rjf: box node equipment
|
||||
internal inline void ui_box_equip_display_string(UI_Box *box, String8 string);
|
||||
internal inline void ui_box_equip_display_fancy_strings(UI_Box *box, D_FancyStringList *strings);
|
||||
internal inline void ui_box_equip_display_string_fancy_runs(UI_Box *box, String8 string, D_FancyRunList *runs);
|
||||
internal inline void ui_box_equip_draw_bucket(UI_Box *box, D_Bucket *bucket);
|
||||
internal inline void ui_box_equip_custom_draw(UI_Box *box, UI_BoxCustomDrawFunctionType *custom_draw, void *user_data);
|
||||
|
||||
@@ -617,12 +634,14 @@ internal UI_BoxFlags ui_top_flags(void);
|
||||
internal UI_FocusKind ui_top_focus_hot(void);
|
||||
internal UI_FocusKind ui_top_focus_active(void);
|
||||
internal U32 ui_top_fastpath_codepoint(void);
|
||||
internal F32 ui_top_transparency(void);
|
||||
internal Vec4F32 ui_top_background_color(void);
|
||||
internal Vec4F32 ui_top_text_color(void);
|
||||
internal Vec4F32 ui_top_border_color(void);
|
||||
internal Vec4F32 ui_top_overlay_color(void);
|
||||
internal Vec4F32 ui_top_text_select_color(void);
|
||||
internal Vec4F32 ui_top_text_cursor_color(void);
|
||||
internal F32 ui_top_squish(void);
|
||||
internal OS_Cursor ui_top_hover_cursor(void);
|
||||
internal F_Tag ui_top_font(void);
|
||||
internal F32 ui_top_font_size(void);
|
||||
@@ -645,12 +664,14 @@ internal UI_BoxFlags ui_bottom_flags(void);
|
||||
internal UI_FocusKind ui_bottom_focus_hot(void);
|
||||
internal UI_FocusKind ui_bottom_focus_active(void);
|
||||
internal U32 ui_bottom_fastpath_codepoint(void);
|
||||
internal F32 ui_bottom_transparency(void);
|
||||
internal Vec4F32 ui_bottom_background_color(void);
|
||||
internal Vec4F32 ui_bottom_text_color(void);
|
||||
internal Vec4F32 ui_bottom_border_color(void);
|
||||
internal Vec4F32 ui_bottom_overlay_color(void);
|
||||
internal Vec4F32 ui_bottom_text_select_color(void);
|
||||
internal Vec4F32 ui_bottom_text_cursor_color(void);
|
||||
internal F32 ui_bottom_squish(void);
|
||||
internal OS_Cursor ui_bottom_hover_cursor(void);
|
||||
internal F_Tag ui_bottom_font(void);
|
||||
internal F32 ui_bottom_font_size(void);
|
||||
@@ -673,12 +694,14 @@ internal UI_BoxFlags ui_push_flags(UI_BoxFlags v);
|
||||
internal UI_FocusKind ui_push_focus_hot(UI_FocusKind v);
|
||||
internal UI_FocusKind ui_push_focus_active(UI_FocusKind v);
|
||||
internal U32 ui_push_fastpath_codepoint(U32 v);
|
||||
internal F32 ui_push_transparency(F32 v);
|
||||
internal Vec4F32 ui_push_background_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_border_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_overlay_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_select_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_push_text_cursor_color(Vec4F32 v);
|
||||
internal F32 ui_push_squish(F32 v);
|
||||
internal OS_Cursor ui_push_hover_cursor(OS_Cursor v);
|
||||
internal F_Tag ui_push_font(F_Tag v);
|
||||
internal F32 ui_push_font_size(F32 v);
|
||||
@@ -701,12 +724,14 @@ internal UI_BoxFlags ui_pop_flags(void);
|
||||
internal UI_FocusKind ui_pop_focus_hot(void);
|
||||
internal UI_FocusKind ui_pop_focus_active(void);
|
||||
internal U32 ui_pop_fastpath_codepoint(void);
|
||||
internal F32 ui_pop_transparency(void);
|
||||
internal Vec4F32 ui_pop_background_color(void);
|
||||
internal Vec4F32 ui_pop_text_color(void);
|
||||
internal Vec4F32 ui_pop_border_color(void);
|
||||
internal Vec4F32 ui_pop_overlay_color(void);
|
||||
internal Vec4F32 ui_pop_text_select_color(void);
|
||||
internal Vec4F32 ui_pop_text_cursor_color(void);
|
||||
internal F32 ui_pop_squish(void);
|
||||
internal OS_Cursor ui_pop_hover_cursor(void);
|
||||
internal F_Tag ui_pop_font(void);
|
||||
internal F32 ui_pop_font_size(void);
|
||||
@@ -729,12 +754,14 @@ internal UI_BoxFlags ui_set_next_flags(UI_BoxFlags v);
|
||||
internal UI_FocusKind ui_set_next_focus_hot(UI_FocusKind v);
|
||||
internal UI_FocusKind ui_set_next_focus_active(UI_FocusKind v);
|
||||
internal U32 ui_set_next_fastpath_codepoint(U32 v);
|
||||
internal F32 ui_set_next_transparency(F32 v);
|
||||
internal Vec4F32 ui_set_next_background_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_border_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_overlay_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_select_color(Vec4F32 v);
|
||||
internal Vec4F32 ui_set_next_text_cursor_color(Vec4F32 v);
|
||||
internal F32 ui_set_next_squish(F32 v);
|
||||
internal OS_Cursor ui_set_next_hover_cursor(OS_Cursor v);
|
||||
internal F_Tag ui_set_next_font(F_Tag v);
|
||||
internal F32 ui_set_next_font_size(F32 v);
|
||||
@@ -771,12 +798,14 @@ internal void ui_pop_corner_radius(void);
|
||||
#define UI_FocusHot(v) DeferLoop(ui_push_focus_hot(v), ui_pop_focus_hot())
|
||||
#define UI_FocusActive(v) DeferLoop(ui_push_focus_active(v), ui_pop_focus_active())
|
||||
#define UI_FastpathCodepoint(v) DeferLoop(ui_push_fastpath_codepoint(v), ui_pop_fastpath_codepoint())
|
||||
#define UI_Transparency(v) DeferLoop(ui_push_transparency(v), ui_pop_transparency())
|
||||
#define UI_BackgroundColor(v) DeferLoop(ui_push_background_color(v), ui_pop_background_color())
|
||||
#define UI_TextColor(v) DeferLoop(ui_push_text_color(v), ui_pop_text_color())
|
||||
#define UI_BorderColor(v) DeferLoop(ui_push_border_color(v), ui_pop_border_color())
|
||||
#define UI_OverlayColor(v) DeferLoop(ui_push_overlay_color(v), ui_pop_overlay_color())
|
||||
#define UI_TextSelectColor(v) DeferLoop(ui_push_text_select_color(v), ui_pop_text_select_color())
|
||||
#define UI_TextCursorColor(v) DeferLoop(ui_push_text_cursor_color(v), ui_pop_text_cursor_color())
|
||||
#define UI_Squish(v) DeferLoop(ui_push_squish(v), ui_pop_squish())
|
||||
#define UI_HoverCursor(v) DeferLoop(ui_push_hover_cursor(v), ui_pop_hover_cursor())
|
||||
#define UI_Font(v) DeferLoop(ui_push_font(v), ui_pop_font())
|
||||
#define UI_FontSize(v) DeferLoop(ui_push_font_size(v), ui_pop_font_size())
|
||||
|
||||
Reference in New Issue
Block a user