|  | 
| GetItemMetrics of the CXTPReportRow is NOT virtual | 
| Post Reply   | 
| Author | |
| Kukis   Newbie   Joined: 24 May 2006 Status: Offline Points: 11 |  Post Options  Thanks(0)  Quote  Reply  Topic: GetItemMetrics of the CXTPReportRow is NOT virtual Posted: 05 September 2006 at 5:06am | 
| 
   I wanted to customize my control and noticed that CXTPReportRow class has not virtual GetItemMetrics method. 
 Original GetITemMetrics method has lines which overwrite my custom color settings.  ..... if (GetControl()->HasFocus()) { pItemMetrics->clrForeground = pPaintManager->m_clrHighlightText; pItemMetrics->clrBackground = pPaintManager->m_clrHighlight; } else if (!pPaintManager->m_bHideSelection) { pItemMetrics->clrForeground = pPaintManager->m_clrBtnText; pItemMetrics->clrBackground = pPaintManager->m_clrBtnFace; }.... I wanted to to remove lines which set text color and made my own row class. But because GetItemMetrics is not virtual my code is never called (only at that moment I've noticed that it is not virtual) Could you give my some ideas how to overcome this problem (leave text color of the selected item lets say green)? Change library code? overwrite ondrawcaption of the reportrecorditem? | |
|  | |
| sserge   Moderator Group   Joined: 01 December 2004 Status: Offline Points: 1297 |  Post Options  Thanks(0)  Quote  Reply  Posted: 05 September 2006 at 3:05pm | 
| 
   Hi, You can make CXTPReportRow::GetItemMetrics() as virtual in your toolkit sources and rebuild it. This change will be included in the next release. -- WBR, Serge | |
|  | |
| Post Reply   | |
| Tweet | 
| Forum Jump | Forum Permissions  You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |