I don't know how everyone thinks how it is the ability to indent the extended function when using QQ? The key to achieving this effect is how to determine that the form below the current mouse pointer is not our program form. GetCursorpos () is an API function that gets the coordinates of the mouse pointer on the screen, which can easily get the VCL visual component under the mouse pointer with the combination of FINDVCLWindow (), but not only one VCL in a form can be When the components, such as TPANEL, TMEMO, etc., then we must find their PARENT level, and finally get TFORM, that means our program form. Follow this idea I have customized the getFormNameat () function, which can get the name of the form below the current mouse pointer. The main implementation code of the program will be used for your reference: (Subsheng, Win2000 Delphi test via) // custom function getFormNameat, NameFunction GetFormNamet (X, Y: Integer) of the Mouse Needle Named Form (X, Y: Integer): String VAR P: TPOINT; W: TwinControl; Begin PX: = X; PY: = Y; W: = FindvCLWindow (P); // Get VCL Visual Components under Mouse Pointer (NIL <> W) THEN Begin While W.Parent <> nil do // Continue to W: = W.Parent; Result: = W.Name; // Last Return Else Begin Result when W: = W.Parent; Result: = W.Name; // Last Return Form Name end else : = '; End; end; procedure tform1.timer1timer (sender: TOBJECT); VAR WINPOS: TPOINT; beginif (Form1.top <= 3) OR (Form1.Top <= 3) OR (Form1.Top <= Screen.Width-Form1.Width-3) Determine Begin getCursorpos (WinPOS); // Get the coordinate of the current mouse pointer // When the name of the mouse pointer is equal to FORM1.NAME = GetFormNamet (WinPos.x, WinPOS) This {here we can take a special name for Form1 to prevent other form names with it} begin form1.timer2.enabled: = false; // deactivate Timer2 Form1.top:=0 ; // Form1 Top and screen align end else form1.timer2.enabled: = true; // Open Timer2nd; End; Procedure TFORM1.TIMER2TIMER (Sender: TOBJECT); begin if form1.top <= 20 THEN FORM1.TOP: = - (Form1.Height-10 ); // Displace Form1 upward, and expose 10 pixel END above the screen;