Yes, the build-in Hint effect just changes the text of the given targetElement which needs to be a part of the screen and it needs to be a text element.
There is no ready made hint effect available that does what you want. But it is possible to add this with a custom effect. I’ve done this before for another demo which just changes the position of the targetElement to align it somewhere near the element which the effect has been applied to.
<!-- apply the custom-hint effect whenever someone hovers this element, show the element with the id “hint-panel” and change the text to the given hintText -->
<onHover name=“custom-hint” targetElement=“hint-panel” hintText=“This is a hint” />
</effect>
</panel>
</layer>
<!-- another layer with the panel we’ll show as a hint on top of the normal layer -->
To add to this very helpful answer. If you are using this programatically to build the UI it’s like this:
new PanelBuilder(){{
onHoverEffect(new HoverEffectBuilder("custom-hint")
.effectParameter("targetElement", "hint-panel")
.effectParameter("hintText", "This is a hint")
}}.build(nifty, currentScreen, parent);