Vision Tag Browser Tree - Show Tag Tooltip on Mouseover?

Hi folks!

I'm working with the Vision Tag Browser Tree on an Ad Hoc trend in vision. Client has requested mouseover behavior that shows the tool-tip or documentation property of the tag that's being moused over, but I am at a loss for how to execute this. I expect I'll need to use a custom method and dig into the java component? Any thoughts or guidance would be appreciated. Cheers!

Existing behavior shows the full tag path:

This is going to be pretty challenging.

There's two halves -
First, you'll need to create a new rendering function for the tree, by providing a custom tree cell renderer. In theory, something like this:

from com.inductiveautomation.ignition.client.tags.tree.node.HistoricalProvidersNode import HistoricalTreeRenderer

class CustomHistoricalTreeRenderer(HistoricalTreeRenderer):
	def getTreeCellRendererComponent(self, tree, value, isSelected, isExpanded, isLeaf, rowIndex, isFocused):
		ret = HistoricalTreeRenderer.getTreeCellRendererComponent(self, tree, value, isSelected, isExpanded, isLeaf, rowIndex, isFocused)
		ret.toolTipText = "Something Custom Here"
		ret.text = "TESTING"
		return ret

event.source.tree.setCellRenderer(CustomHistoricalTreeRenderer())

The value object will be a com.inductiveautomation.ignition.common.browsing.Result object. That result object does not have the tooltip or documentation of the tag - because the only backing source of information it has is the historian. The historian may or may not be delivering data from an Ignition tag, so you'll have to issue the reads to do that yourself.
Doing that in a safe way, since the tooltip rendering code is running on the event dispatch thread, is non-trivial.

Congratulations, AIO, on successfully nerd-sniping Paul! Paul's gotten better at dodging, but the newcomer sneaks in the kill!

I'll call it a graze, at best :smiley:
I pulled the ripcord once I had the obvious in hindsight realization that the metadata OP is after won't already be there.

Hmmm. On 8.1.35 my mouseover does reveal the tooltip. (This was an upgrade from a 7.9 project).

This is the Vision "Tag Browser Tree" component, not the tag browser. I was hopefully it might be an easy feature to add, but seeing Paul pull the ripcord is not inspiring a lot of hope. :sweat_smile:

That is the tag browser tree, in designer in preview mode. The tooltips work in the client.

Ahh, my mistake. I am seeing that behavior as well, but only when configured as "Realtime Tag Tree," not "Historical Tag Tree". That's exactly the tooltip behavior I want.

Unfortunately, when dropping the tag onto an ad hoc trend from a Realtime Tag Tree, it doesn't populate with a working historical tag path.

I'll tweak it a little more and see if I can get it before barreling down Paul's rabbit hole.

Tweaking the tag dropping behavior to adjust the tag path would be a lot more doable.

Consider replacing the tags dropped handler with one that does the Right Thing™.

Success.

Altered the existing tag drop script to create the necessary historical path and things are working like a charm.

Thank you Paul for the guidance, and Matrix for reframing the problem.

For any who may follow, the following links were helpful for sussing out the necessary code changes: