Folks,
For everybody that needs the ToolButton position:
| Delphi | | copy code | | ? |
| 1 | type |
| 2 | TToolButtonAccess = class(TToolButton); |
| 3 | |
| 4 | function ToolButtonScreenPos(AToolButton: TToolButton): TPoint; |
| 5 | begin |
| 6 | GetDCOrgEx(TToolButtonAccess(AToolButton).Canvas.Handle, Result); |
| 7 | Inc(Result.X, AToolButton.Left); |
| 8 | Inc(Result.Y, AToolButton.Top); |
| 9 | end; |
Hugs!
Tags: Delphi, GetDCOrgEx, ToolButtonScreenPos, Usefull functions
