TTIPropertyGrid.OnPropertyHint not work
Original Reporter info from Mantis: Zhengji
-
Reporter name:
Original Reporter info from Mantis: Zhengji
- Reporter name:
Description:
TTIPropertyGrid.OnPropertyHint can be used to show customized hint when mouse is over a name.
procedure TForm1.FormCreate(Sender: TObject);
begin
TIPropertyGrid1.OnPropertyHint := @OnPropertyHint;
TIPropertyGrid1.ShowHint := True;
end;
function TForm1.OnPropertyHint(Sender: TObject; PointedRow: TOIPropertyGridRow;
out AHint: string): Boolean;
begin
AHint := 'Test';
Result := True;
end;
But actually this handler can't be called because GetHintTypeAt is called with X on screen (while on client area is expected), so HintType never equals to pehName, expect when near the left side of screen.
Test project and patch are attached.
Steps to reproduce:
-
run the test project;
-
when mouse is over a name (such as Action) in the object inspector, a hint 'Test' should be shown.
Mantis conversion info:
- Mantis ID: 34726
- OS: Windows
- OS Build: 10
- Platform: 64bit
- Version: 2.0RC2
- Monitored by: » Zhengji (Zhengji)