LPaintEffect::DrawFrame
#include "ltwrappr.h"
virtual L_INT LPaintEffect::DrawFrame(pRect, uFrameStyle=EFX_FRAME_OUTER_RAISED|EFX_FRAME_ADJUST_RECT)
LPRECT pRect; |
/* the bounding rectangle */ |
L_UINT uFrameStyle; |
/* type of frame style */ |
Draws a rectangular frame with the specified style into the associated device context.
Parameter |
Description |
|
pRect |
The bounding rectangle. |
|
uFrameStyle |
Type of frame style to draw. Possible values are: |
|
|
Value |
Meaning |
|
EFX_FRAME_INNER_INSET |
[0x0000] Inner band inset |
|
EFX_FRAME_INNER_RAISED |
[0x0001] Inner band raised |
|
EFX_FRAME_OUTER_INSET |
[0x0000] Outer band inset |
|
EFX_FRAME_OUTER_RAISED |
[0x0010] Outer band raised |
|
EFX_FRAME_ADJUST_RECT |
[0x0100] Adjust dimensions of the destination rectangle |
Returns
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
Required DLLs and Libraries
LTDIS For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
See Also
Functions: |
|
Topics: |
Example
L_VOID TestEffectFunction(LBitmapBase& LeadBitmap,HDC hDC)
{
LPaintEffect LeadPaintEffect ;
RECT Rect ;
LeadPaintEffect.SetBitmap(&LeadBitmap) ;
LeadPaintEffect.SetDC(hDC);
if (LeadPaintEffect.GetBackgroundColor() != RGB(0,255,0))
LeadPaintEffect.SetBackgroundColor(RGB(0,255,0)) ;
if (LeadPaintEffect.GetForegroundColor() != RGB(255,255,0))
LeadPaintEffect.SetForegroundColor(RGB(255,255,0)) ;
if (LeadPaintEffect.GetMiddleBandColor() != RGB(255,0,0))
LeadPaintEffect.SetMiddleBandColor(RGB(255,0,0)) ;
if (LeadPaintEffect.GetMiddleBandWidth() != RGB(255,10,0))
LeadPaintEffect.SetMiddleBandWidth(RGB(255,10,0)) ;
if (LeadPaintEffect.GetOuterBandWidth() != 3)
LeadPaintEffect.SetOuterBandWidth(3) ;
if (LeadPaintEffect.GetOuterBandShadowColor() != RGB(255,255,255))
LeadPaintEffect.SetOuterBandShadowColor(RGB(255,255,255)) ;
if (LeadPaintEffect.GetOuterBandHilite() != RGB(255,0,255))
LeadPaintEffect.SetOuterBandHilite(RGB(255,0,255)) ;
if (LeadPaintEffect.GetInnerBandWidth() != 3)
LeadPaintEffect.SetInnerBandWidth(3) ;
if (LeadPaintEffect.GetInnerBandShadowColor() != RGB(255,255,255))
LeadPaintEffect.SetOuterBandShadowColor(RGB(255,255,255)) ;
if (LeadPaintEffect.GetInnerBandHilite() != RGB(255,0,255))
LeadPaintEffect.SetInnerBandHilite(RGB(255,0,255)) ;
Rect.left = 50 ;
Rect.top = 50 ;
Rect.right = 200 ;
Rect.bottom = 200 ;
LeadPaintEffect.DrawFrame(&Rect);
LeadPaintEffect.DrawPattern(&Rect,EFX_PATTERN_HORZ_LINE);
}