Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - CXTPHeaderCtrl::SetTheme needs love
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPHeaderCtrl::SetTheme needs love

 Post Reply Post Reply
Author
Message
xsensordev View Drop Down
Groupie
Groupie


Joined: 19 August 2021
Location: Canada
Status: Offline
Points: 24
Post Options Post Options   Thanks (0) Thanks(0)   Quote xsensordev Quote  Post ReplyReply Direct Link To This Post Topic: CXTPHeaderCtrl::SetTheme needs love
    Posted: 07 March 2023 at 3:59pm
This method could use some updated theme support. The default themes are very out-of-date.

BOOL CXTPHeaderCtrl::SetTheme(XTPControlTheme eTheme)
{
    CMDTARGET_RELEASE(m_pTheme);

    switch (eTheme)
    {
        case xtpControlThemeFlat:
        case xtpControlThemeUltraFlat:
        case xtpControlThemeOffice2000:
        case xtpControlThemeOfficeXP: m_pTheme = new CXTPHeaderCtrlThemeOfficeXP; break;

        case xtpControlThemeOffice2003: m_pTheme = new CXTPHeaderCtrlThemeOffice2003; break;

        case xtpControlThemeVisualStudio2005:
        case xtpControlThemeVisualStudio2008:
        case xtpControlThemeVisualStudio2010:
        case xtpControlThemeNativeWinXP:
            m_pTheme = new CXTPHeaderCtrlThemeExplorer;
            m_pTheme->SetDrawStyle(HDR_XTP_WINDEF | HDR_XTP_HOTTRACKING | HDR_XTP_SORTARROW, this);
            break;

        case xtpControlThemeResource: m_pTheme = new CXTPHeaderCtrlThemeResource; break;

        case xtpControlThemeDefault:
        default: m_pTheme = new CXTPHeaderCtrlTheme; break;
    }

    RefreshMetrics();

    return (m_pTheme != NULL);
}
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.125 seconds.