OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
owl::TThemePart Class Reference

Encapsulates a themed part. More...

#include <owl/theme.h>

Inheritance diagram for owl::TThemePart:
owl::TTheme

Public Member Functions

 TThemePart (HWND, LPCWSTR cls, int part, int state)
 Constructs a theme part handler.
 
int GetPart () const
 
int GetState () const
 
void SetState (int state)
 
void DrawBackground (HDC, const TRect &dest)
 Paints the background of the themed part.
 
void DrawBackground (HDC, const TRect &dest, const TRect &clip)
 Paints the background of the themed part using a clip rectangle.
 
bool IsBackgroundPartiallyTransparent ()
 Returns true if the theme-specified background for a part has transparent pieces or alpha-blended pieces.
 
void DrawTransparentBackground (HWND control, HDC, const TRect &dest)
 Paints the background of the themed part, properly composited with the parent background.
 
- Public Member Functions inherited from owl::TTheme
 TTheme (HWND, LPCWSTR cls)
 Constructs a theme handler.
 
virtual ~TTheme ()
 Releases the theme handle.
 
HTHEME GetHandle ()
 
 operator HTHEME ()
 

Detailed Description

Encapsulates a themed part.

Definition at line 125 of file theme.h.

Constructor & Destructor Documentation

◆ TThemePart()

owl::TThemePart::TThemePart ( HWND w,
LPCWSTR cls,
int part,
int state )

Constructs a theme part handler.

Definition at line 159 of file theme.cpp.

Member Function Documentation

◆ DrawBackground() [1/2]

void owl::TThemePart::DrawBackground ( HDC dc,
const TRect & dest )

Paints the background of the themed part.

Definition at line 166 of file theme.cpp.

References _T, owl::TTheme::GetHandle(), owl::TThemeModule::GetInstance(), and owl::TXTheme::Raise().

◆ DrawBackground() [2/2]

void owl::TThemePart::DrawBackground ( HDC dc,
const TRect & dest,
const TRect & clip )

Paints the background of the themed part using a clip rectangle.

Definition at line 176 of file theme.cpp.

References _T, owl::TTheme::GetHandle(), owl::TThemeModule::GetInstance(), and owl::TXTheme::Raise().

◆ DrawTransparentBackground()

void owl::TThemePart::DrawTransparentBackground ( HWND control,
HDC dc,
const TRect & dest )

Paints the background of the themed part, properly composited with the parent background.

Assumes there is a window handle associated with the themed part, which should be passed in the control parameter. Combines a call to DrawThemeParentBackground and DrawBackground if the part is partially transparent. Otherwise just calls DrawBackground.

Definition at line 189 of file theme.cpp.

References _T, owl::TTheme::GetHandle(), owl::TThemeModule::GetInstance(), owl::InUse(), IsBackgroundPartiallyTransparent(), owl::TXTheme::Raise(), and WARNX.

◆ GetPart()

int owl::TThemePart::GetPart ( ) const
inline

Definition at line 132 of file theme.h.

◆ GetState()

int owl::TThemePart::GetState ( ) const
inline

Definition at line 133 of file theme.h.

◆ IsBackgroundPartiallyTransparent()

bool owl::TThemePart::IsBackgroundPartiallyTransparent ( )

Returns true if the theme-specified background for a part has transparent pieces or alpha-blended pieces.

Definition at line 207 of file theme.cpp.

References owl::TTheme::GetHandle(), and owl::TThemeModule::GetInstance().

◆ SetState()

void owl::TThemePart::SetState ( int state)
inline

Definition at line 134 of file theme.h.


The documentation for this class was generated from the following files: