HitTestThemeBackground Function


This is preliminary documentation and is subject to change.

Retrieves a hit test code for a point within the theme specified background.

Syntax

HRESULT HitTestThemeBackground(
    HTHEME hTheme, 
    int iPartId, 
    int iStateId, 
    const RECT *pRect, 
    POINT ptTest, 
    WORD *pwHitTestCode
);

Parameters

hTheme
Handle to a window's specified theme data. Use OpenThemeData to create an HTHEME.
iPartId
Integer that specifies the part.
iStateId
Integer that specifies the state of the part.
pRect
Pointer to a RECT structure that contains, in logical coordinates, the rectangle that bounds the background.
ptTest
POINT structure that contains the coordinates of the point.
pwHitTestCode
[out] WORD that receives the hit test code which indicates whether the point in ptTest is in the background area bounded by pRect. The HITTEST values returned are:
HTNOWHERE
Outside of control or on a transparent area.
HTTOPLEFT
Top and left border intersection.
HTLEFT
Left border.
HTBOTTOMLEFT
Bottom and left border intersection.
HTTOP
Top border.
HTCLIENT
In the content area.
HTBOTTOM
Bottom border.
HTTOPRIGHT
Top and right border intersection.
HTRIGHT
Right border
HTBOTTOMRIGHT
Bottom and right border intersection.

Return Value

Returns S_OK if successful, or an error value otherwise.

Remarks

The values in ptTest and pRect should be in the same coordinate system, such as client or screen.

Function Information

Stock ImplementationUxTheme.dll
Custom ImplementationNo
HeaderThemeApi.h
Import libraryUxTheme.lib
Minimum operating systems Windows NT Whistler


© 2000 Microsoft Corporation. All rights reserved. Terms of use.