#include <window.h>


Public Types | |
| typedef SubclassedWindow | super |
Public Member Functions | |
| ColorStatic (HWND hwnd, COLORREF textColor=RGB(255, 0, 0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0) | |
| ColorStatic (HWND owner, int id, COLORREF textColor=RGB(255, 0, 0), HBRUSH hbrush_bkgnd=0, HFONT hfont=0) | |
Protected Member Functions | |
| LRESULT | WndProc (UINT nmsg, WPARAM wparam, LPARAM lparam) |
Protected Attributes | |
| COLORREF | _textColor |
| HBRUSH | _hbrush_bkgnd |
| HFONT | _hfont |
Definition at line 766 of file window.h.
| typedef SubclassedWindow ColorStatic::super |
Reimplemented from SubclassedWindow.
| ColorStatic::ColorStatic | ( | HWND | hwnd, |
| COLORREF | textColor = RGB(255,0,0), |
||
| HBRUSH | hbrush_bkgnd = 0, |
||
| HFONT | hfont = 0 |
||
| ) | [inline] |
Definition at line 770 of file window.h.
: super(hwnd), _textColor(textColor), _hbrush_bkgnd(hbrush_bkgnd), _hfont(hfont) { }
| ColorStatic::ColorStatic | ( | HWND | owner, |
| int | id, | ||
| COLORREF | textColor = RGB(255,0,0), |
||
| HBRUSH | hbrush_bkgnd = 0, |
||
| HFONT | hfont = 0 |
||
| ) | [inline] |
Definition at line 778 of file window.h.
: super(GetDlgItem(owner, id)), _textColor(textColor), _hbrush_bkgnd(hbrush_bkgnd), _hfont(hfont) { }
| LRESULT ColorStatic::WndProc | ( | UINT | nmsg, |
| WPARAM | wparam, | ||
| LPARAM | lparam | ||
| ) | [inline, protected, virtual] |
Reimplemented from SubclassedWindow.
Definition at line 787 of file window.h.
References _hbrush_bkgnd, _hfont, _textColor, PM_DISPATCH_CTLCOLOR, and SubclassedWindow::WndProc().
{
if (nmsg == PM_DISPATCH_CTLCOLOR) {
HDC hdc = (HDC) wparam;
SetTextColor(hdc, _textColor);
if (_hfont)
SelectFont(hdc, _hfont);
if (_hbrush_bkgnd)
return (LRESULT)_hbrush_bkgnd;
else {
SetBkMode(hdc, TRANSPARENT);
return (LRESULT)GetStockBrush(HOLLOW_BRUSH);
}
} else
return super::WndProc(nmsg, wparam, lparam);
}

HBRUSH ColorStatic::_hbrush_bkgnd [protected] |
HFONT ColorStatic::_hfont [protected] |
COLORREF ColorStatic::_textColor [protected] |
|
ROS Explorer Source Code Documentation
generated on 02.01.2013 by
|