Compare commits

..

5 Commits

Author SHA1 Message Date
LagoLunatic 221c1a8cda
Merge 0b7afa9f1e into 7aa878b48e 2024-12-01 22:33:58 -07:00
LagoLunatic 0b7afa9f1e Remove trailing newline when displaying decoded rlwinm info 2024-12-01 20:34:48 -05:00
LagoLunatic 5841d4db8a Display decoded rlwinm info to hover tooltip 2024-12-01 20:27:56 -05:00
LagoLunatic 7a360d4a99 Update .gitignore 2024-12-01 20:26:17 -05:00
LagoLunatic 40c97a1bc3 Fix missing dependency feature for objdiff-gui 2024-12-01 20:26:17 -05:00
2 changed files with 5 additions and 5 deletions

View File

@ -150,8 +150,8 @@ fn ins_hover_ui(
} }
} }
if let Some(decoded) = rlwinmdec::decode(&ins.formatted) { if let Some(demangled) = rlwinmdec::decode(&ins.formatted) {
ui.colored_label(appearance.highlight_color, decoded.trim()); ui.colored_label(appearance.highlight_color, demangled.trim());
} }
}); });
} }

View File

@ -16,13 +16,13 @@ pub fn rlwinm_decode_window(
egui::Window::new("Rlwinm Decoder").open(show).show(ctx, |ui| { egui::Window::new("Rlwinm Decoder").open(show).show(ctx, |ui| {
ui.text_edit_singleline(&mut state.text); ui.text_edit_singleline(&mut state.text);
ui.add_space(10.0); ui.add_space(10.0);
if let Some(decoded) = rlwinmdec::decode(&state.text) { if let Some(demangled) = rlwinmdec::decode(&state.text) {
ui.scope(|ui| { ui.scope(|ui| {
ui.style_mut().override_text_style = Some(TextStyle::Monospace); ui.style_mut().override_text_style = Some(TextStyle::Monospace);
ui.colored_label(appearance.replace_color, decoded.trim()); ui.colored_label(appearance.replace_color, demangled.trim());
}); });
if ui.button("Copy").clicked() { if ui.button("Copy").clicked() {
ui.output_mut(|output| output.copied_text = decoded); ui.output_mut(|output| output.copied_text = demangled);
} }
} else { } else {
ui.scope(|ui| { ui.scope(|ui| {