/** * @file XTPRibbonThemeNativeWindows10.h * * @copyright * (c) 1998-2025 Codejock Software, All Rights Reserved. * * This source file is the property of Codejock Software and must not be * redistributed by any means without the explicit written permission of * Codejock Software. * * The use of this source code is governed by the terms and conditions specified * in the Toolkit Pro license agreement. Codejock Software grants you, as a * single software developer, the limited right to use this software on one * computer only. * * Contact Information: * support@codejock.com * http://www.codejock.com * */ /** @cond */ #if !defined(__XTPRIBBONNATIVEWINDOWS10THEME_H__) # define __XTPRIBBONNATIVEWINDOWS10THEME_H__ /** @endcond */ # if _MSC_VER > 1000 # pragma once # endif // _MSC_VER > 1000 # include "Common/Base/Diagnostic/XTPDisableNoisyWarnings.h" /** * @brief * CXTPRibbonThemeNativeWindows10 is a CXTPRibbonOffice2013Theme derived class * used to represent a Native Windows 10 ribbon theme. */ class _XTP_EXT_CLASS CXTPRibbonThemeNativeWindows10 : public CXTPRibbonOffice2013Theme , private IXTPPaintManagerCustomAccentColorProvider { public: /** * @brief * Constructs a CXTPRibbonThemeNativeWindows10 object. * @param pPaintManager A CXTPPaintManager object. */ CXTPRibbonThemeNativeWindows10(CXTPPaintManager* pPaintManager); /** * @brief * Destroys a CXTPRibbonThemeNativeWindows10 object, handles cleanup and deallocation. */ virtual ~CXTPRibbonThemeNativeWindows10(); /** * @brief * This method is called to refresh the visual metrics of the manager. * @details * Refreshes all of the colors in the ribbon bar. Many of the colors * used are set with the GROUP_COLOR structure. * @see * GROUP_COLOR */ virtual void RefreshMetrics(); /** * @brief * This method is called to fill the background of a CXTPRibbonGroup. * @param pDC Pointer to a valid device context. * @param pActiveTab Pointer to the tab that is currently active. * @param rcGroups Bounding rectangle of the group. * @details * Performs a gradient fill using the GROUP_COLOR::clrBackground for * the main group background and GROUP_COLOR::clrCaption to fill the * group caption rectangle. * @see * CXTPRibbonGroup::GetRect, GROUP_COLOR */ void FillGroupRect(CDC* pDC, CXTPRibbonTab* pActiveTab, CRect rcGroups); /** * @brief * This method is called to draw a single tab of the ribbon bar. * @param pDC Pointer to a valid device context. * @param pItem Ribbon tab to draw. */ virtual void DrawRibbonTab(CDC* pDC, CXTPRibbonTab* pItem); /** * @brief * This method is called to draw ribbon context headers. * @param pDC Pointer to a valid device context. * @param pContextHeaders Collection of context headers. * @param pRibbonBar Pointer to the parent ribbon bar. */ virtual void DrawRibbonFrameContextHeaders(CDC* pDC, CXTPRibbonBar* pRibbonBar, CXTPRibbonTabContextHeaders* pContextHeaders); private: // IXTPPaintManagerCustomAccentColorProvider overrides virtual COLORREF GetCustomAccentColor(XTPPaintManagerAccentColor nColor); }; # include "Common/Base/Diagnostic/XTPEnableNoisyWarnings.h" /** @cond */ #endif // !defined(__XTPRIBBONNATIVEWINDOWS10THEME_H__) /** @endcond */