-
Notifications
You must be signed in to change notification settings - Fork 366
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add re_data_ui
tooltip to graph view nodes
#8311
Conversation
[skip ci]
[skip ci]
Web viewer built successfully. If applicable, you should also test it:
Note: This comment is updated whenever you push a commit. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not super convinced by the "show instance for implicit node" part, but having the "regular" tooltip for the "regular" nodes is very nice 👍🏻
Node::Implicit { graph_node, .. } => { | ||
draw_node(ui, center, node.label(), Default::default()) | ||
.on_hover_text(format!("Implicit Graph Node: {}", graph_node.as_str(),)) | ||
Node::Implicit { edge_instance, .. } => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm confused here. There could be many edge instances which refer to this implicit node right? Is that the first one that you encounter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, you're right—I was too greedy here.
item_ui::instance_path_button( | ||
ctx, | ||
&query.latest_at_query(), | ||
ctx.recording(), | ||
ui, | ||
Some(query.space_view_id), | ||
&instance_path, | ||
); | ||
|
||
instance_path.data_ui_recording(ctx, ui, UiLayout::Tooltip); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because of my comment above and because this is generally somewhat confusing (and soon broken), I would suggest not having this here, and instead just a text stating "Implicit node created via a reference in the GraphEdge
component" or something of that nature.
The edge instance tooltip should be displayed when the actual edge is hovered imo, but that can be left for later (btw, kurbo has point to bezier distance computation so this is something it could help with).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That makes sense, and I agree. I will change it back!
Related
What
Title.