egui icon indicating copy to clipboard operation
egui copied to clipboard

Add ability to disable hover tooltip on TextWrapping

Open SUPERCILEX opened this issue 9 months ago • 2 comments

Is your feature request related to a problem? Please describe. I'm trying to show a single row of text with whitespace stripped, but then show the original text on hover. Currently, it seems like I can't disable the stripped version from having a tooltip. Also what I'd really want is just the ability to provide custom ui for the tooltip when the text gets clipped.

SUPERCILEX avatar Apr 27 '24 23:04 SUPERCILEX

response = ui.label("test"); Receive a response in the form. Depending on the condition, check if you get the desired result with response.enable = false.

rustbasic avatar Apr 28 '24 02:04 rustbasic

No, the tooltip still shows up from Layout job.

SUPERCILEX avatar Apr 28 '24 02:04 SUPERCILEX

Are you talking about truncated labels, i.e. labels that replace some text with ? If so, the fix should go in here:

https://github.com/emilk/egui/blob/631b2277288a25b994b2bce191cf6a35eb497160/crates/egui/src/widgets/label.rs#L222-L225

I suggest you add a setting for this in Visuals

emilk avatar Jun 05 '24 16:06 emilk

Yes, thank you for the code pointer!

SUPERCILEX avatar Jun 05 '24 17:06 SUPERCILEX