Partager via


HitTestThemeBackground (Windows CE 5.0)

Send Feedback

This function retrieves the hit test code for a point within the specified themed background.

HRESULT GetThemeColor(  HTHEME hTheme,  HDC hdc,  int iPartId,  int iStateId,  DWORD dwOptions,  const RECT* pRect,HRGNhrgn,POINT ptTest,WORD* pwHitTestCode);

Parameters

  • hTheme
    [in] Handle to a window's specified theme data. To create a theme data handle, use OpenThemeDataEx.
  • hdc
    [in] Handle to a device context (HDC) used for drawing the background image. This parameter is optional parameter and may be set to NULL.
  • iPartId
    [in] Integer value that specifies the part. For more information, see Theme Parts and States.
  • iStateId
    [in] Integer value that specifies the state of the part. For more information, see Theme Parts and States.
  • dwOptions
    [in] Specifies the hit test options. For more information, see Theme Hit Test Values.
  • pRect
    [in] Pointer to the RECT structure that contains the logical coordinates for the rectangle that bounds the background.
  • hrgn
    [in] Handle to a region that can be used to specify the bounds of a hit test area. This parameter is optional and may be set to NULL.
  • ptTest
    [in] POINT structure that contains the coordinates of the point.
  • pwHitTestCode
    [out] WORD that receives the hit test code that indicates whether or not the coordinates specified in ptTest is in the background area bounded by pRect or hrgn. For the possible hit test return values, see Theme Hit Test Values.

Return Values

Returns S_OK if successful, or E_FAIL otherwise.

Remarks

The values in ptTest and pRect should be in the same coordinate system, such as client or screen. If the hrgn parameter is used, it must be specified in the same coordinates as pRect and ptTest.

Requirements

OS Versions: Windows CE 5.0 and later.
Header: Uxtheme.h.
Link Library: Ietheme.dll.

See Also

Theme Support Reference

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.