MCPcopy Index your code
hub / github.com/encounter/objdiff / symbol_label_ui

Function symbol_label_ui

objdiff-gui/src/views/diff.rs:719–747  ·  view source on GitHub ↗
(
    ui: &mut Ui,
    ctx: DiffColumnContext,
    symbol: &Symbol,
    symbol_idx: usize,
    column: usize,
    appearance: &Appearance,
)

Source from the content-addressed store, hash-verified

717}
718
719fn symbol_label_ui(
720 ui: &mut Ui,
721 ctx: DiffColumnContext,
722 symbol: &Symbol,
723 symbol_idx: usize,
724 column: usize,
725 appearance: &Appearance,
726) -> Option<DiffViewAction> {
727 let (obj, diff) = ctx.obj.unwrap();
728 let ctx = SymbolDiffContext { obj, diff };
729 let mut ret = None;
730 egui::Label::new(
731 RichText::new(symbol.demangled_name.as_deref().unwrap_or(&symbol.name))
732 .font(appearance.code_font.clone())
733 .color(appearance.highlight_color),
734 )
735 .show_tooltip_when_elided(false)
736 .ui(ui)
737 .on_hover_ui_at_pointer(|ui| symbol_hover_ui(ui, ctx, symbol_idx, appearance))
738 .context_menu(|ui| {
739 let section = symbol.section.and_then(|section_idx| ctx.obj.sections.get(section_idx));
740 if let Some(result) =
741 symbol_context_menu_ui(ui, ctx, symbol_idx, symbol, section, column, appearance)
742 {
743 ret = Some(result);
744 }
745 });
746 ret
747}
748
749#[must_use]
750fn diff_col_ui(

Callers 1

diff_view_uiFunction · 0.85

Calls 4

symbol_hover_uiFunction · 0.85
symbol_context_menu_uiFunction · 0.85
uiMethod · 0.80
getMethod · 0.80

Tested by

no test coverage detected