From 40c97a1bc38b9fbee9c2d0c96cc07cfff8cb69e1 Mon Sep 17 00:00:00 2001 From: LagoLunatic Date: Wed, 27 Nov 2024 21:05:07 -0500 Subject: [PATCH 1/4] Fix missing dependency feature for objdiff-gui --- objdiff-gui/Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/objdiff-gui/Cargo.toml b/objdiff-gui/Cargo.toml index 8be0c75..8da8051 100644 --- a/objdiff-gui/Cargo.toml +++ b/objdiff-gui/Cargo.toml @@ -95,7 +95,7 @@ exec = "0.3" # native: [target.'cfg(not(target_arch = "wasm32"))'.dependencies] -tracing-subscriber = "0.3" +tracing-subscriber = { version = "0.3", features = ["env-filter"] } # web: [target.'cfg(target_arch = "wasm32")'.dependencies] From 7a360d4a99521047b17e69a82272df69d5b90699 Mon Sep 17 00:00:00 2001 From: LagoLunatic Date: Thu, 28 Nov 2024 16:19:17 -0500 Subject: [PATCH 2/4] Update .gitignore --- .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index c46c7cc..e4a9258 100644 --- a/.gitignore +++ b/.gitignore @@ -18,4 +18,4 @@ android.keystore *.frag *.vert *.metal -.vscode/launch.json +.vscode/ From 5841d4db8abd30f540cbc3250b90657706a82c62 Mon Sep 17 00:00:00 2001 From: LagoLunatic Date: Sun, 1 Dec 2024 20:27:56 -0500 Subject: [PATCH 3/4] Display decoded rlwinm info to hover tooltip --- objdiff-gui/src/views/function_diff.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/objdiff-gui/src/views/function_diff.rs b/objdiff-gui/src/views/function_diff.rs index 168ed7e..9734c7e 100644 --- a/objdiff-gui/src/views/function_diff.rs +++ b/objdiff-gui/src/views/function_diff.rs @@ -149,6 +149,10 @@ fn ins_hover_ui( ui.colored_label(appearance.highlight_color, "Extern".to_string()); } } + + if let Some(demangled) = rlwinmdec::decode(&ins.formatted) { + ui.colored_label(appearance.highlight_color, &demangled); + } }); } From 0b7afa9f1eb8ae606fa249d1e10b44f36489742b Mon Sep 17 00:00:00 2001 From: LagoLunatic Date: Sun, 1 Dec 2024 20:34:48 -0500 Subject: [PATCH 4/4] Remove trailing newline when displaying decoded rlwinm info --- objdiff-gui/src/views/function_diff.rs | 2 +- objdiff-gui/src/views/rlwinm.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/objdiff-gui/src/views/function_diff.rs b/objdiff-gui/src/views/function_diff.rs index 9734c7e..c5e8286 100644 --- a/objdiff-gui/src/views/function_diff.rs +++ b/objdiff-gui/src/views/function_diff.rs @@ -151,7 +151,7 @@ fn ins_hover_ui( } if let Some(demangled) = rlwinmdec::decode(&ins.formatted) { - ui.colored_label(appearance.highlight_color, &demangled); + ui.colored_label(appearance.highlight_color, demangled.trim()); } }); } diff --git a/objdiff-gui/src/views/rlwinm.rs b/objdiff-gui/src/views/rlwinm.rs index 08b9354..63b9ca5 100644 --- a/objdiff-gui/src/views/rlwinm.rs +++ b/objdiff-gui/src/views/rlwinm.rs @@ -19,7 +19,7 @@ pub fn rlwinm_decode_window( if let Some(demangled) = rlwinmdec::decode(&state.text) { ui.scope(|ui| { ui.style_mut().override_text_style = Some(TextStyle::Monospace); - ui.colored_label(appearance.replace_color, &demangled); + ui.colored_label(appearance.replace_color, demangled.trim()); }); if ui.button("Copy").clicked() { ui.output_mut(|output| output.copied_text = demangled);