MFC Grid manual

CProgressCellPaintFormat Class Reference

Draws a progress bar for numeric-type fields. More...

#include <Dapfor/GUI/ProgressCellPaintFormat.h>

Inheritance diagram for CProgressCellPaintFormat:

CCellPaintFormat ICellPaintFormat

List of all members.


Public Member Functions

 CProgressCellPaintFormat (COLORREF color, long lower=0, long upper=100)
 Constructor.
virtual void DrawCell (CGridCell &cell, const CPaintContext &paintContext, UINT paintFilter) const
 Draws a cell.

Protected Member Functions

virtual void OnDrawText (CGridCell &cell, const CPaintContext &paintContext, UINT paintFilter)
 Draws a scroll bar.

Detailed Description

Draws a progress bar for numeric-type fields.

The format can be applied to fields of the following types: char, unsigned char, short, unsigned short, long, unsigned long, __int64.

Version:
1.0.0.0 Initial version

Member Function Documentation

void DrawCell ( CGridCell cell,
const CPaintContext paintContext,
UINT  paintFilter 
) const [virtual]

Draws a cell.

Excludes GUI::drawHighlight style from PaintFilter enumeration.

Reimplemented from CCellPaintFormat.

void OnDrawText ( CGridCell cell,
const CPaintContext paintContext,
UINT  paintFilter 
) [protected, virtual]

Draws a scroll bar.

Initially the function is called to draw a text inside of a cell, but it paints a progress bar control instead of default behaviour.

Parameters:
[in] cell Cell-related paint info.
[in] paintContext General information like device context, reference to CGrid, header, etc...
[in] paintFilter Set of painting operations, defined in PaintFilter enumeration.

Reimplemented from CCellPaintFormat.