Implementing an owner drawn Tab Control - 项目摘要 |
摘要
| 管理 |
论坛 文档
| 软件包 |
|
|
|
项目描述: |
Implementing an owner drawn tab control requires that the tab control have the "owner draw fixed" style (TCS_OWNERDRAWFIXED), and that it have a mechanism for drawing itself when needed.
To draw the tabs, just override the "DrawItem" function in your derived class. This function accepts a pointer to a DRAWITEMSTRUCT structure, which contains the index of the tab to draw (itemID), a handle to a DC (hDC) and the rectangle in which to draw the tab (rcItem).
实现一自绘制的标签控件需要标签控件具有"owner draw fixed" 的风格(TCS_OWNERDRAWFIXED),它提供了需要时的自绘制机制。为了绘制标签,重载你的派生类中的"DrawItem" 函数。这个函数接受一个指向DRAWITEMSTRUCT 结构的指针,它包含了需要绘制的标签的索引, DC (hDC)的句柄,以及绘制标签的矩形区域(rcItem)
来源: http://www.codeguru.com/controls/ownerdraw_tab.shtml |
类别: |
|
发布者:
cbd002
|
|
最新发布源码包 |
软件包 |
版本号 |
日期 |
本地下载 |
ownerdraw |
 1.0  |
2004-04-18 |
下载 |
|
|