There no built-in feature of showing panel's hints on the corresponding tabs. However, you can do this manually. Use OnShowHint event of the TApplicationEvents component, like this:
if (ht.Kind = hkZone) and (ht.ZoneArea = hzaTabs) and
(ht.Index >= 0) then
begin
ch := ht.Zone.Tabs[ht.Index].Zone;
if (ch <> nil) and (ch.Panel <> nil) then
begin
CanShow := True;
HintStr := ch.Panel.Caption;
Exit;
end;
end;
CanShow := False;
end;
end;
This code is just an example and it is not perfect. I predict that you will also need some additional code to update hint when mouse moving from one tab to another and to cancel hint in some situations. You can use Site.OnMouseMove event handler and call Application.ActivateHint and Application.CancelHint in required cases.
PS: We consider to add this feature in the next version.
When the mouse moves outside of that rectangle but is still within the control's client area, the ShowHint event is generated again to obtain new information to update the current hint with. Consequently, the hint disappears as soon as the mouse moves outside of that tab, and changes when the mouse moves to another tab. No messing about with Application.ActivateHint and Application.CancelHint needed.
Comments
I found the answer was even easier. There's no need for an OnMouseMove handler. Just set the HintInfo.CursorRect to the bounds of the tab:
HintStr := ch.Panel.Caption;
HintInfo.CursorRect := ht.Zone.Tabs[ht.Index].Bounds;
When the mouse moves outside of that rectangle but is still within the control's client area, the ShowHint event is generated again to obtain new information to update the current hint with. Consequently, the hint disappears as soon as the mouse moves outside of that tab, and changes when the mouse moves to another tab. No messing about with Application.ActivateHint and Application.CancelHint needed.
See this answer on Stack Overflow:
http://stackoverflow.com/a/15031957/127670