ExtPaintManager.cpp
上传用户:sesekoo
上传日期:2020-07-18
资源大小:21543k
文件大小:1653k
- } // for( ; nY < _sizeBmp.cy; nY ++ )
- } // if( m_bmpArrButtonSS_simple.IsEmpty() )
- VERIFY(
- m_bmpArrButtonLSM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_ALL_R2) // IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2
- )
- );
- // m_bmpArrButtonLSM.PreMultipliedRGBChannelsSet( true );
- // VERIFY(
- // m_bmpArrButtonLSB.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- // )
- // );
- // m_bmpArrButtonLSB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2)
- )
- );
- m_bmpArrButtonLSXM.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXB.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- )
- );
- m_bmpArrButtonLSXB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingMarginHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_HV_LUNA_BLUE) ) );
- VERIFY( m_bmpRibbonMenuResizingMarginV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_V_LUNA_BLUE) ) );
- VERIFY( m_bmpRibbonMenuResizingGripperHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_HV_LUNA_BLUE) ) );
- m_bmpRibbonMenuResizingGripperHV.Make32();
- m_bmpRibbonMenuResizingGripperHV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingGripperV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_V_LUNA_BLUE) ) );
- m_bmpRibbonMenuResizingGripperV.Make32();
- m_bmpRibbonMenuResizingGripperV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrRibbonModeMenuTextNormal = RGB(20,20,90);
- VERIFY(
- m_bmpRibbonModeMenuBorder.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_BORDER_R2)
- )
- );
- m_bmpRibbonModeMenuBorder.Make32();
- m_bmpRibbonModeMenuBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrMenuCaptionText = RGB(20,20,90);
- m_rcMenuCaptionBmpPadding.SetRect( 0, 2, 0, 2 );
- VERIFY(
- m_bmpMenuCaptionBk.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_CAPTION_BK_R2_LUNA_BLUE)
- )
- );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 12, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R2_LUNA_BLUE) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
-
- m_rcPaddingRibbonFileMenuOptionsButton.SetRect( 2, 2, 2, 2 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonCold.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_COLD_R2_LUNA_BLUE)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonCold.Make32();
- m_bmpRibbonFileMenuOptionsButtonCold.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonHot.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_HOT_R2)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonHot.Make32();
- m_bmpRibbonFileMenuOptionsButtonHot.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpResizingGripper.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RESIZING_GRIPPER_R2_LUNA_BLUE) ) );
- m_bmpResizingGripper.PreMultipliedRGBChannelsSet( true );
- // spin bitmaps
- VERIFY( m_arrBmpSpinArrowDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_DOWN_LUNA_BLUE) ) );
- VERIFY( m_arrBmpSpinArrowUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_UP_LUNA_BLUE) ) );
- VERIFY( m_arrBmpSpinDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_DOWN_LUNA_BLUE) ) );
- VERIFY( m_arrBmpSpinUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_UP_LUNA_BLUE) ) );
- #if (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- m_bShortcutListUseDockerBkgnd = true;
- #endif // (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- }
- CExtPaintManagerOffice2007_R2_Silver::CExtPaintManagerOffice2007_R2_Silver()
- {
- m_clrFillHint = RGB(244,247,251);
- m_clrAccentHint = RGB(255,227,140);
- INT nBmpArrWalkIndex;
- nBmpArrWalkIndex;
- //m_clrIconAlphaColor = RGB(128,128,128); // not needed
- //m_clrForceSplitterBk = RGB(83,83,83);
- m_clrDCA1 = RGB(200,203,211);
- m_clrDCA2 = RGB(200,203,211);
- m_clrDCA3 = RGB(200,203,211);
- m_bDocumentClientAreaBkgndR2 = true;
- VERIFY( m_bmpDCA.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_DCA_SILVER) ) );
- m_clrCustomDropDownGlyphEnabled = RGB(76,83,92);
- m_clrCustomDropDownGlyphDisabled = RGB(141,141,141);
- m_clrDockingFrameDark = RGB(122, 121, 153);
- m_clrFloatingToolbarGripperSolid = RGB(122, 121, 153);
- m_clrDockingFrameCaptionTextActive = RGB(76,83,92);
- m_clrDockingFrameCaptionTextInactive = RGB(76,83,92);
- m_clrDockingFrameCaptionTextFloatingFixed = RGB(255,255,255);
- m_clrDockingCaptionShapeFixedNormal = RGB(0,0,0);
- m_rcNcFrameBordersActive.SetRect( 3, 4, 3, 2 );
- m_rcNcFrameBordersInactive.SetRect( 3, 4, 3, 2 );
- m_nCaptionHeightActive = m_nCaptionHeightInactive = 26;
- VERIFY( m_bmpNcFrameActive.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_FRAME_ACTIVE_SILVER) ) );
- VERIFY( m_bmpNcFrameInactive.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_FRAME_INACTIVE_SILVER) ) );
- VERIFY( m_bmpNcFrameActive.Make32() );
- VERIFY( m_bmpNcFrameInactive.Make32() );
- m_bmpNcFrameActive.AlphaColor( m_clrTransparentNcFrameActive, RGB(0,0,0), 0 );
- m_bmpNcFrameInactive.AlphaColor( m_clrTransparentNcFrameInactive, RGB(0,0,0), 0 );
- m_clrNcFrameTextActive = RGB(92,98,106);
- m_clrNcFrameTextInactive = RGB(105,112,121);
- VERIFY( m_bmpNcButtonBkHover.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_BUTTON_BK_HOVER_LUNA_BLUE) ) );
- m_bmpNcButtonBkHover.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpNcButtonBkPressed.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_BUTTON_BK_PRESSED_LUNA_BLUE) ) );
- m_bmpNcButtonBkPressed.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
-
- VERIFY( m_bmpArrNcButtonsHelp.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_HELP_LUNA_BLUE) ) );
- m_bmpArrNcButtonsHelp.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpArrNcButtonsClose.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_CLOSE_LUNA_BLUE) ) );
- m_bmpArrNcButtonsClose.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpArrNcButtonsMaximize.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_MAXIMIZE_LUNA_BLUE) ) );
- m_bmpArrNcButtonsMaximize.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpArrNcButtonsRestore.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_RESTORE_LUNA_BLUE) ) );
- m_bmpArrNcButtonsRestore.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpArrNcButtonsMinimize.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_MINIMIZE_LUNA_BLUE) ) );
- m_bmpArrNcButtonsMinimize.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- #if (!defined __EXT_MFC_NO_STATUSBAR)
- m_rcStatusBkPadding.SetRect( 0, 1, 0, 1 );
- VERIFY( m_bmpStatusBkLight.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_BK_LIGHT_SILVER) ) );
- // m_bmpStatusBkLight.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- VERIFY( m_bmpStatusBkDark.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_BK_DARK_SILVER) ) );
- // m_bmpStatusBkDark.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- m_rcStatusSeparatorPadding.SetRect( 0, 1, 0, 1 );
- VERIFY( m_bmpStatusSeparator.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_SEPARATOR_SILVER) ) );
- // m_bmpStatusSeparator.AdjustHLS( RGB(255,0,255), RGB(0,0,0), 0.0, 0.0, -1.0 );
- m_clrStatusPaneTextColorDisabled = RGB(128,128,128);
- m_clrStatusPaneTextColorNormal = RGB(32,32,32);
- #endif // (!defined __EXT_MFC_NO_STATUSBAR)
- #if (!defined __EXT_MFC_NO_TAB_CTRL)
- m_clrTabTextNormal = RGB(84,84,84);
- m_clrTabTextSelected = RGB(128,128,128);
- m_nIdxTabShapeHover = 1;
- m_nIdxTabShapePressed = 2;
- m_nIdxTabShapeSelected = 3;
- m_nIdxTabShapeSelectedHover = 4;
- m_arrSizeTabShape[__ETSOI_TOP].cx
- = m_arrSizeTabShape[__ETSOI_BOTTOM].cx
- = m_arrSizeTabShape[__ETSOI_LEFT].cy
- = m_arrSizeTabShape[__ETSOI_RIGHT].cy
- = 57;
- m_arrSizeTabShape[__ETSOI_TOP].cy
- = m_arrSizeTabShape[__ETSOI_BOTTOM].cy
- = m_arrSizeTabShape[__ETSOI_LEFT].cx
- = m_arrSizeTabShape[__ETSOI_RIGHT].cx
- = 24;
- m_arrRectTabShapePadding[__ETSOI_TOP].SetRect( 6, 3, 6, 3 );
- m_arrRectTabShapePadding[__ETSOI_BOTTOM].SetRect( 6, 3, 6, 3 );
- m_arrRectTabShapePadding[__ETSOI_LEFT].SetRect( 3, 6, 3, 6 );
- m_arrRectTabShapePadding[__ETSOI_RIGHT].SetRect( 3, 6, 3, 6 );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SHAPE_ARR_SILVER )
- )
- );
- VERIFY( m_arrBmpTabShapeNormal[__ETSOI_TOP].Make32() );
- // m_arrBmpTabShapeNormal[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 180,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 270,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 90,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SHAPE_ARR_SILVER_SEL_AREA )
- )
- );
- VERIFY( m_arrBmpTabShapeSelArea[__ETSOI_TOP].Make32() );
- m_arrBmpTabShapeSelArea[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 180,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 270,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 90,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- m_arrRectTabAreaPadding[__ETSOI_TOP].SetRect( 3, 3, 3, 3 );
- m_arrRectTabAreaPadding[__ETSOI_BOTTOM].SetRect( 3, 3, 3, 3 );
- m_arrRectTabAreaPadding[__ETSOI_LEFT].SetRect( 3, 3, 3, 3 );
- m_arrRectTabAreaPadding[__ETSOI_RIGHT].SetRect( 3, 3, 3, 3 );
- m_arrTabAreaMargins[__ETSOI_TOP] = 1;
- m_arrTabAreaMargins[__ETSOI_BOTTOM] = 1;
- m_arrTabAreaMargins[__ETSOI_LEFT] = 1;
- m_arrTabAreaMargins[__ETSOI_RIGHT] = 1;
- VERIFY(
- m_arrBmpTabArea[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_AREA_BK_SILVER )
- )
- );
- VERIFY( m_arrBmpTabArea[__ETSOI_TOP].Make32() );
- CSize _sizeTabArea = m_arrBmpTabArea[__ETSOI_TOP].GetSize();
- m_arrBmpTabArea[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 180,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 270,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 90,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- m_arrSizeTabSeparator[__ETSOI_TOP].cx
- = m_arrSizeTabSeparator[__ETSOI_BOTTOM].cx
- = m_arrSizeTabSeparator[__ETSOI_LEFT].cy
- = m_arrSizeTabSeparator[__ETSOI_RIGHT].cy
- = 1;
- m_arrSizeTabSeparator[__ETSOI_TOP].cy
- = m_arrSizeTabSeparator[__ETSOI_BOTTOM].cy
- = m_arrSizeTabSeparator[__ETSOI_LEFT].cx
- = m_arrSizeTabSeparator[__ETSOI_RIGHT].cx
- = 24;
- m_arrRectTabSeparatorPadding[__ETSOI_TOP].SetRect( 0, 2, 0, 2 );
- m_arrRectTabSeparatorPadding[__ETSOI_BOTTOM].SetRect( 0, 2, 0, 2 );
- m_arrRectTabSeparatorPadding[__ETSOI_LEFT].SetRect( 2, 0, 2, 0 );
- m_arrRectTabSeparatorPadding[__ETSOI_RIGHT].SetRect( 2, 0, 2, 0 );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SEPARATOR_SILVER )
- )
- );
- VERIFY( m_arrBmpTabSeparator[__ETSOI_TOP].Make32() );
- m_arrBmpTabSeparator[__ETSOI_TOP].PreMultiplyRGBChannels();
- m_arrBmpTabSeparator[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 180,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 270,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 90,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- #endif // (!defined __EXT_MFC_NO_TAB_CTRL)
- VERIFY(
- m_bmpArrStatesCheckBox.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_CHECK_BOX_R2_OBSIDIAN )
- )
- );
- VERIFY(
- m_bmpArrStatesRadioButton.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_RADIO_BUTTON_R2 )
- )
- );
- m_clrMenuItemLeftAreaMarginL = RGB(197,197,197);
- m_clrMenuItemLeftAreaMarginR = RGB(245,245,245);
- VERIFY(
- m_bmpMenuItemLargeLeft.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_LARGE_LEFT )
- )
- );
- m_bmpMenuItemLargeLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemLargeRight.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_LARGE_RIGHT )
- )
- );
- m_bmpMenuItemLargeRight.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemSmallLeft.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_SMALL_LEFT )
- )
- );
- m_bmpMenuItemSmallLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemSmallRight.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_SMALL_RIGHT )
- )
- );
- m_bmpMenuItemSmallRight.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuArrow.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_ARROW )
- )
- );
- m_sizeMenuCheckAreaChecked.cx = 16;
- m_sizeMenuCheckAreaChecked.cy = 16;
- m_sizeMenuCheckAreaUnchecked.cx = 20;
- m_sizeMenuCheckAreaUnchecked.cy = 20;
- m_arrRectMenuCheckAreaCheckedPadding[0].SetRect( 1, 1, 1, 1 );
- m_arrRectMenuCheckAreaCheckedPadding[1].SetRect( 1, 1, 1, 1 );
- m_arrRectMenuCheckAreaUncheckedPadding[0].SetRect( 2, 2, 2, 2 );
- m_arrRectMenuCheckAreaUncheckedPadding[1].SetRect( 2, 2, 2, 2 );
- VERIFY( m_bmpMenuCheckAreaChecked.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_MENU_CHECK_AREA_CHECKED_R2 ) ) );
- VERIFY( m_bmpMenuCheckAreaUnchecked.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_MENU_CHECK_AREA_UNCHECKED_R2 ) ) );
- #if (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_arrClrPnCaptNormal[0] = RGB(235,238,250);
- m_arrClrPnCaptNormal[1] = RGB(215,219,229);
- m_arrClrPnCaptNormal[2] = RGB(197,199,209);
- m_arrClrPnCaptNormal[3] = RGB(212,216,226);
- m_arrClrPnSplitter[0] = RGB(255,255,255);
- m_arrClrPnSplitter[1] = RGB(120,119,151);
- m_clrPnCaptText = RGB(21,66,139);
- m_arrClrPnItemText[0] = RGB(0,0,0);
- m_arrClrPnItemText[1] = RGB(76,83,92);
- m_clrPnConfigButton = RGB(101,104,112);
- #endif // (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- VERIFY( m_bmpArrComboBoxDropDown.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_COMBO_BOX_BUTTON_R2_OBSIDIAN ) ) );
- m_arrClrComboBoxBorder[0] = RGB(169,177,184);
- m_arrClrComboBoxBorder[1] = RGB(169,177,184);
- m_arrClrComboBoxBorder[2] = RGB(169,177,184);
- m_arrClrComboBoxBorder[3] = RGB(169,177,184);
- CRect SbSkinDataPaddingH( 5, 3, 5, 3 ), SbSkinDataPaddingV( 3, 5, 3, 5 );
- CRect rcEntirePaddingRH( 0, 2, 0, 2 ), rcEntirePaddingRV( 2, 0, 2, 0 );
- CRect rcEntirePaddingCH( 1, 1, 1, 1 ), rcEntirePaddingCV( 1, 1, 1, 1 );
- m_SbSkinDataT_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_TOP
- );
- m_SbSkinDataB_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_BOTTOM
- );
- m_SbSkinDataL_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_LEFT
- );
- m_SbSkinDataR_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_RIGHT
- );
- m_SbSkinDataH_Light.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_HORZ_OBSIDIAN,
- 15,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_HORZ,
- 8,
- SbSkinDataPaddingH,
- COLORREF(-1L), // RGB(117,150,192),
- COLORREF(-1L), // RGB(91,99,116),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- true,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_LIGHT,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_LIGHT,
- rcEntirePaddingRH,
- rcEntirePaddingCH
- );
- m_SbSkinDataV_Light.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_VERT_OBSIDIAN,
- 21,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_VERT,
- 8,
- SbSkinDataPaddingV,
- COLORREF(-1L), // RGB(117,150,192),
- COLORREF(-1L), // RGB(91,99,116),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- false,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_LIGHT,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_LIGHT,
- rcEntirePaddingRV,
- rcEntirePaddingCV
- );
- m_SbSkinDataH_Dark.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_HORZ_OBSIDIAN,
- 15,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_HORZ,
- 8,
- SbSkinDataPaddingH,
- COLORREF(-1L), // RGB(117,150,192),
- COLORREF(-1L), // RGB(91,99,116),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- true,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_SILVER_DARK,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_SILVER_DARK,
- rcEntirePaddingRH,
- rcEntirePaddingCH
- );
- m_SbSkinDataV_Dark.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_VERT_OBSIDIAN,
- 21,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_VERT,
- 8,
- SbSkinDataPaddingV,
- COLORREF(-1L), // RGB(117,150,192),
- COLORREF(-1L), // RGB(91,99,116),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- false,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_SILVER_DARK,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_SILVER_DARK,
- rcEntirePaddingRV,
- rcEntirePaddingCV
- );
- m_clrGridHeaderBkTop = RGB(253,253,253);
- m_clrGridHeaderBkBottom = RGB(212,215,220);
- m_clrGridHeaderSeparator = RGB(145,153,164);
- m_clrGridHeaderSortArrow = RGB(145,153,164);
- m_clrGridHeaderBorder = RGB(145,153,164);
- m_clrRgHeaderBkTop = RGB(253,253,253);
- m_clrRgHeaderBkBottom = RGB(212,215,220);
- m_clrRgHeaderSeparator = RGB(145,153,164);
- m_clrRgHeaderSortArrow = RGB(145,153,164);
- m_clrRgHeaderText = RGB(0,0,0);
- m_clrRgHeaderBorder = RGB(76,83,92);
- #if (!defined __EXT_MFC_NO_REPORTGRIDWND)
- m_clrRgGroupAreaBk = RGB(235,235,235);
- m_clrRgGroupAreaText = RGB(70,70,70);
- #endif // (!defined __EXT_MFC_NO_REPORTGRIDWND)
- // m_nTbbLightWeightSimpleGlyphHeightV = 20;
- // m_nTbbLightWeightSDDLeftGlyphHeightV = 23;
- // m_nTbbLightWeightSDDRightGlyphHeightV = 10;
- // VERIFY(
- // m_arrBmpTbbLightWeightSimpleH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_SIMPLE )
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDLeftH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_LEFT_PART )
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDRightH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_RIGHT_PART )
- // )
- // );
- // // m_arrBmpTbbLightWeightSimpleH.PreMultipliedRGBChannelsSet( true );
- // // m_arrBmpTbbLightWeightSDDLeftH.PreMultipliedRGBChannelsSet( true );
- // // m_arrBmpTbbLightWeightSDDRightH.PreMultipliedRGBChannelsSet( true );
- // VERIFY(
- // m_arrBmpTbbLightWeightSimpleV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSimpleH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSimpleH.GetSize().cx,
- // m_nTbbLightWeightSimpleGlyphHeightH,
- // false,
- // false
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDLeftV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSDDLeftH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSDDLeftH.GetSize().cx,
- // m_nTbbLightWeightSDDLeftGlyphHeightH,
- // false,
- // false
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDRightV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSDDRightH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSDDRightH.GetSize().cx,
- // m_nTbbLightWeightSDDRightGlyphHeightH,
- // false,
- // false
- // )
- // );
- m_nPushBtnSimpleGlyphHeightV = 20;
- m_nPushBtnSDDLeftGlyphHeightV = 23;
- m_nPushBtnSDDRightGlyphHeightV = 10;
- VERIFY(
- m_arrBmpPushBtnSimpleH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_SIMPLE )
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDLeftH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_LEFT_PART )
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDRightH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_RIGHT_PART )
- )
- );
- // m_arrBmpPushBtnSimpleH.PreMultipliedRGBChannelsSet( true );
- // m_arrBmpPushBtnSDDLeftH.PreMultipliedRGBChannelsSet( true );
- // m_arrBmpPushBtnSDDRightH.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpPushBtnSimpleV.CreateRotated9xStack(
- m_arrBmpPushBtnSimpleH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSimpleH.GetSize().cx,
- m_nPushBtnSimpleGlyphHeightH,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDLeftV.CreateRotated9xStack(
- m_arrBmpPushBtnSDDLeftH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSDDLeftH.GetSize().cx,
- m_nPushBtnSDDLeftGlyphHeightH,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDRightV.CreateRotated9xStack(
- m_arrBmpPushBtnSDDRightH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSDDRightH.GetSize().cx,
- m_nPushBtnSDDRightGlyphHeightH,
- false,
- false
- )
- );
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- m_nQatbAdditionalSpaceAtRightDWM = 30;
- m_clrContractedMargin1 = RGB(220,225,235);
- m_clrContractedMargin2 = RGB(128,128,128);
- m_nContractedMarginHeight = 2;
- m_bRibbonGroupCaptionAtTop = false;
- m_bRibbonGroupCaptionAreaHasPadding = true;
- m_nRibbonGroupCaptionAreaHeightExpanded = 16;
- m_nRibbonGroupCaptionAreaHeightCollapsed = 16;
- m_nRibbonCaptionPartHeight = 17;
- m_nRibbonGroupIconBkVertOffset = 2;
- m_clrRibbonComboBackGroundNormal = RGB(232,232,232);
- m_nRibbonTabIntersectionHeight = 1;
- m_clrRibbonButtonDisabled = RGB(128,128,128);
- m_clrRibbonGroupCaptionTextExpanded = RGB( 84, 84, 84 );
- m_nRibbonGroupCaptionTextDF
- = m_nRibbonGroupCaptionTextShadowDF
- = DT_SINGLELINE|DT_CENTER|DT_VCENTER|DT_END_ELLIPSIS;
- m_rcRibbonPageBkPadding.SetRect( 5, 19, 5, 10 );
- VERIFY(
- m_bmpRibbonPageBk.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_PAGE_BK_R2_SILVER)
- )
- );
- // m_bmpRibbonPageBk.Make32();
- // m_bmpRibbonPageBk.PreMultipliedRGBChannelsSet( true );
-
- m_rcRibbonGroupPaddingBkExpanded.SetRect( 4, 4, 4, 4 );
- VERIFY(
- m_bmpRibbonGroupBkExpanded[0].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_EXPANDED_NORMAL_BK_R2_SILVER)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkExpanded[1].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_EXPANDED_HOVER_BK_R2_SILVER)
- )
- );
-
- m_rcRibbonGroupPaddingBkCollapsed.SetRect( 4, 18, 4, 4 );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[0].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_NORMAL_BK_R2_SILVER)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[1].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_HOVER_BK_R2_SILVER)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[2].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_PRESSED_BK_R2_SILVER)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[3].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_SELECTED_BK_R2)
- )
- );
- INT nBkIndex, nBkCount;
- nBkCount = sizeof( m_bmpRibbonGroupBkExpanded ) / sizeof( m_bmpRibbonGroupBkExpanded[0] );
- for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- {
- m_bmpRibbonGroupBkExpanded[nBkIndex].Make32();
- m_bmpRibbonGroupBkExpanded[nBkIndex].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- } // for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- nBkCount = sizeof( m_bmpRibbonGroupBkCollapsed ) / sizeof( m_bmpRibbonGroupBkCollapsed[0] );
- for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- {
- m_bmpRibbonGroupBkCollapsed[nBkIndex].Make32();
- m_bmpRibbonGroupBkCollapsed[nBkIndex].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- } // for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[0].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_NORMAL_BK_R2_OBSIDIAN)
- // )
- // );
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[1].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_HOVER_BK_R2_OBSIDIAN)
- // )
- // );
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[2].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_PRESSED_BK_R2_OBSIDIAN)
- // )
- // );
- VERIFY(
- m_bmpRibbonIconBkCF.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_COLLAPSED_ICON_FRAME_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonIconBkCF.PreMultiplyRGBChannels( false );
- // m_bmpRibbonIconBkCF.PreMultipliedRGBChannelsSet( true );
- m_nRibbonSeparatorDrawModeH = INT( CExtBitmap::__EDM_STRETCH );
- m_nRibbonSeparatorDrawModeV = INT( CExtBitmap::__EDM_STRETCH );
- m_rcRibbonSeparatorPaddingH.SetRect( 6, 0, 6, 0 );
- VERIFY(
- m_bmpRibbonSeparatorH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_SEPARATOR_H_R2_OBSIDIAN)
- )
- );
- VERIFY( m_bmpRibbonSeparatorH.Make32() );
- m_bmpRibbonSeparatorH.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_rcRibbonSeparatorPaddingV.SetRect( 0, 6, 0, 6 );
- VERIFY(
- m_bmpRibbonSeparatorV.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_SEPARATOR_V_R2_OBSIDIAN)
- )
- );
- VERIFY( m_bmpRibbonSeparatorV.Make32() );
- m_bmpRibbonSeparatorV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_nRibbonHeightOfQACEB = 22;
- m_nIdxRibbonQACEB_Selected = 3;
- VERIFY(
- m_bmpArrRibbonQACEB.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_QATB_CEB_R2_OBSIDIAN)
- )
- );
- //m_bmpArrRibbonQACEB.PreMultipliedRGBChannelsSet( true );
- m_clrRibbon_EmbeddedCaptionTextLeft = RGB(100,100,100);
- m_clrRibbon_EmbeddedCaptionTextRight = RGB( 65, 115, 175 );;
- m_bRibbonFileButtonItegrationSupported = true;
- INT nCaptionHeightActive = NcFrame_GetCaptionHeight( true, NULL ) + m_rcNcFrameBordersActive.top;
- INT nCaptionHeightInactive = NcFrame_GetCaptionHeight( false, NULL ) + m_rcNcFrameBordersInactive.top;
- CExtBitmap::Filter _fBox( CExtBitmap::Filter::box );
- m_rcRibbonNcCornerLeftCP.SetRect( 22, 8, 2, 2 );
- m_rcRibbonNcCornerRightCP.SetRect( 2, 8, 22, 2 );
- VERIFY(
- m_bmpRibbonNcCornerActiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R2_SILVER)
- )
- );
- m_bmpRibbonNcCornerActiveLeft.Make32();
- m_bmpRibbonNcCornerActiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- // m_bmpRibbonNcCornerActiveLeft.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerActiveLeft.Scale(
- m_bmpRibbonNcCornerActiveLeft.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerInactiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_LEFT_R2_SILVER)
- )
- );
- m_bmpRibbonNcCornerInactiveLeft.Make32();
- m_bmpRibbonNcCornerInactiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- // m_bmpRibbonNcCornerInactiveLeft.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerInactiveLeft.Scale(
- m_bmpRibbonNcCornerInactiveLeft.GetSize().cx,
- nCaptionHeightInactive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerActiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R2_SILVER)
- )
- );
- m_bmpRibbonNcCornerActiveRight.Make32();
- m_bmpRibbonNcCornerActiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- // m_bmpRibbonNcCornerActiveRight.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerActiveRight.Scale(
- m_bmpRibbonNcCornerActiveRight.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerInactiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_RIGHT_R2_SILVER)
- )
- );
- m_bmpRibbonNcCornerInactiveRight.Make32();
- m_bmpRibbonNcCornerInactiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- // m_bmpRibbonNcCornerInactiveRight.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerInactiveRight.Scale(
- m_bmpRibbonNcCornerInactiveRight.GetSize().cx,
- nCaptionHeightInactive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerHT.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_HT_MASK_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerHT.Make32();
- m_bmpRibbonNcCornerHT.Scale(
- m_bmpRibbonNcCornerHT.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY( m_bmpArrRibbonFileButton.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_FILE_BUTTON_R2_OBSIDIAN) ) );
- //m_bmpArrRibbonFileButton.PreMultipliedRGBChannelsSet( true );
- m_rcPaddingRibbonQuickAccessBarBkAtTheBottom.SetRect( 3, 3, 3, 3 );
- VERIFY( m_bmpRibbonQuickAccessBarBkAtTheBottom.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_QATB_BK_R2_SILVER) ) );
- m_nRibbonHeightOfOneDLB = 14;
- m_nDlbIdxDisabled = 3;
- m_nDlbIdxNormal = 0;
- m_nDlbIdxHover = 1;
- m_nDlbIdxPressed = 2;
- rcRibbonContentPaddingDLB.SetRect( 2, 2, 2, 2 );
- VERIFY( m_arrBmpRibbonDLB.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_GCB_R2_OBSIDIAN) ) );
- // m_arrBmpRibbonDLB.PreMultipliedRGBChannelsSet( true );
- m_clrRibbonGalleryInplaceBorderNormal = RGB(172,172,172);
- m_clrRibbonGalleryInplaceBorderHover = RGB(172,172,172);
- m_clrRibbonGalleryInplaceBkgndNormal = RGB(232,234,236);
- m_clrRibbonGalleryInplaceBkgndHover = RGB(247,247,247);
- m_rcRibbonGalleryScrollFill = RGB(218,226,226);
- m_rcRibbonGalleryScrollButtonPadding.SetRect( 4, 4, 4, 4 );
- m_nHeightRibbonGalleryScrollButton = -1;
- m_nIndexRibbonGalleryScrollButtonDisabled = 4;
- m_nIndexRibbonGalleryScrollButtonNormal = 1;
- m_nIndexRibbonGalleryScrollButtonHover = 2;
- m_nIndexRibbonGalleryScrollButtonPressed = 3;
- VERIFY(
- m_bmpArrRibbonGalleryScrollButtonDown.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_DOWN_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpArrRibbonGalleryScrollButtonUp.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_UP_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpArrRibbonGalleryScrollButtonMenu.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_MENU_R2_OBSIDIAN)
- )
- );
- #endif // (!defined __EXT_MFC_NO_RIBBON_BAR)
- VERIFY( m_bmpRibbonDDA.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_DDA_R2_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonDDA.Make32() );
- m_bmpRibbonDDA.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpArrRibbonComboBoxDropDown.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_COMBO_BOX_BUTTON_R2_SILVER) ) );
- // tool buttons 2007
- m_arrIndicesButtonTS[INT(__E07BI_NORMAL)] = 0;
- m_arrIndicesButtonTS[INT(__E07BI_HOVER)] = 3;
- m_arrIndicesButtonTS[INT(__E07BI_PRESSED)] = 2;
- m_arrIndicesButtonTS[INT(__E07BI_HDD)] = 3;
- m_arrIndicesButtonTS[INT(__E07BI_SEL_T)] = 1;
- m_arrIndicesButtonTS[INT(__E07BI_INDETERMINATE)] = 0;
- m_arrIndicesButtonSS_Left[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonSS_Left[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonSS_Left[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonSS_Left[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonSS_Left[INT(__E07BI_SEL_T)] = 5;
- m_arrIndicesButtonSS_Left[INT(__E07BI_INDETERMINATE)] = 4;
- m_arrIndicesButtonSS_Right[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonSS_Right[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonSS_Right[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonSS_Right[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonSS_Right[INT(__E07BI_SEL_T)] = 4;
- m_arrIndicesButtonSS_Right[INT(__E07BI_INDETERMINATE)] = 3;
- m_arrIndicesButtonLSM[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonLSM[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonLSM[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonLSM[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonLSM[INT(__E07BI_SEL_T)] = 0;
- m_arrIndicesButtonLSM[INT(__E07BIX_INDETERMINATE)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_NORMAL)] = -1;
- // m_arrIndicesButtonLSB[INT(__E07BI_HOVER)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_PRESSED)] = 1;
- // m_arrIndicesButtonLSB[INT(__E07BI_HDD)] = 2;
- // m_arrIndicesButtonLSB[INT(__E07BI_SEL_T)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_INDETERMINATE)] = 0;
- m_arrIndicesButtonLSXM[INT(__E07BIX_NORMAL)] = -1;
- m_arrIndicesButtonLSXM[INT(__E07BIX_HOVER)] = 0;
- m_arrIndicesButtonLSXM[INT(__E07BIX_HOVER2)] = 5;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED)] = 1;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED2)] = 2;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED3)] = 3;
- m_arrIndicesButtonLSXM[INT(__E07BIX_INDETERMINATE)] = 4;
- m_arrIndicesButtonLSXM[INT(__E07BIX_SELECTED)] = 5;
- m_arrIndicesButtonLSXB[INT(__E07BIX_NORMAL)] = -1;
- m_arrIndicesButtonLSXB[INT(__E07BIX_HOVER)] = 0;
- m_arrIndicesButtonLSXB[INT(__E07BIX_HOVER2)] = 4;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED)] = 1;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED2)] = 2;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED3)] = 2;
- m_arrIndicesButtonLSXB[INT(__E07BIX_INDETERMINATE)] = 3;
- m_arrIndicesButtonLSXB[INT(__E07BIX_SELECTED)] = 4;
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_SOLID)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SOLID_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_SOLID)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_LEFT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_LEFT_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_LEFT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_MIDDLE)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_MIDDLE_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_MIDDLE)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_RIGHT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_RIGHT_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_RIGHT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonSS_DD[INT(__EBSSA_LEFT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_SMALL_LEFT_R2)
- )
- );
- m_bmpArrButtonSS_DD[INT(__EBSSA_LEFT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonSS_DD[INT(__EBSSA_RIGHT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_SMALL_RIGHT_R2)
- )
- );
- m_bmpArrButtonSS_DD[INT(__EBSSA_RIGHT)].PreMultipliedRGBChannelsSet( true );
- m_bmpArrButtonSS_simple = m_bmpArrButtonSS_DD[ INT(__EBSSA_LEFT) ];
- if( ! m_bmpArrButtonSS_simple.IsEmpty() )
- {
- CSize _sizeBmp = m_bmpArrButtonSS_simple.GetSize();
- INT nY = 0, nXRange = _sizeBmp.cx / 2;
- for( ; nY < _sizeBmp.cy; nY ++ )
- {
- INT nXSrc = nXRange - 1, nXDst = _sizeBmp.cx - nXRange;
- for( ; nXDst < _sizeBmp.cx; nXDst ++, nXSrc -- )
- {
- RGBQUAD _pixel;
- VERIFY( m_bmpArrButtonSS_simple.GetPixel( nXSrc, nY, _pixel ) );
- VERIFY( m_bmpArrButtonSS_simple.SetPixel( nXDst, nY, _pixel ) );
- } // for( ; nXDst < _sizeBmp.cx; nXDst ++, nXSrc -- )
- } // for( ; nY < _sizeBmp.cy; nY ++ )
- } // if( m_bmpArrButtonSS_simple.IsEmpty() )
- VERIFY(
- m_bmpArrButtonLSM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_ALL_R2) // IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2
- )
- );
- // m_bmpArrButtonLSM.PreMultipliedRGBChannelsSet( true );
- // VERIFY(
- // m_bmpArrButtonLSB.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- // )
- // );
- // m_bmpArrButtonLSB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2)
- )
- );
- m_bmpArrButtonLSXM.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXB.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- )
- );
- m_bmpArrButtonLSXB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingMarginHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_HV_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonMenuResizingMarginV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_V_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonMenuResizingGripperHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_HV_OBSIDIAN) ) );
- m_bmpRibbonMenuResizingGripperHV.Make32();
- m_bmpRibbonMenuResizingGripperHV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingGripperV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_V_OBSIDIAN) ) );
- m_bmpRibbonMenuResizingGripperV.Make32();
- m_bmpRibbonMenuResizingGripperV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrRibbonModeMenuTextNormal = RGB(0,0,0);
- VERIFY(
- m_bmpRibbonModeMenuBorder.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_BORDER_R2)
- )
- );
- m_bmpRibbonModeMenuBorder.Make32();
- m_bmpRibbonModeMenuBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrMenuCaptionText = RGB(20,20,90);
- m_rcMenuCaptionBmpPadding.SetRect( 0, 2, 0, 2 );
- VERIFY(
- m_bmpMenuCaptionBk.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_CAPTION_BK_R2_OBSIDIAN)
- )
- );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 12, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R2_SILVER) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
-
- m_rcPaddingRibbonFileMenuOptionsButton.SetRect( 2, 2, 2, 2 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonCold.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_COLD_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonCold.Make32();
- m_bmpRibbonFileMenuOptionsButtonCold.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonHot.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_HOT_R2)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonHot.Make32();
- m_bmpRibbonFileMenuOptionsButtonHot.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpResizingGripper.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RESIZING_GRIPPER_R2_OBSIDIAN) ) );
- m_bmpResizingGripper.PreMultipliedRGBChannelsSet( true );
- // spin bitmaps
- VERIFY( m_arrBmpSpinArrowDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_DOWN_SILVER) ) );
- VERIFY( m_arrBmpSpinArrowUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_UP_SILVER) ) );
- VERIFY( m_arrBmpSpinDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_DOWN_SILVER) ) );
- VERIFY( m_arrBmpSpinUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_UP_SILVER) ) );
- #if (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- m_bShortcutListUseDockerBkgnd = true;
- #endif // (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- }
- CExtPaintManagerOffice2007_R3_Silver::CExtPaintManagerOffice2007_R3_Silver()
- {
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- m_nQatbAdditionalSpaceAtRightDWM = 0;
- // INT nCaptionHeightActive = NcFrame_GetCaptionHeight( true, NULL ) + m_rcNcFrameBordersActive.top;
- // INT nCaptionHeightInactive = NcFrame_GetCaptionHeight( false, NULL ) + m_rcNcFrameBordersInactive.top;
- // CExtBitmap::Filter _fBox( CExtBitmap::Filter::box );
- m_rcRibbonNcCornerLeftCP.SetRect( 53, 2, 2, 2 );
- m_rcRibbonNcCornerRightCP.SetRect( 2, 2, 42, 2 );
- VERIFY(
- m_bmpRibbonNcCornerDwmLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_LEFT_R3_SILVER)
- )
- );
- //m_bmpRibbonNcCornerDwmLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpRibbonNcCornerDwmRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_RIGHT_R3_SILVER)
- )
- );
- //m_bmpRibbonNcCornerDwmRight.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerDwmLeft.AdjustAlpha( -0.60 );
- m_bmpRibbonNcCornerDwmRight.AdjustAlpha( -0.60 );
- VERIFY(
- m_bmpRibbonNcCornerActiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R3_SILVER)
- )
- );
- // m_bmpRibbonNcCornerActiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveLeft.Scale(
- // m_bmpRibbonNcCornerActiveLeft.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveLeft.Make32() );
- m_bmpRibbonNcCornerActiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_LEFT_R3_SILVER)
- )
- );
- // m_bmpRibbonNcCornerInactiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveLeft.Scale(
- // m_bmpRibbonNcCornerInactiveLeft.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveLeft.Make32() );
- m_bmpRibbonNcCornerInactiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerActiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R3_SILVER)
- )
- );
- // m_bmpRibbonNcCornerActiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveRight.Scale(
- // m_bmpRibbonNcCornerActiveRight.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveRight.Make32() );
- m_bmpRibbonNcCornerActiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_RIGHT_R3_SILVER)
- )
- );
- // m_bmpRibbonNcCornerInactiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveRight.Scale(
- // m_bmpRibbonNcCornerInactiveRight.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveRight.Make32() );
- m_bmpRibbonNcCornerInactiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- // VERIFY(
- // m_bmpRibbonNcCornerHT.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_HT_MASK_R2_SILVER)
- // )
- // );
- // m_bmpRibbonNcCornerHT.Make32();
- // m_bmpRibbonNcCornerHT.Scale(
- // m_bmpRibbonNcCornerHT.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- m_bmpRibbonNcCornerHT.Empty();
- VERIFY( m_bmpArrRibbonFileButton.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_FILE_BUTTON_R3_SILVER) ) );
- //m_bmpArrRibbonFileButton.PreMultipliedRGBChannelsSet( true );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 18, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R3_SILVER) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_sizeAboveTheRibbonShiftQACEB.cx = 10;
- m_sizeAboveTheRibbonShiftQACEB.cy = 0;
- m_nRibbonFileButtonMenuIntersectionHeight = 20;
- #endif // (!defined __EXT_MFC_NO_RIBBON_BAR)
- }
- CExtPaintManagerOffice2007_R3_LunaBlue::CExtPaintManagerOffice2007_R3_LunaBlue()
- {
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- m_nQatbAdditionalSpaceAtRightDWM = 0;
- // INT nCaptionHeightActive = NcFrame_GetCaptionHeight( true, NULL ) + m_rcNcFrameBordersActive.top;
- // INT nCaptionHeightInactive = NcFrame_GetCaptionHeight( false, NULL ) + m_rcNcFrameBordersInactive.top;
- // CExtBitmap::Filter _fBox( CExtBitmap::Filter::box );
- m_rcRibbonNcCornerLeftCP.SetRect( 53, 2, 2, 2 );
- m_rcRibbonNcCornerRightCP.SetRect( 2, 2, 42, 2 );
- VERIFY(
- m_bmpRibbonNcCornerDwmLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_LEFT_R3_LUNA_BLUE)
- )
- );
- //m_bmpRibbonNcCornerDwmLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpRibbonNcCornerDwmRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_RIGHT_R3_LUNA_BLUE)
- )
- );
- //m_bmpRibbonNcCornerDwmRight.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerDwmLeft.AdjustAlpha( -0.60 );
- m_bmpRibbonNcCornerDwmRight.AdjustAlpha( -0.60 );
- VERIFY(
- m_bmpRibbonNcCornerActiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R3_LUNA_BLUE)
- )
- );
- // m_bmpRibbonNcCornerActiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveLeft.Scale(
- // m_bmpRibbonNcCornerActiveLeft.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveLeft.Make32() );
- m_bmpRibbonNcCornerActiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_LEFT_R3_LUNA_BLUE)
- )
- );
- // m_bmpRibbonNcCornerInactiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveLeft.Scale(
- // m_bmpRibbonNcCornerInactiveLeft.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveLeft.Make32() );
- m_bmpRibbonNcCornerInactiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerActiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R3_LUNA_BLUE)
- )
- );
- // m_bmpRibbonNcCornerActiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveRight.Scale(
- // m_bmpRibbonNcCornerActiveRight.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveRight.Make32() );
- m_bmpRibbonNcCornerActiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_RIGHT_R3_LUNA_BLUE)
- )
- );
- // m_bmpRibbonNcCornerInactiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveRight.Scale(
- // m_bmpRibbonNcCornerInactiveRight.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveRight.Make32() );
- m_bmpRibbonNcCornerInactiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- // VERIFY(
- // m_bmpRibbonNcCornerHT.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_HT_MASK_R2_LUNA_BLUE)
- // )
- // );
- // m_bmpRibbonNcCornerHT.Make32();
- // m_bmpRibbonNcCornerHT.Scale(
- // m_bmpRibbonNcCornerHT.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- m_bmpRibbonNcCornerHT.Empty();
- VERIFY( m_bmpArrRibbonFileButton.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_FILE_BUTTON_R3_LUNA_BLUE) ) );
- //m_bmpArrRibbonFileButton.PreMultipliedRGBChannelsSet( true );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 18, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R3_LUNA_BLUE) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_sizeAboveTheRibbonShiftQACEB.cx = 10;
- m_sizeAboveTheRibbonShiftQACEB.cy = 0;
- m_nRibbonFileButtonMenuIntersectionHeight = 20;
- #endif // (!defined __EXT_MFC_NO_RIBBON_BAR)
- }
- CExtPaintManagerOffice2007_R2_LunaBlue::~CExtPaintManagerOffice2007_R2_LunaBlue()
- {
- }
- CExtPaintManagerOffice2007_R2_Silver::~CExtPaintManagerOffice2007_R2_Silver()
- {
- }
- CExtPaintManagerOffice2007_R3_Silver::~CExtPaintManagerOffice2007_R3_Silver()
- {
- }
- CExtPaintManagerOffice2007_R3_LunaBlue::~CExtPaintManagerOffice2007_R3_LunaBlue()
- {
- }
- CExtPaintManagerOffice2007_R2_Obsidian::CExtPaintManagerOffice2007_R2_Obsidian()
- {
- m_clrFillHint = RGB(173,174,189);
- m_clrAccentHint = RGB(255,227,140);
- //m_clrIconAlphaColor = RGB(128,128,128); // not needed
- m_clrForceSplitterBk = RGB(83,83,83);
- m_clrDCA1 = RGB(72,72,72);
- m_clrDCA2 = RGB(45,45,45);
- m_clrDCA3 = RGB(10,10,10);
- m_bDocumentClientAreaBkgndR2 = true;
- VERIFY( m_bmpDCA.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_DCA_OBSIDIAN) ) );
- m_clrCustomDropDownGlyphEnabled = RGB(0,0,0);
- m_clrCustomDropDownGlyphDisabled = RGB(141,141,141);
- m_clrDockingFrameDark = RGB(49,60,66);
- m_clrFloatingToolbarGripperSolid = RGB(74,81,90);
- m_clrDockingFrameCaptionTextActive = RGB(0,0,0);
- m_clrDockingFrameCaptionTextInactive = RGB(0,0,0);
- m_clrDockingFrameCaptionTextFloatingFixed = RGB(255,255,255);
- m_clrDockingCaptionShapeFixedNormal = RGB(255,255,255);
- m_rcNcFrameBordersActive.SetRect( 3, 4, 3, 2 );
- m_rcNcFrameBordersInactive.SetRect( 3, 4, 3, 2 );
- m_nCaptionHeightActive = m_nCaptionHeightInactive = 26;
- VERIFY( m_bmpNcFrameActive.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_FRAME_ACTIVE_OBSIDIAN) ) );
- VERIFY( m_bmpNcFrameInactive.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_FRAME_INACTIVE_OBSIDIAN) ) );
- VERIFY( m_bmpNcFrameActive.Make32() );
- VERIFY( m_bmpNcFrameInactive.Make32() );
- m_bmpNcFrameActive.AlphaColor( m_clrTransparentNcFrameActive, RGB(0,0,0), 0 );
- m_bmpNcFrameInactive.AlphaColor( m_clrTransparentNcFrameInactive, RGB(0,0,0), 0 );
- m_clrNcFrameTextActive = RGB(255,255,255); // = RGB(174,209,255);
- m_clrNcFrameTextInactive = RGB(183,183,183); // = RGB(255,255,255); // = RGB(174,209,255);
- VERIFY( m_bmpNcButtonBkHover.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_BUTTON_BK_HOVER_OBSIDIAN) ) );
- VERIFY( m_bmpNcButtonBkPressed.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_BUTTON_BK_PRESSED_OBSIDIAN) ) );
-
- VERIFY( m_bmpArrNcButtonsHelp.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_HELP_OBSIDIAN) ) );
- VERIFY( m_bmpArrNcButtonsClose.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_CLOSE_OBSIDIAN) ) );
- VERIFY( m_bmpArrNcButtonsMaximize.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_MAXIMIZE_OBSIDIAN) ) );
- VERIFY( m_bmpArrNcButtonsRestore.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_RESTORE_OBSIDIAN) ) );
- VERIFY( m_bmpArrNcButtonsMinimize.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_NC_ARR_MINIMIZE_OBSIDIAN) ) );
- #if (!defined __EXT_MFC_NO_STATUSBAR)
- m_rcStatusBkPadding.SetRect( 0, 2, 0, 1 );
- VERIFY( m_bmpStatusBkLight.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_BK_LIGHT_OBSIDIAN) ) );
- VERIFY( m_bmpStatusBkDark.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_BK_DARK_OBSIDIAN) ) );
- m_rcStatusSeparatorPadding.SetRect( 0, 2, 0, 1 );
- VERIFY( m_bmpStatusSeparator.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_STATUSBAR_SEPARATOR_OBSIDIAN) ) );
- // VERIFY( m_bmpStatusSeparator.Make32() );
- // m_bmpStatusSeparator.AdjustAlpha( -0.5 );
- //m_clrStatusPaneTextColorDisabled = RGB(128,128,128);
- m_clrStatusPaneTextColorNormal = RGB(255,255,255);
- #endif // (!defined __EXT_MFC_NO_STATUSBAR)
- #if (!defined __EXT_MFC_NO_TAB_CTRL)
- m_clrTabTextNormal = RGB(255,255,255);
- m_clrTabTextSelected = RGB(0,0,0);
- m_nIdxTabShapeHover = 1;
- m_nIdxTabShapePressed = 2;
- m_nIdxTabShapeSelected = 3;
- m_nIdxTabShapeSelectedHover = 4;
- m_arrSizeTabShape[__ETSOI_TOP].cx
- = m_arrSizeTabShape[__ETSOI_BOTTOM].cx
- = m_arrSizeTabShape[__ETSOI_LEFT].cy
- = m_arrSizeTabShape[__ETSOI_RIGHT].cy
- = 57;
- m_arrSizeTabShape[__ETSOI_TOP].cy
- = m_arrSizeTabShape[__ETSOI_BOTTOM].cy
- = m_arrSizeTabShape[__ETSOI_LEFT].cx
- = m_arrSizeTabShape[__ETSOI_RIGHT].cx
- = 24;
- m_arrRectTabShapePadding[__ETSOI_TOP].SetRect( 6, 3, 6, 3 );
- m_arrRectTabShapePadding[__ETSOI_BOTTOM].SetRect( 6, 3, 6, 3 );
- m_arrRectTabShapePadding[__ETSOI_LEFT].SetRect( 3, 6, 3, 6 );
- m_arrRectTabShapePadding[__ETSOI_RIGHT].SetRect( 3, 6, 3, 6 );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SHAPE_ARR_OBSIDIAN )
- )
- );
- VERIFY( m_arrBmpTabShapeNormal[__ETSOI_TOP].Make32() );
- m_arrBmpTabShapeNormal[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 180,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 270,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeNormal[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabShapeNormal[__ETSOI_TOP],
- 90,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SHAPE_ARR_OBSIDIAN_SEL_AREA )
- )
- );
- VERIFY( m_arrBmpTabShapeSelArea[__ETSOI_TOP].Make32() );
- m_arrBmpTabShapeSelArea[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 180,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 270,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabShapeSelArea[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabShapeSelArea[__ETSOI_TOP],
- 90,
- 5,
- m_arrSizeTabShape[__ETSOI_TOP].cx,
- m_arrSizeTabShape[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- m_arrRectTabAreaPadding[__ETSOI_TOP].SetRect( 4, 4, 4, 4 );
- m_arrRectTabAreaPadding[__ETSOI_BOTTOM].SetRect( 4, 4, 4, 4 );
- m_arrRectTabAreaPadding[__ETSOI_LEFT].SetRect( 4, 4, 4, 4 );
- m_arrRectTabAreaPadding[__ETSOI_RIGHT].SetRect( 4, 4, 4, 4 );
- m_arrTabAreaMargins[__ETSOI_TOP] = 1;
- m_arrTabAreaMargins[__ETSOI_BOTTOM] = 1;
- m_arrTabAreaMargins[__ETSOI_LEFT] = 1;
- m_arrTabAreaMargins[__ETSOI_RIGHT] = 1;
- VERIFY(
- m_arrBmpTabArea[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_AREA_BK_OBSIDIAN )
- )
- );
- VERIFY( m_arrBmpTabArea[__ETSOI_TOP].Make32() );
- CSize _sizeTabArea = m_arrBmpTabArea[__ETSOI_TOP].GetSize();
- m_arrBmpTabArea[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 180,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 270,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabArea[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabArea[__ETSOI_TOP],
- 90,
- 1,
- _sizeTabArea.cx,
- _sizeTabArea.cy,
- false,
- false
- )
- );
- m_arrSizeTabSeparator[__ETSOI_TOP].cx
- = m_arrSizeTabSeparator[__ETSOI_BOTTOM].cx
- = m_arrSizeTabSeparator[__ETSOI_LEFT].cy
- = m_arrSizeTabSeparator[__ETSOI_RIGHT].cy
- = 1;
- m_arrSizeTabSeparator[__ETSOI_TOP].cy
- = m_arrSizeTabSeparator[__ETSOI_BOTTOM].cy
- = m_arrSizeTabSeparator[__ETSOI_LEFT].cx
- = m_arrSizeTabSeparator[__ETSOI_RIGHT].cx
- = 24;
- m_arrRectTabSeparatorPadding[__ETSOI_TOP].SetRect( 0, 2, 0, 2 );
- m_arrRectTabSeparatorPadding[__ETSOI_BOTTOM].SetRect( 0, 2, 0, 2 );
- m_arrRectTabSeparatorPadding[__ETSOI_LEFT].SetRect( 2, 0, 2, 0 );
- m_arrRectTabSeparatorPadding[__ETSOI_RIGHT].SetRect( 2, 0, 2, 0 );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_TOP].LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_TAB_SEPARATOR_OBSIDIAN )
- )
- );
- VERIFY( m_arrBmpTabSeparator[__ETSOI_TOP].Make32() );
- m_arrBmpTabSeparator[__ETSOI_TOP].PreMultiplyRGBChannels();
- m_arrBmpTabSeparator[__ETSOI_TOP].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_BOTTOM].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 180,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_LEFT].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 270,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpTabSeparator[__ETSOI_RIGHT].CreateRotated9xStack(
- m_arrBmpTabSeparator[__ETSOI_TOP],
- 90,
- 1,
- m_arrSizeTabSeparator[__ETSOI_TOP].cx,
- m_arrSizeTabSeparator[__ETSOI_TOP].cy,
- false,
- false
- )
- );
- #endif // (!defined __EXT_MFC_NO_TAB_CTRL)
- VERIFY(
- m_bmpArrStatesCheckBox.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_CHECK_BOX_R2_OBSIDIAN )
- )
- );
- VERIFY(
- m_bmpArrStatesRadioButton.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_RADIO_BUTTON_R2 )
- )
- );
- m_clrMenuItemLeftAreaMarginL = RGB(197,197,197);
- m_clrMenuItemLeftAreaMarginR = RGB(245,245,245);
- VERIFY(
- m_bmpMenuItemLargeLeft.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_LARGE_LEFT )
- )
- );
- m_bmpMenuItemLargeLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemLargeRight.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_LARGE_RIGHT )
- )
- );
- m_bmpMenuItemLargeRight.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemSmallLeft.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_SMALL_LEFT )
- )
- );
- m_bmpMenuItemSmallLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuItemSmallRight.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_R2_SMALL_RIGHT )
- )
- );
- m_bmpMenuItemSmallRight.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpMenuArrow.LoadBMP_Resource(
- MAKEINTRESOURCE( IDB_EXT_2007_MENU_ITEM_ARROW )
- )
- );
- m_sizeMenuCheckAreaChecked.cx = 16;
- m_sizeMenuCheckAreaChecked.cy = 16;
- m_sizeMenuCheckAreaUnchecked.cx = 20;
- m_sizeMenuCheckAreaUnchecked.cy = 20;
- m_arrRectMenuCheckAreaCheckedPadding[0].SetRect( 1, 1, 1, 1 );
- m_arrRectMenuCheckAreaCheckedPadding[1].SetRect( 1, 1, 1, 1 );
- m_arrRectMenuCheckAreaUncheckedPadding[0].SetRect( 2, 2, 2, 2 );
- m_arrRectMenuCheckAreaUncheckedPadding[1].SetRect( 2, 2, 2, 2 );
- VERIFY( m_bmpMenuCheckAreaChecked.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_MENU_CHECK_AREA_CHECKED_R2 ) ) );
- VERIFY( m_bmpMenuCheckAreaUnchecked.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_MENU_CHECK_AREA_UNCHECKED_R2 ) ) );
- VERIFY( m_bmpArrComboBoxDropDown.LoadBMP_Resource( MAKEINTRESOURCE( IDB_EXT_2007_COMBO_BOX_BUTTON_R2_OBSIDIAN ) ) );
- m_arrClrComboBoxBorder[0] = RGB(137,137,137);
- m_arrClrComboBoxBorder[1] = RGB(137,137,137);
- m_arrClrComboBoxBorder[2] = RGB(137,137,137);
- m_arrClrComboBoxBorder[3] = RGB(137,137,137);
- CRect SbSkinDataPaddingH( 5, 3, 5, 3 ), SbSkinDataPaddingV( 3, 5, 3, 5 );
- CRect rcEntirePaddingRH( 0, 2, 0, 2 ), rcEntirePaddingRV( 2, 0, 2, 0 );
- CRect rcEntirePaddingCH( 1, 1, 1, 1 ), rcEntirePaddingCV( 1, 1, 1, 1 );
- m_SbSkinDataT_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_TOP
- );
- m_SbSkinDataB_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_BOTTOM
- );
- m_SbSkinDataL_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_LEFT
- );
- m_SbSkinDataR_Zoom.Load2007_Zoom(
- IDB_EXT_2007_ZS_PLUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_MINUS_R2_OBSIDIAN, IDB_EXT_2007_ZS_THUMB_R2_OBSIDIAN,
- RGB(204,204,204), RGB(37,37,37), RGB(148,149,151), RGB(68,69,71), AFX_IDW_DOCKBAR_RIGHT
- );
- m_SbSkinDataH_Light.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_HORZ_OBSIDIAN,
- 15,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_HORZ,
- 8,
- SbSkinDataPaddingH,
- COLORREF(-1L), // RGB(64,64,64),
- COLORREF(-1L), // RGB(91,98,115),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- true,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_LIGHT,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_LIGHT,
- rcEntirePaddingRH,
- rcEntirePaddingCH
- );
- m_SbSkinDataV_Light.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_VERT_OBSIDIAN,
- 21,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_VERT,
- 8,
- SbSkinDataPaddingV,
- COLORREF(-1L), // RGB(64,64,64),
- COLORREF(-1L), // RGB(91,98,115),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- false,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_LIGHT,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_LIGHT,
- rcEntirePaddingRV,
- rcEntirePaddingCV
- );
- m_SbSkinDataH_Dark.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_HORZ_OBSIDIAN,
- 15,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_HORZ,
- 8,
- SbSkinDataPaddingH,
- COLORREF(-1L), // RGB(64,64,64),
- COLORREF(-1L), // RGB(91,98,115),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- true,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_DARK,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_DARK,
- rcEntirePaddingRH,
- rcEntirePaddingCH
- );
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_HOT)][INT(__ESBMHT_GLYPH_ARROW_UP)] =
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)];
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_NORMAL)][INT(__ESBMHT_GLYPH_ARROW_UP)] =
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)];
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)].
- AdjustHLS( COLORREF(-1L), RGB(0,0,0), 0.0, 0.75, -1.0 );
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_HOT)][INT(__ESBMHT_GLYPH_ARROW_DOWN)] =
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)];
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_NORMAL)][INT(__ESBMHT_GLYPH_ARROW_DOWN)] =
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)];
- m_SbSkinDataH_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)].
- AdjustHLS( COLORREF(-1L), RGB(0,0,0), 0.0, 0.75, -1.0 );
- m_SbSkinDataV_Dark.Load2007_R2(
- IDB_EXT_2007_SCROLL_BAR_STACK_BUTTONS_R2_VERT_OBSIDIAN,
- 21,
- IDB_EXT_2007_SCROLL_BAR_STACK_GRIPPER_R2_VERT,
- 8,
- SbSkinDataPaddingV,
- COLORREF(-1L), // RGB(64,64,64),
- COLORREF(-1L), // RGB(91,98,115),
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_UP_DISABLED_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_NORMAL_R2,
- IDB_EXT_2007_SCROLL_BAR_ARROW_DOWN_DISABLED_R2,
- false,
- IDB_EXT_2007_SCROLL_BAR_ENTIRE_BK_R2_OBSIDIAN_DARK,
- IDB_EXT_2007_SCROLL_BAR_PAGE_BK_R2_OBSIDIAN_DARK,
- rcEntirePaddingRV,
- rcEntirePaddingCV
- );
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_HOT)][INT(__ESBMHT_GLYPH_ARROW_UP)] =
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)];
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_NORMAL)][INT(__ESBMHT_GLYPH_ARROW_UP)] =
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)];
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_UP)].
- AdjustHLS( COLORREF(-1L), RGB(0,0,0), 0.0, 0.75, -1.0 );
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_HOT)][INT(__ESBMHT_GLYPH_ARROW_DOWN)] =
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)];
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_NORMAL)][INT(__ESBMHT_GLYPH_ARROW_DOWN)] =
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)];
- m_SbSkinDataV_Dark.m_arrPartBmp[INT(__ESBSPT_COLD)][INT(__ESBMHT_GLYPH_ARROW_DOWN)].
- AdjustHLS( COLORREF(-1L), RGB(0,0,0), 0.0, 0.75, -1.0 );
- m_clrGridHeaderBkTop = RGB(253,253,253);
- m_clrGridHeaderBkBottom = RGB(212,215,220);
- m_clrGridHeaderSeparator = RGB(145,153,164);
- m_clrGridHeaderSortArrow = RGB(145,153,164);
- m_clrGridHeaderBorder = RGB(145,153,164);
- m_clrRgHeaderBkTop = RGB(253,253,253);
- m_clrRgHeaderBkBottom = RGB(212,215,220);
- m_clrRgHeaderSeparator = RGB(145,153,164);
- m_clrRgHeaderSortArrow = RGB(145,153,164);
- m_clrRgHeaderText = RGB(0,0,0);
- m_clrRgHeaderBorder = RGB(76,83,92);
- #if (!defined __EXT_MFC_NO_REPORTGRIDWND)
- m_clrRgGroupAreaBk = RGB(235,235,235);
- m_clrRgGroupAreaText = RGB(70,70,70);
- #endif // (!defined __EXT_MFC_NO_REPORTGRIDWND)
- // m_nTbbLightWeightSimpleGlyphHeightV = 20;
- // m_nTbbLightWeightSDDLeftGlyphHeightV = 23;
- // m_nTbbLightWeightSDDRightGlyphHeightV = 10;
- // VERIFY(
- // m_arrBmpTbbLightWeightSimpleH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_SIMPLE )
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDLeftH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_LEFT_PART )
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDRightH.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_TBB_LIGHTWEIGHT_R2_RIGHT_PART )
- // )
- // );
- // // m_arrBmpTbbLightWeightSimpleH.PreMultipliedRGBChannelsSet( true );
- // // m_arrBmpTbbLightWeightSDDLeftH.PreMultipliedRGBChannelsSet( true );
- // // m_arrBmpTbbLightWeightSDDRightH.PreMultipliedRGBChannelsSet( true );
- // VERIFY(
- // m_arrBmpTbbLightWeightSimpleV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSimpleH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSimpleH.GetSize().cx,
- // m_nTbbLightWeightSimpleGlyphHeightH,
- // false,
- // false
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDLeftV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSDDLeftH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSDDLeftH.GetSize().cx,
- // m_nTbbLightWeightSDDLeftGlyphHeightH,
- // false,
- // false
- // )
- // );
- // VERIFY(
- // m_arrBmpTbbLightWeightSDDRightV.CreateRotated9xStack(
- // m_arrBmpTbbLightWeightSDDRightH,
- // 90,
- // INT(__EPBGT_GLYPH_COUNT),
- // m_arrBmpTbbLightWeightSDDRightH.GetSize().cx,
- // m_nTbbLightWeightSDDRightGlyphHeightH,
- // false,
- // false
- // )
- // );
- m_nPushBtnSimpleGlyphHeightV = 20;
- m_nPushBtnSDDLeftGlyphHeightV = 23;
- m_nPushBtnSDDRightGlyphHeightV = 10;
- VERIFY(
- m_arrBmpPushBtnSimpleH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_SIMPLE )
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDLeftH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_LEFT_PART )
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDRightH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_BUTTON_R2_OBSIDIAN_RIGHT_PART )
- )
- );
- // m_arrBmpPushBtnSimpleH.PreMultipliedRGBChannelsSet( true );
- // m_arrBmpPushBtnSDDLeftH.PreMultipliedRGBChannelsSet( true );
- // m_arrBmpPushBtnSDDRightH.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_arrBmpPushBtnSimpleV.CreateRotated9xStack(
- m_arrBmpPushBtnSimpleH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSimpleH.GetSize().cx,
- m_nPushBtnSimpleGlyphHeightH,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDLeftV.CreateRotated9xStack(
- m_arrBmpPushBtnSDDLeftH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSDDLeftH.GetSize().cx,
- m_nPushBtnSDDLeftGlyphHeightH,
- false,
- false
- )
- );
- VERIFY(
- m_arrBmpPushBtnSDDRightV.CreateRotated9xStack(
- m_arrBmpPushBtnSDDRightH,
- 90,
- INT(__EPBGT_GLYPH_COUNT),
- m_arrBmpPushBtnSDDRightH.GetSize().cx,
- m_nPushBtnSDDRightGlyphHeightH,
- false,
- false
- )
- );
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- m_nQatbAdditionalSpaceAtRightDWM = 30;
- m_clrContractedMargin1 = RGB(98,98,98);
- m_clrContractedMargin2 = RGB(79,79,79);
- m_nContractedMarginHeight = 2;
- m_bRibbonGroupCaptionAtTop = false;
- m_bRibbonGroupCaptionAreaHasPadding = true;
- m_nRibbonGroupCaptionAreaHeightExpanded = 16;
- m_nRibbonGroupCaptionAreaHeightCollapsed = 16;
- m_nRibbonCaptionPartHeight = 17;
- m_nRibbonGroupIconBkVertOffset = 2;
- m_clrRibbonComboBackGroundNormal = RGB(232,232,232);
- m_nRibbonTabIntersectionHeight = 1;
- m_clrRibbonButtonDisabled = RGB(128,128,128);
- m_clrRibbonGroupCaptionTextExpanded = RGB( 250, 250, 250 );
- m_nRibbonGroupCaptionTextDF
- = m_nRibbonGroupCaptionTextShadowDF
- = DT_SINGLELINE|DT_CENTER|DT_VCENTER|DT_END_ELLIPSIS;
- m_rcRibbonPageBkPadding.SetRect( 5, 19, 5, 10 );
- VERIFY(
- m_bmpRibbonPageBk.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_PAGE_BK_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonPageBk.PreMultipliedRGBChannelsSet( true );
-
- m_rcRibbonGroupPaddingBkExpanded.SetRect( 4, 4, 4, 4 );
- VERIFY(
- m_bmpRibbonGroupBkExpanded[0].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_EXPANDED_NORMAL_BK_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkExpanded[1].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_EXPANDED_HOVER_BK_R2_OBSIDIAN)
- )
- );
-
- m_rcRibbonGroupPaddingBkCollapsed.SetRect( 4, 18, 4, 4 );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[0].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_NORMAL_BK_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[1].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_HOVER_BK_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[2].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_PRESSED_BK_R2_OBSIDIAN)
- )
- );
- VERIFY(
- m_bmpRibbonGroupBkCollapsed[3].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_GROUP_COLLAPSED_SELECTED_BK_R2)
- )
- );
-
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[0].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_NORMAL_BK_R2_OBSIDIAN)
- // )
- // );
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[1].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_HOVER_BK_R2_OBSIDIAN)
- // )
- // );
- // VERIFY(
- // m_bmpRibbonIconBkCollapsed[2].LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_ICON_COLLAPSED_PRESSED_BK_R2_OBSIDIAN)
- // )
- // );
- INT nBkIndex, nBkCount;
- nBkCount = sizeof( m_bmpRibbonGroupBkExpanded ) / sizeof( m_bmpRibbonGroupBkExpanded[0] );
- for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- {
- m_bmpRibbonGroupBkExpanded[nBkIndex].Make32();
- m_bmpRibbonGroupBkExpanded[nBkIndex].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- } // for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- nBkCount = sizeof( m_bmpRibbonGroupBkCollapsed ) / sizeof( m_bmpRibbonGroupBkCollapsed[0] );
- for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- {
- m_bmpRibbonGroupBkCollapsed[nBkIndex].Make32();
- m_bmpRibbonGroupBkCollapsed[nBkIndex].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- } // for( nBkIndex = 0; nBkIndex < nBkCount; nBkIndex ++ )
- VERIFY(
- m_bmpRibbonIconBkCF.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_COLLAPSED_ICON_FRAME_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonIconBkCF.PreMultiplyRGBChannels( false );
- // m_bmpRibbonIconBkCF.PreMultipliedRGBChannelsSet( true );
- m_nRibbonSeparatorDrawModeH = INT( CExtBitmap::__EDM_STRETCH );
- m_nRibbonSeparatorDrawModeV = INT( CExtBitmap::__EDM_STRETCH );
- m_rcRibbonSeparatorPaddingH.SetRect( 6, 0, 6, 0 );
- VERIFY(
- m_bmpRibbonSeparatorH.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_SEPARATOR_H_R2_OBSIDIAN)
- )
- );
- VERIFY( m_bmpRibbonSeparatorH.Make32() );
- m_bmpRibbonSeparatorH.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_rcRibbonSeparatorPaddingV.SetRect( 0, 6, 0, 6 );
- VERIFY(
- m_bmpRibbonSeparatorV.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_SEPARATOR_V_R2_OBSIDIAN)
- )
- );
- VERIFY( m_bmpRibbonSeparatorV.Make32() );
- m_bmpRibbonSeparatorV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_nRibbonHeightOfQACEB = 22;
- m_nIdxRibbonQACEB_Selected = 3;
- VERIFY(
- m_bmpArrRibbonQACEB.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_QATB_CEB_R2_OBSIDIAN)
- )
- );
- m_bmpArrRibbonQACEB.PreMultiplyRGBChannels();
- m_bmpArrRibbonQACEB.PreMultipliedRGBChannelsSet( true );
- m_clrRibbon_EmbeddedCaptionTextLeft = RGB(255,255,255);
- m_clrRibbon_EmbeddedCaptionTextRight = RGB(180,216,255);
- m_bRibbonFileButtonItegrationSupported = true;
- INT nCaptionHeightActive = NcFrame_GetCaptionHeight( true, NULL ) + m_rcNcFrameBordersActive.top;
- INT nCaptionHeightInactive = NcFrame_GetCaptionHeight( false, NULL ) + m_rcNcFrameBordersInactive.top;
- CExtBitmap::Filter _fBox( CExtBitmap::Filter::box );
- m_rcRibbonNcCornerLeftCP.SetRect( 22, 8, 2, 2 );
- m_rcRibbonNcCornerRightCP.SetRect( 2, 8, 22, 2 );
- VERIFY(
- m_bmpRibbonNcCornerActiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerActiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveLeft.Make32();
- // m_bmpRibbonNcCornerActiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- m_bmpRibbonNcCornerActiveLeft.Scale(
- m_bmpRibbonNcCornerActiveLeft.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerInactiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_LEFT_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerInactiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveLeft.Make32();
- // m_bmpRibbonNcCornerInactiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- m_bmpRibbonNcCornerInactiveLeft.Scale(
- m_bmpRibbonNcCornerInactiveLeft.GetSize().cx,
- nCaptionHeightInactive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerActiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerActiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveRight.Make32();
- // m_bmpRibbonNcCornerActiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- m_bmpRibbonNcCornerActiveRight.Scale(
- m_bmpRibbonNcCornerActiveRight.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerInactiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_RIGHT_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerInactiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveRight.Make32();
- // m_bmpRibbonNcCornerInactiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), BYTE(0) );
- m_bmpRibbonNcCornerInactiveRight.Scale(
- m_bmpRibbonNcCornerInactiveRight.GetSize().cx,
- nCaptionHeightInactive,
- _fBox
- );
- VERIFY(
- m_bmpRibbonNcCornerHT.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_HT_MASK_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonNcCornerHT.Make32();
- m_bmpRibbonNcCornerHT.Scale(
- m_bmpRibbonNcCornerHT.GetSize().cx,
- nCaptionHeightActive,
- _fBox
- );
- VERIFY( m_bmpArrRibbonFileButton.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_FILE_BUTTON_R2_OBSIDIAN) ) );
- //m_bmpArrRibbonFileButton.PreMultipliedRGBChannelsSet( true );
- m_rcPaddingRibbonQuickAccessBarBkAtTheBottom.SetRect( 3, 3, 3, 3 );
- VERIFY( m_bmpRibbonQuickAccessBarBkAtTheBottom.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_QATB_BK_R2_OBSIDIAN) ) );
- m_nRibbonHeightOfOneDLB = 14;
- m_nDlbIdxDisabled = 3;
- m_nDlbIdxNormal = 0;
- m_nDlbIdxHover = 1;
- m_nDlbIdxPressed = 2;
- rcRibbonContentPaddingDLB.SetRect( 2, 2, 2, 2 );
- VERIFY( m_arrBmpRibbonDLB.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_GCB_R2_OBSIDIAN) ) );
- m_arrBmpRibbonDLB.PreMultiplyRGBChannels();
- m_arrBmpRibbonDLB.PreMultipliedRGBChannelsSet( true );
- m_clrRibbonGalleryInplaceBorderNormal = RGB(172,172,172);
- m_clrRibbonGalleryInplaceBorderHover = RGB(172,172,172);
- m_clrRibbonGalleryInplaceBkgndNormal = RGB(218,226,226);
- m_clrRibbonGalleryInplaceBkgndHover = RGB(247,247,247);
- m_rcRibbonGalleryScrollFill = RGB(218,226,226);
- m_rcRibbonGalleryScrollButtonPadding.SetRect( 4, 4, 4, 4 );
- m_nHeightRibbonGalleryScrollButton = -1;
- m_nIndexRibbonGalleryScrollButtonDisabled = 4;
- m_nIndexRibbonGalleryScrollButtonNormal = 1;
- m_nIndexRibbonGalleryScrollButtonHover = 2;
- m_nIndexRibbonGalleryScrollButtonPressed = 3;
- VERIFY( m_bmpArrRibbonGalleryScrollButtonDown.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_DOWN_R2_OBSIDIAN) ) );
- VERIFY( m_bmpArrRibbonGalleryScrollButtonUp.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_UP_R2_OBSIDIAN) ) );
- VERIFY( m_bmpArrRibbonGalleryScrollButtonMenu.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RGIBTN_MENU_R2_OBSIDIAN) ) );
- #endif // (!defined __EXT_MFC_NO_RIBBON_BAR)
- VERIFY( m_bmpRibbonDDA.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_DDA_R2_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonDDA.Make32() );
- m_bmpRibbonDDA.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpArrRibbonComboBoxDropDown.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_COMBO_BOX_BUTTON_R2_OBSIDIAN) ) );
- // tool buttons 2007
- m_arrIndicesButtonTS[INT(__E07BI_NORMAL)] = 0;
- m_arrIndicesButtonTS[INT(__E07BI_HOVER)] = 3;
- m_arrIndicesButtonTS[INT(__E07BI_PRESSED)] = 2;
- m_arrIndicesButtonTS[INT(__E07BI_HDD)] = 3;
- m_arrIndicesButtonTS[INT(__E07BI_SEL_T)] = 1;
- m_arrIndicesButtonTS[INT(__E07BI_INDETERMINATE)] = 0;
- m_arrIndicesButtonSS_Left[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonSS_Left[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonSS_Left[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonSS_Left[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonSS_Left[INT(__E07BI_SEL_T)] = 5;
- m_arrIndicesButtonSS_Left[INT(__E07BI_INDETERMINATE)] = 4;
- m_arrIndicesButtonSS_Right[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonSS_Right[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonSS_Right[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonSS_Right[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonSS_Right[INT(__E07BI_SEL_T)] = 4;
- m_arrIndicesButtonSS_Right[INT(__E07BI_INDETERMINATE)] = 3;
- m_arrIndicesButtonLSM[INT(__E07BI_NORMAL)] = -1;
- m_arrIndicesButtonLSM[INT(__E07BI_HOVER)] = 0;
- m_arrIndicesButtonLSM[INT(__E07BI_PRESSED)] = 1;
- m_arrIndicesButtonLSM[INT(__E07BI_HDD)] = 2;
- m_arrIndicesButtonLSM[INT(__E07BI_SEL_T)] = 0;
- m_arrIndicesButtonLSM[INT(__E07BIX_INDETERMINATE)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_NORMAL)] = -1;
- // m_arrIndicesButtonLSB[INT(__E07BI_HOVER)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_PRESSED)] = 1;
- // m_arrIndicesButtonLSB[INT(__E07BI_HDD)] = 2;
- // m_arrIndicesButtonLSB[INT(__E07BI_SEL_T)] = 0;
- // m_arrIndicesButtonLSB[INT(__E07BI_INDETERMINATE)] = 0;
- m_arrIndicesButtonLSXM[INT(__E07BIX_NORMAL)] = -1;
- m_arrIndicesButtonLSXM[INT(__E07BIX_HOVER)] = 0;
- m_arrIndicesButtonLSXM[INT(__E07BIX_HOVER2)] = 5;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED)] = 1;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED2)] = 2;
- m_arrIndicesButtonLSXM[INT(__E07BIX_PRESSED3)] = 3;
- m_arrIndicesButtonLSXM[INT(__E07BIX_INDETERMINATE)] = 4;
- m_arrIndicesButtonLSXM[INT(__E07BIX_SELECTED)] = 5;
- m_arrIndicesButtonLSXB[INT(__E07BIX_NORMAL)] = -1;
- m_arrIndicesButtonLSXB[INT(__E07BIX_HOVER)] = 0;
- m_arrIndicesButtonLSXB[INT(__E07BIX_HOVER2)] = 4;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED)] = 1;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED2)] = 2;
- m_arrIndicesButtonLSXB[INT(__E07BIX_PRESSED3)] = 2;
- m_arrIndicesButtonLSXB[INT(__E07BIX_INDETERMINATE)] = 3;
- m_arrIndicesButtonLSXB[INT(__E07BIX_SELECTED)] = 4;
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_SOLID)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SOLID_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_SOLID)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_LEFT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_LEFT_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_LEFT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_MIDDLE)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_MIDDLE_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_MIDDLE)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonTS[INT(__EBTSA_RIGHT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_RIGHT_R2_OBSIDIAN)
- )
- );
- m_bmpArrButtonTS[INT(__EBTSA_RIGHT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonSS_DD[INT(__EBSSA_LEFT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_SMALL_LEFT_R2)
- )
- );
- m_bmpArrButtonSS_DD[INT(__EBSSA_LEFT)].PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonSS_DD[INT(__EBSSA_RIGHT)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_SMALL_RIGHT_R2)
- )
- );
- m_bmpArrButtonSS_DD[INT(__EBSSA_RIGHT)].PreMultipliedRGBChannelsSet( true );
- m_bmpArrButtonSS_simple = m_bmpArrButtonSS_DD[ INT(__EBSSA_LEFT) ];
- if( ! m_bmpArrButtonSS_simple.IsEmpty() )
- {
- CSize _sizeBmp = m_bmpArrButtonSS_simple.GetSize();
- INT nY = 0, nXRange = _sizeBmp.cx / 2;
- for( ; nY < _sizeBmp.cy; nY ++ )
- {
- INT nXSrc = nXRange - 1, nXDst = _sizeBmp.cx - nXRange;
- for( ; nXDst < _sizeBmp.cx; nXDst ++, nXSrc -- )
- {
- RGBQUAD _pixel;
- VERIFY( m_bmpArrButtonSS_simple.GetPixel( nXSrc, nY, _pixel ) );
- VERIFY( m_bmpArrButtonSS_simple.SetPixel( nXDst, nY, _pixel ) );
- } // for( ; nXDst < _sizeBmp.cx; nXDst ++, nXSrc -- )
- } // for( ; nY < _sizeBmp.cy; nY ++ )
- } // if( m_bmpArrButtonSS_simple.IsEmpty() )
- VERIFY(
- m_bmpArrButtonLSM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_ALL_R2) // IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2
- )
- );
- // m_bmpArrButtonLSM.PreMultipliedRGBChannelsSet( true );
- // VERIFY(
- // m_bmpArrButtonLSB.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- // )
- // );
- // m_bmpArrButtonLSB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXM.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_TOP_R2)
- )
- );
- m_bmpArrButtonLSXM.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpArrButtonLSXB.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_BOTTOM_R2)
- )
- );
- m_bmpArrButtonLSXB.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_TB_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].Make32();
- m_bmpToolBtnSeparator[INT(__ETBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_HOVER_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_HOVER)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_BTN_PART_LARGE_SEPARATOR_PRESSED_R2)
- )
- );
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].Make32();
- m_bmpLargeBtnSeparator[INT(__ELBS_PRESSED)].AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingMarginHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_HV_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonMenuResizingMarginV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRB_V_OBSIDIAN) ) );
- VERIFY( m_bmpRibbonMenuResizingGripperHV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_HV_OBSIDIAN) ) );
- m_bmpRibbonMenuResizingGripperHV.Make32();
- m_bmpRibbonMenuResizingGripperHV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpRibbonMenuResizingGripperV.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_MRG_V_OBSIDIAN) ) );
- m_bmpRibbonMenuResizingGripperV.Make32();
- m_bmpRibbonMenuResizingGripperV.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrRibbonModeMenuTextNormal = RGB(0,0,0);
- VERIFY(
- m_bmpRibbonModeMenuBorder.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_BORDER_R2)
- )
- );
- m_bmpRibbonModeMenuBorder.Make32();
- m_bmpRibbonModeMenuBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_clrMenuCaptionText = RGB(20,20,90);
- m_rcMenuCaptionBmpPadding.SetRect( 0, 2, 0, 2 );
- VERIFY(
- m_bmpMenuCaptionBk.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_MENU_CAPTION_BK_R2_OBSIDIAN)
- )
- );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 12, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R2_OBSIDIAN) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
-
- m_rcPaddingRibbonFileMenuOptionsButton.SetRect( 2, 2, 2, 2 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonCold.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_COLD_R2_OBSIDIAN)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonCold.Make32();
- m_bmpRibbonFileMenuOptionsButtonCold.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonFileMenuOptionsButtonHot.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RM_OPTION_HOT_R2)
- )
- );
- m_bmpRibbonFileMenuOptionsButtonHot.Make32();
- m_bmpRibbonFileMenuOptionsButtonHot.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY( m_bmpResizingGripper.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RESIZING_GRIPPER_R2_OBSIDIAN) ) );
- m_bmpResizingGripper.PreMultipliedRGBChannelsSet( true );
- // spin bitmaps
- VERIFY( m_arrBmpSpinArrowDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_DOWN_OBSIDIAN) ) );
- VERIFY( m_arrBmpSpinArrowUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_ARROW_UP_OBSIDIAN) ) );
- VERIFY( m_arrBmpSpinDown. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_DOWN_OBSIDIAN) ) );
- VERIFY( m_arrBmpSpinUp. LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_SPIN_UP_OBSIDIAN) ) );
- #if (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- m_clrShortcutListItemAlternativeText = RGB(255,255,255);
- m_bShortcutListUseDockerBkgnd = true;
- #endif // (!defined __EXT_MFC_NO_SHORTCUTLIST_CTRL)
- }
- CExtPaintManagerOffice2007_R3_Obsidian::CExtPaintManagerOffice2007_R3_Obsidian()
- {
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- m_nQatbAdditionalSpaceAtRightDWM = 0;
- // INT nCaptionHeightActive = NcFrame_GetCaptionHeight( true, NULL ) + m_rcNcFrameBordersActive.top;
- // INT nCaptionHeightInactive = NcFrame_GetCaptionHeight( false, NULL ) + m_rcNcFrameBordersInactive.top;
- // CExtBitmap::Filter _fBox( CExtBitmap::Filter::box );
- m_rcRibbonNcCornerLeftCP.SetRect( 53, 2, 2, 2 );
- m_rcRibbonNcCornerRightCP.SetRect( 2, 2, 42, 2 );
- VERIFY(
- m_bmpRibbonNcCornerDwmLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_LEFT_R3_OBSIDIAN)
- )
- );
- //m_bmpRibbonNcCornerDwmLeft.PreMultipliedRGBChannelsSet( true );
- VERIFY(
- m_bmpRibbonNcCornerDwmRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_DWM_RIGHT_R3_OBSIDIAN)
- )
- );
- //m_bmpRibbonNcCornerDwmRight.PreMultipliedRGBChannelsSet( true );
- m_bmpRibbonNcCornerDwmLeft.AdjustAlpha( -0.60 );
- m_bmpRibbonNcCornerDwmRight.AdjustAlpha( -0.60 );
- VERIFY(
- m_bmpRibbonNcCornerActiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R3_OBSIDIAN)
- )
- );
- // m_bmpRibbonNcCornerActiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveLeft.Scale(
- // m_bmpRibbonNcCornerActiveLeft.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveLeft.Make32() );
- m_bmpRibbonNcCornerActiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveLeft.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_LEFT_R3_OBSIDIAN)
- )
- );
- // m_bmpRibbonNcCornerInactiveLeft.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveLeft.Scale(
- // m_bmpRibbonNcCornerInactiveLeft.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveLeft.Make32() );
- m_bmpRibbonNcCornerInactiveLeft.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerActiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R3_OBSIDIAN)
- )
- );
- // m_bmpRibbonNcCornerActiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerActiveRight.Scale(
- // m_bmpRibbonNcCornerActiveRight.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerActiveRight.Make32() );
- m_bmpRibbonNcCornerActiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- VERIFY(
- m_bmpRibbonNcCornerInactiveRight.LoadBMP_Resource(
- MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_INACTIVE_RIGHT_R3_OBSIDIAN)
- )
- );
- // m_bmpRibbonNcCornerInactiveRight.PreMultipliedRGBChannelsSet( true );
- // m_bmpRibbonNcCornerInactiveRight.Scale(
- // m_bmpRibbonNcCornerInactiveRight.GetSize().cx,
- // nCaptionHeightInactive,
- // _fBox
- // );
- VERIFY( m_bmpRibbonNcCornerInactiveRight.Make32() );
- m_bmpRibbonNcCornerInactiveRight.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- // VERIFY(
- // m_bmpRibbonNcCornerHT.LoadBMP_Resource(
- // MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_NC_CORNER_HT_MASK_R2_OBSIDIAN)
- // )
- // );
- // m_bmpRibbonNcCornerHT.Make32();
- // m_bmpRibbonNcCornerHT.Scale(
- // m_bmpRibbonNcCornerHT.GetSize().cx,
- // nCaptionHeightActive,
- // _fBox
- // );
- m_bmpRibbonNcCornerHT.Empty();
- VERIFY( m_bmpArrRibbonFileButton.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RIBBON_FILE_BUTTON_R3_OBSIDIAN) ) );
- //m_bmpArrRibbonFileButton.PreMultipliedRGBChannelsSet( true );
- m_rcPaddingRibbonFileMenuBigBorder.SetRect( 6, 18, 6, 29 );
- VERIFY( m_bmpRibbonFileMenuBigBorder.LoadBMP_Resource( MAKEINTRESOURCE(IDB_EXT_2007_RM_BIG_BORDER_R3_OBSIDIAN) ) );
- m_bmpRibbonFileMenuBigBorder.Make32();
- m_bmpRibbonFileMenuBigBorder.AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
- m_sizeAboveTheRibbonShiftQACEB.cx = 10;
- m_sizeAboveTheRibbonShiftQACEB.cy = 0;
- m_nRibbonFileButtonMenuIntersectionHeight = 20;
- #endif // (!defined __EXT_MFC_NO_RIBBON_BAR)
- }
- CExtPaintManagerOffice2007_R2_Obsidian::~CExtPaintManagerOffice2007_R2_Obsidian()
- {
- }
- CExtPaintManagerOffice2007_R3_Obsidian::~CExtPaintManagerOffice2007_R3_Obsidian()
- {
- }
- void CExtPaintManagerOffice2007_Impl::InitTranslatedColors()
- {
- CExtPaintManagerOffice2003::InitTranslatedColors();
- m_mapColorTranslate[_2003CLR_EXPBTN_HOVER_LIGHT] = InstallColor( RGB(255,251,214) );
- m_mapColorTranslate[_2003CLR_EXPBTN_HOVER_DARK] = InstallColor( RGB(255,195,115) );
- m_mapColorTranslate[_2003CLR_EXPBTN_PRESSED_LIGHT] = InstallColor( RGB(255,219,148) );
- m_mapColorTranslate[_2003CLR_EXPBTN_PRESSED_DARK] = InstallColor( RGB(255,150,82) );
- }
- void CExtPaintManagerOffice2007_R1::InitTranslatedColors()
- {
- CExtPaintManagerOffice2007_Impl::InitTranslatedColors();
- #if (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_LIGHT] = InstallColor( RGB(240,241,242) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_DARK] = InstallColor( RGB(221,224,227) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_DARK] = InstallColor( RGB(232,234,236) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_BOTTOM_LINE] = InstallColor( RGB(199,203,209) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_LIGHT] = InstallColor( RGB(223,226,229) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_DARK] = InstallColor( RGB(225,227,230) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_LIGHT] = InstallColor( RGB(240,241,242) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_DARK] = InstallColor( RGB(189,194,201) );
- m_mapColorTranslate[_2003CLR_PN_BORDER] = InstallColor( RGB(119,130,153) );
- m_mapColorTranslate[CLR_PN_CAPTION_TEXT] = InstallColor( RGB(51,51,51) );
- #endif // (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[CLR_GROUP_BOX_FRAME] = InstallColor( RGB(140,140,140) );
- m_mapColorTranslate[CLR_WRB_FRAME] = InstallColor( RGB(140,140,140) );
- m_mapColorTranslate[_2003CLR_EXPBTN_LIGHT] = InstallColor( RGB(178, 183, 191) );
- m_mapColorTranslate[_2003CLR_EXPBTN_DARK] = InstallColor( RGB(76, 83, 92) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_LIGHT] = InstallColor( RGB(242, 242, 242) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_MIDDLE] = InstallColor( RGB(224, 224, 224) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_DARK] = InstallColor( RGB(186, 186, 186) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_BOTTOM_LINE] = InstallColor( RGB(83, 96, 125) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_DARK] = InstallColor( RGB(130,135,146) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_DARK] = InstallColor( RGB(130,135,146) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_LEFT] = InstallColor( RGB(239,239,239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_MIDDLE] = InstallColor( RGB(239,239,239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_RIGHT] = InstallColor( RGB(239,239,239) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_LEFT] = InstallColor( RGB(242,242,242) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_MIDDLE] = InstallColor( RGB(224, 224, 224) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_RIGHT] = InstallColor( RGB(186, 186, 186) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_TOP] = InstallColor( RGB(239,239,239) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_BOTTOM] = InstallColor( RGB(239,239,239) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_LEFT] = InstallColor( RGB(255,247,206) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_RIGHT] = InstallColor( RGB(255,219,115) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_LEFT] = InstallColor( RGB(255,150,57) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_RIGHT] = InstallColor( RGB(255,186,90) );
- m_mapColorTranslate[_2003CLR_BTN_HP_LEFT] = InstallColor( RGB(255,150,57) );
- m_mapColorTranslate[_2003CLR_BTN_HP_RIGHT] = InstallColor( RGB(255,186,90) );
- m_mapColorTranslate[XPCLR_MENU_BORDER] = InstallColor( RGB(83,96,125) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER] = InstallColor( RGB(83,96,125) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER_SELECTED] = m_mapColorTranslate[XPCLR_HILIGHT_BORDER];
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_LIGHT] = InstallColor( RGB(242,242,242) );
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_DARK] = InstallColor( RGB(186, 186, 186) );
- m_mapColorTranslate[CLR_TEXT_DISABLED] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[COLOR_3DSHADOW] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_NORMAL] = InstallColor( m_arrClrComboBoxBorder[0] );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_DISABLED] = InstallColor( m_arrClrComboBoxBorder[3] );
- m_mapColorTranslate[_2003CLR_GRADIENT_LIGHT] =
- m_mapColorTranslate[_2003CLR_GRADIENT_DARK] = InstallColor( m_clrFillHint );
- }
- void CExtPaintManagerOffice2007_R2_LunaBlue::InitTranslatedColors()
- {
- CExtPaintManagerOffice2007_Impl::InitTranslatedColors();
- #if (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_LIGHT] = InstallColor( RGB(226, 239, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_DARK] = InstallColor( RGB(214, 232, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_LIGHT] = InstallColor( RGB(255, 255, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_DARK] = InstallColor( RGB(227, 239, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_BOTTOM_LINE] = InstallColor( RGB(173, 209, 255) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_LIGHT] = InstallColor( RGB(216, 233, 255) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_DARK] = InstallColor( RGB(216, 233, 255) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_LIGHT] = InstallColor( RGB(227, 239, 255) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_DARK] = InstallColor( RGB(175, 210, 255) );
- m_mapColorTranslate[_2003CLR_PN_BORDER] = InstallColor( RGB(101, 147, 207) );
- m_mapColorTranslate[CLR_PN_CAPTION_TEXT] = InstallColor( RGB(21, 66, 139) );
- #endif // (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[CLR_GROUP_BOX_FRAME] = InstallColor( RGB(101,147,207) );
- m_mapColorTranslate[CLR_WRB_FRAME] = InstallColor( RGB(101,147,207) );
- m_mapColorTranslate[_2003CLR_EXPBTN_LIGHT] = InstallColor( RGB(215, 232, 255) );
- m_mapColorTranslate[_2003CLR_EXPBTN_DARK] = InstallColor( RGB(111, 157, 217) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_LIGHT] = InstallColor( RGB(227, 239, 255) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_MIDDLE] = InstallColor( RGB(227, 239, 255) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_DARK] = InstallColor( RGB(167, 205, 255) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_BOTTOM_LINE] = InstallColor( RGB(111, 157, 217) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_DARK] = InstallColor( RGB(111,157,217) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_DARK] = InstallColor( RGB(154,198,255) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_LEFT] = InstallColor( RGB(233, 238, 238) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_MIDDLE] = InstallColor( RGB(233, 238, 238) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_RIGHT] = InstallColor( RGB(233, 238, 238) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_LEFT] = InstallColor( RGB(215, 227, 234) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_MIDDLE] = InstallColor( RGB(215, 227, 234) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_RIGHT] = InstallColor( RGB(215, 227, 234) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_TOP] = InstallColor( RGB(227, 239, 254) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_BOTTOM] = InstallColor( RGB(131, 176, 236) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_HP_LEFT] = InstallColor( RGB(252, 151, 61) );
- m_mapColorTranslate[_2003CLR_BTN_HP_RIGHT] = InstallColor( RGB(255, 184, 94) );
- m_mapColorTranslate[CLR_3DFACE_IN] = InstallColor( RGB(255, 231, 162) );
- m_mapColorTranslate[XPCLR_MENU_BORDER] = InstallColor( RGB(101, 147, 207) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER] = InstallColor( RGB(255, 189, 105) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER_SELECTED] = m_mapColorTranslate[XPCLR_HILIGHT_BORDER];
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_LIGHT] = InstallColor( RGB(231,239,255) );
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_DARK] = InstallColor( RGB(140,182,239) );
- m_mapColorTranslate[CLR_TEXT_DISABLED] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[COLOR_3DSHADOW] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_R] = InstallColor( RGB(194, 220, 255) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_F] = InstallColor( RGB(194, 220, 255) );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_NORMAL] = InstallColor( m_arrClrComboBoxBorder[0] );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_DISABLED] = InstallColor( m_arrClrComboBoxBorder[3] );
- m_mapColorTranslate[_2003CLR_GRADIENT_LIGHT] =
- m_mapColorTranslate[_2003CLR_GRADIENT_DARK] = InstallColor( RGB(191, 219, 255) );
- }
- void CExtPaintManagerOffice2007_R2_Silver::InitTranslatedColors()
- {
- CExtPaintManagerOffice2007_Impl::InitTranslatedColors();
- #if (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_LIGHT] = InstallColor( RGB(243, 245, 245) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_DARK] = InstallColor( RGB(213, 219, 231) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_LIGHT] = InstallColor( RGB(255, 255, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_DARK] = InstallColor( RGB(231, 234, 238) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_BOTTOM_LINE] = InstallColor( RGB(197, 199, 199) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_LIGHT] = InstallColor( RGB(223, 226, 229) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_DARK] = InstallColor( RGB(225, 227, 230) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_LIGHT] = InstallColor( RGB(246, 247, 248) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_DARK] = InstallColor( RGB(218, 223, 231) );
- m_mapColorTranslate[_2003CLR_PN_BORDER] = InstallColor( RGB(111, 112, 116) );
- m_mapColorTranslate[CLR_PN_CAPTION_TEXT] = InstallColor( RGB(21, 66, 139) );
- #endif // (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[CLR_GROUP_BOX_FRAME] = InstallColor( RGB(169,177,184) );
- m_mapColorTranslate[CLR_WRB_FRAME] = InstallColor( RGB(169,177,184) );
- m_mapColorTranslate[_2003CLR_EXPBTN_LIGHT] = InstallColor( RGB(179, 178, 200) );
- m_mapColorTranslate[_2003CLR_EXPBTN_DARK] = InstallColor( RGB(118, 116, 146) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_LIGHT] = InstallColor( RGB(243, 244, 250) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_MIDDLE] = InstallColor( RGB(225, 226, 236) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_DARK] = InstallColor( RGB(134, 130, 166) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_BOTTOM_LINE] = InstallColor( RGB(124, 124, 148) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_LIGHT] = InstallColor( RGB(255,255,255) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_DARK] = InstallColor( RGB(84, 84, 117) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_LIGHT] = InstallColor( RGB(255, 255, 255) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_DARK] = InstallColor( RGB(110, 109, 143) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_LEFT] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_MIDDLE] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_RIGHT] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_LEFT] = InstallColor( RGB(215, 215, 226) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_MIDDLE] = InstallColor( RGB(184, 185, 202) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_RIGHT] = InstallColor( RGB(128, 126, 158) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_TOP] = InstallColor( RGB(232, 233, 241) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_BOTTOM] = InstallColor( RGB(172, 170, 194) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_HP_LEFT] = InstallColor( RGB(252, 151, 61) );
- m_mapColorTranslate[_2003CLR_BTN_HP_RIGHT] = InstallColor( RGB(255, 184, 94) );
- m_mapColorTranslate[CLR_3DFACE_IN] = InstallColor( RGB(255, 238, 194) );
- m_mapColorTranslate[XPCLR_MENU_BORDER] = InstallColor( RGB(124, 124, 148) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER] = InstallColor( RGB(255, 189, 105) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER_SELECTED] = m_mapColorTranslate[XPCLR_HILIGHT_BORDER];
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_LIGHT] = InstallColor( RGB(249, 249, 255) );
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_DARK] = InstallColor( RGB(159, 157, 185) );
- m_mapColorTranslate[CLR_TEXT_DISABLED] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[COLOR_3DSHADOW] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_R] = InstallColor( RGB(219, 218, 228) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_F] = InstallColor( RGB(219, 218, 228) );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_NORMAL] = InstallColor( m_arrClrComboBoxBorder[0] );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_DISABLED] = InstallColor( m_arrClrComboBoxBorder[3] );
- m_mapColorTranslate[_2003CLR_GRADIENT_LIGHT] = InstallColor( RGB(243, 243, 247) );
- m_mapColorTranslate[_2003CLR_GRADIENT_DARK] = InstallColor( RGB(215, 215, 229) );
- }
- void CExtPaintManagerOffice2007_R2_Obsidian::InitTranslatedColors()
- {
- CExtPaintManagerOffice2007_Impl::InitTranslatedColors();
- #if (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_LIGHT] = InstallColor( RGB(240, 241, 242) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_DARK] = InstallColor( RGB(221, 224, 227) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_LIGHT] = InstallColor( RGB(255, 255, 255) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_HOVER_DARK] = InstallColor( RGB(232, 234, 236) );
- m_mapColorTranslate[_2003CLR_PN_PANE_CAPTION_BOTTOM_LINE] = InstallColor( RGB(199, 203, 209) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_LIGHT] = InstallColor( RGB(223, 226, 229) );
- m_mapColorTranslate[_2003CLR_PN_ITEM_DARK] = InstallColor( RGB(225, 227, 230) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_LIGHT] = InstallColor( RGB(240, 241, 242) );
- m_mapColorTranslate[_2003CLR_PN_GRIPPER_DARK] = InstallColor( RGB(189, 194, 201) );
- m_mapColorTranslate[_2003CLR_PN_BORDER] = InstallColor( RGB(76, 83, 92) );
- m_mapColorTranslate[CLR_PN_CAPTION_TEXT] = InstallColor( RGB(0, 0, 0) );
- #endif // (!defined __EXT_MFC_NO_PAGE_NAVIGATOR )
- m_mapColorTranslate[CLR_GROUP_BOX_FRAME] = InstallColor( RGB(132,132,132) );
- m_mapColorTranslate[CLR_WRB_FRAME] = InstallColor( RGB(132,132,132) );
- m_mapColorTranslate[_2003CLR_EXPBTN_LIGHT] = InstallColor( RGB(178, 183, 191) );
- m_mapColorTranslate[_2003CLR_EXPBTN_DARK] = InstallColor( RGB(76, 83, 92) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_LIGHT] = InstallColor( RGB(205, 208, 213) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_MIDDLE] = InstallColor( RGB(187, 192, 198) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_GRADIENT_DARK] = InstallColor( RGB(138, 147, 157) );
- m_mapColorTranslate[_2003CLR_TOOLBAR_BOTTOM_LINE] = InstallColor( RGB(76, 83, 92) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_LIGHT] = InstallColor( RGB(255, 255, 255) );
- m_mapColorTranslate[_2003CLR_GRIPPER_DOT_DARK] = InstallColor( RGB(55, 60, 67) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_LIGHT] = InstallColor( RGB(221, 224, 227) );
- m_mapColorTranslate[_2003CLR_SEPARATOR_DARK] = InstallColor( RGB(145, 153, 164) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_LEFT] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_MIDDLE] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_NORM_RIGHT] = InstallColor( RGB(239, 239, 239) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_LEFT] = InstallColor( RGB(210, 213, 218) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_MIDDLE] = InstallColor( RGB(187, 192, 199) );
- m_mapColorTranslate[_2003CLR_MLA_RARELY_RIGHT] = InstallColor( RGB(197, 201, 207) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_TOP] = InstallColor( RGB(145, 153, 164) );
- m_mapColorTranslate[_2003CLR_TBB_BK_COMBINED_BOTTOM] = InstallColor( RGB(97, 106, 118) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_HOVER_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_LEFT] = InstallColor( RGB(255, 245, 204) );
- m_mapColorTranslate[_2003CLR_BTN_PRESSED_RIGHT] = InstallColor( RGB(255, 219, 117) );
- m_mapColorTranslate[_2003CLR_BTN_HP_LEFT] = InstallColor( RGB(252, 151, 61) );
- m_mapColorTranslate[_2003CLR_BTN_HP_RIGHT] = InstallColor( RGB(255, 184, 94) );
- m_mapColorTranslate[CLR_3DFACE_IN] = InstallColor( RGB(255, 231, 162) );
- m_mapColorTranslate[XPCLR_MENU_BORDER] = InstallColor( RGB(145, 153, 164) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER] = InstallColor( RGB(255, 189, 105) );
- m_mapColorTranslate[XPCLR_HILIGHT_BORDER_SELECTED] = m_mapColorTranslate[XPCLR_HILIGHT_BORDER];
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_LIGHT] = InstallColor( RGB(148,154,165) );
- m_mapColorTranslate[_2003CLR_EXPBTN_CIRCLE_DARK] = InstallColor( RGB(99,109,123) );
- m_mapColorTranslate[CLR_TEXT_DISABLED] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[COLOR_3DSHADOW] = InstallColor( RGB(141,141,141) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_R] = InstallColor( RGB(115,130,140) );
- m_mapColorTranslate[XPCLR_3DFACE_FLOAT_F] = InstallColor( RGB(115,130,140) );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_NORMAL] = InstallColor( m_arrClrComboBoxBorder[0] );
- m_mapColorTranslate[XPCLR_TEXT_FIELD_BORDER_DISABLED] = InstallColor( m_arrClrComboBoxBorder[3] );
- m_mapColorTranslate[_2003CLR_GRADIENT_LIGHT] =
- m_mapColorTranslate[_2003CLR_GRADIENT_DARK] = InstallColor( RGB(83, 83, 83) );
- }
- #if (!defined __EXT_MFC_NO_RIBBON_BAR)
- CSize CExtPaintManager::Ribbon_GetIconSize(
- const CObject * pHelperSrc,
- INT nILV,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- pHelperSrc;
- lParam;
- CSize _size( 16, 16 );
- if( nILV < 0 || nILV == __EXT_RIBBON_ILV_SIMPLE_LARGE )
- _size.cx = _size.cy = 32;
- _size.cx = UiScalingDo( _size.cx, __EUIST_X );
- _size.cy = UiScalingDo( _size.cy, __EUIST_Y );
- return _size;
- }
- INT CExtPaintManager::Ribbon_GetOuterGroupDistance(
- const CExtBarButton * pTBB,
- bool bDistanceBefore,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- pTBB;
- bDistanceBefore;
- lParam;
- return 1;
- }
- INT CExtPaintManagerOffice2007_R1::Ribbon_GetOuterGroupDistance(
- const CExtBarButton * pTBB,
- bool bDistanceBefore,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetOuterGroupDistance(
- pTBB,
- bDistanceBefore,
- lParam
- );
- return 0;
- }
- bool CExtPaintManager::Ribbon_OptionsPageBackgroundIsDefault() const
- {
- ASSERT_VALID( this );
- return false;
- }
- void CExtPaintManager::Ribbon_DwmAreaAdjust(
- CExtRibbonBar * pRibbonBar,
- CExtUxTheme::__EXT_UX_MARGINS & _margins,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pRibbonBar );
- lParam;
- if( Ribbon_DwmAreaCoversTabs() )
- _margins.cyTopHeight += pRibbonBar->RibbonLayout_GetTabLineHeight();
- }
- bool CExtPaintManager::Ribbon_DwmAreaCoversTabs() const
- {
- ASSERT_VALID( this );
- return false;
- }
- bool CExtPaintManagerOffice2010_Impl::Ribbon_DwmAreaCoversTabs() const
- {
- ASSERT_VALID( this );
- return true;
- }
- INT CExtPaintManager::Ribbon_GetContractedMarginHeight(
- const CExtRibbonPage * pRibbonPage,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- pRibbonPage;
- lParam;
- return 0;
- }
- INT CExtPaintManagerOffice2007_Impl::Ribbon_GetContractedMarginHeight(
- const CExtRibbonPage * pRibbonPage,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetContractedMarginHeight(
- pRibbonPage,
- lParam
- );
- return m_nContractedMarginHeight;
- }
- void CExtPaintManager::Ribbon_PaintContractedMargin(
- CDC & dc,
- const CExtRibbonPage * pRibbonPage,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT( dc.GetSafeHdc() != NULL );
- dc;
- pRibbonPage;
- lParam;
- }
- void CExtPaintManagerOffice2007_Impl::Ribbon_PaintContractedMargin(
- CDC & dc,
- const CExtRibbonPage * pRibbonPage,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT( dc.GetSafeHdc() != NULL );
- if( IsHighContrast() )
- {
- CExtPaintManagerXP::Ribbon_PaintContractedMargin(
- dc,
- pRibbonPage,
- lParam
- );
- return;
- }
- if( m_clrContractedMargin1 != COLORREF(-1L) )
- {
- CRect rc;
- pRibbonPage->GetClientRect( &rc );
- rc.top = rc.bottom - 1;
- if( dc.RectVisible( &rc ) )
- dc.FillSolidRect( &rc, m_clrContractedMargin1 );
- if( m_clrContractedMargin2 != COLORREF(-1L) )
- {
- rc.OffsetRect( 0, -1 );
- if( dc.RectVisible( &rc ) )
- dc.FillSolidRect( &rc, m_clrContractedMargin2 );
- } // if( m_clrContractedMargin2 != COLORREF(-1L) )
- } // if( m_clrContractedMargin1 != COLORREF(-1L) )
- }
- INT CExtPaintManager::Ribbon_GetGroupHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- lParam;
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CWindowDC dc( NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- // //INT nBasicHeight = 95;
- // INT nBasicHeight = _TxtM.tmHeight*3 + 56;
- // INT nRetVal = UiScalingDo( nBasicHeight, __EUIST_Y );
- INT nRetVal = _TxtM.tmHeight*3;
- if( g_PaintManager.m_nLPY > 120 )
- nRetVal += UiScalingDo( 62, __EUIST_Y );
- else
- nRetVal += UiScalingDo( 56, __EUIST_Y );
- if( pGroupTBB != NULL )
- {
- ASSERT_VALID( pGroupTBB );
- const CExtRibbonPage * pRibbonPage = pGroupTBB->GetRibbonPage();
- if( pRibbonPage != NULL )
- {
- ASSERT_VALID( pRibbonPage );
- if( pRibbonPage->m_bHelperPopupMode
- && ( ! pRibbonPage->m_bHelperAutoHideMode )
- && ( ! Ribbon_IsPopupGroupWithCaption( (CObject*)pRibbonPage ) )
- )
- {
- INT nCaptionHeight = Ribbon_GroupCaptionGetHeight( NULL );
- nRetVal -= nCaptionHeight;
- }
- } // if( pRibbonPage != NULL )
- } // if( pGroupTBB != NULL )
- return nRetVal;
- }
- INT CExtPaintManagerNativeXP::Ribbon_GetGroupHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- INT nHeight = CExtPaintManager::Ribbon_GetGroupHeight( pGroupTBB, lParam );
- if( g_PaintManager.m_nLPY > 96 )
- nHeight += 2;
- return nHeight;
- }
- INT CExtPaintManagerOffice2007_Impl::Ribbon_GetGroupHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return CExtPaintManagerXP::Ribbon_GetGroupHeight( pGroupTBB, lParam );
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CWindowDC dc( NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- // //INT nBasicHeight = 92;
- // INT nBasicHeight = _TxtM.tmHeight*3 + 53;
- // INT nRetVal = UiScalingDo( nBasicHeight, __EUIST_Y );
- INT nRetVal = _TxtM.tmHeight*3;
- if( g_PaintManager.m_nLPY > 120 )
- nRetVal += UiScalingDo( 60, __EUIST_Y );
- else
- nRetVal += UiScalingDo( 54, __EUIST_Y );
- if( pGroupTBB != NULL )
- {
- ASSERT_VALID( pGroupTBB );
- const CExtRibbonPage * pRibbonPage = pGroupTBB->GetRibbonPage();
- if( pRibbonPage != NULL )
- {
- ASSERT_VALID( pRibbonPage );
- if( pRibbonPage->m_bHelperPopupMode
- && ( ! pRibbonPage->m_bHelperAutoHideMode )
- && ( ! Ribbon_IsPopupGroupWithCaption( (CObject*)pRibbonPage ) )
- )
- {
- INT nCaptionHeight = Ribbon_GroupCaptionGetHeight( NULL );
- nRetVal -= nCaptionHeight;
- }
- } // if( pRibbonPage != NULL )
- } // if( pGroupTBB != NULL )
- return nRetVal;
- }
- INT CExtPaintManagerOffice2010_Impl::Ribbon_GetGroupHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return CExtPaintManagerXP::Ribbon_GetGroupHeight( pGroupTBB, lParam );
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CWindowDC dc( NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- // //INT nBasicHeight = 92;
- // INT nBasicHeight = _TxtM.tmHeight*3 + 48;
- // INT nRetVal = UiScalingDo( nBasicHeight, __EUIST_Y );
- INT nRetVal = _TxtM.tmHeight*3;
- if( g_PaintManager.m_nLPY > 120 )
- nRetVal += UiScalingDo( 48, __EUIST_Y );
- else
- nRetVal += UiScalingDo( 40, __EUIST_Y ) + 8;
- if( pGroupTBB != NULL )
- {
- ASSERT_VALID( pGroupTBB );
- const CExtRibbonPage * pRibbonPage = pGroupTBB->GetRibbonPage();
- if( pRibbonPage != NULL )
- {
- ASSERT_VALID( pRibbonPage );
- if( pRibbonPage->m_bHelperPopupMode
- && ( ! pRibbonPage->m_bHelperAutoHideMode )
- && ( ! Ribbon_IsPopupGroupWithCaption( (CObject*)pRibbonPage ) )
- )
- {
- INT nCaptionHeight = Ribbon_GroupCaptionGetHeight( NULL );
- nRetVal -= nCaptionHeight;
- }
- } // if( pRibbonPage != NULL )
- } // if( pGroupTBB != NULL )
- return nRetVal;
- }
- INT CExtPaintManagerOffice2007_R1::Ribbon_GetGroupHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return CExtPaintManagerXP::Ribbon_GetGroupHeight( pGroupTBB, lParam );
- lParam;
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CWindowDC dc( NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- // //INT nBasicHeight = 93;
- // INT nBasicHeight = _TxtM.tmHeight*3 + 54;
- // INT nRetVal = UiScalingDo( nBasicHeight, __EUIST_Y );
- INT nRetVal = _TxtM.tmHeight*3;
- if( g_PaintManager.m_nLPY > 120 )
- nRetVal += UiScalingDo( 60, __EUIST_Y );
- else
- nRetVal += UiScalingDo( 54, __EUIST_Y );
- if( pGroupTBB != NULL )
- {
- ASSERT_VALID( pGroupTBB );
- const CExtRibbonPage * pRibbonPage = pGroupTBB->GetRibbonPage();
- if( pRibbonPage != NULL )
- {
- ASSERT_VALID( pRibbonPage );
- if( pRibbonPage->m_bHelperPopupMode
- && ( ! pRibbonPage->m_bHelperAutoHideMode )
- && ( ! Ribbon_IsPopupGroupWithCaption( (CObject*)pRibbonPage ) )
- )
- {
- INT nCaptionHeight = Ribbon_GroupCaptionGetHeight( NULL );
- nRetVal -= nCaptionHeight;
- }
- } // if( pRibbonPage != NULL )
- } // if( pGroupTBB != NULL )
- return nRetVal;
- }
- INT CExtPaintManager::Ribbon_GetToolGroupExtraOffset(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- pGroupTBB;
- lParam;
- return -1;
- }
- INT CExtPaintManagerOffice2007_Impl::Ribbon_GetToolGroupExtraOffset(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetToolGroupExtraOffset(
- pGroupTBB,
- lParam
- );
- return 0;
- }
- INT CExtPaintManagerOffice2007_R1::Ribbon_GetToolGroupExtraOffset(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetToolGroupExtraOffset(
- pGroupTBB,
- lParam
- );
- return 0;
- }
- INT CExtPaintManager::Ribbon_GetToolGroupExtraLineDistance(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- pGroupTBB;
- lParam;
- return 1;
- }
- INT CExtPaintManagerOffice2007_Impl::Ribbon_GetToolGroupExtraLineDistance(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetToolGroupExtraLineDistance(
- pGroupTBB,
- lParam
- );
- return 1;
- }
- INT CExtPaintManagerOffice2007_R1::Ribbon_GetToolGroupExtraLineDistance(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- // ASSERT_VALID( pGroupTBB );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetToolGroupExtraLineDistance(
- pGroupTBB,
- lParam
- );
- return 0;
- }
- CRect CExtPaintManager::Ribbon_GetContentPadding(
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- lParam;
- if( pTBB->IsSeparator() )
- return CRect( 1, 1, 1, 1 );
- const CExtRibbonButtonGroup * pGroupTBB = DYNAMIC_DOWNCAST( CExtRibbonButtonGroup, pTBB );
- if( pGroupTBB != NULL )
- {
- if( pGroupTBB->ParentButtonGet() == NULL )
- return CRect( 2, 2, 2, 2 );
- if( pGroupTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) ) )
- return CRect( 1, 0, 1, 0 );
- return CRect( 0, 0, 0, 0 );
- }
- if( pTBB->IsKindOf( RUNTIME_CLASS(CExtRibbonButton) )
- || pTBB->IsKindOf( RUNTIME_CLASS(CExtBarColorButton) )
- )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL )
- {
- if( pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) ) )
- return CRect( 0, 0, 0, 0 );
- if( pParentTBB->ParentButtonGet() == NULL )
- return CRect( 2, 0, 2, 0 );
- }
- return CRect( 3, 0, 3, 0 );
- }
- return CRect( 0, 0, 0, 0 );
- }
- CRect CExtPaintManagerOffice2007_R1::Ribbon_GetContentPadding(
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- if( IsHighContrast() )
- return CExtPaintManagerXP::Ribbon_GetContentPadding( pTBB, lParam );
- if( pTBB->IsSeparator() )
- return CRect( 1, 1, 1, 1 );
- const CExtRibbonButtonGroup * pGroupTBB = DYNAMIC_DOWNCAST( CExtRibbonButtonGroup, pTBB );
- if( pGroupTBB != NULL )
- {
- if( pGroupTBB->ParentButtonGet() == NULL )
- return CRect( 4, 2, 4, 2 );
- if( pGroupTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) ) )
- return CRect( 1, 0, 1, 0 );
- return CRect( 0, 0, 0, 0 );
- }
- if( pTBB->IsKindOf( RUNTIME_CLASS(CExtRibbonButton) )
- || pTBB->IsKindOf( RUNTIME_CLASS(CExtBarColorButton) )
- )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- )
- return CRect( 0, 0, 0, 0 );
- return CRect( 3, 0, 3, 0 );
- }
- return CRect( 0, 0, 0, 0 );
- }
- CRect CExtPaintManagerOffice2010_Impl::Ribbon_GetContentPadding(
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- lParam;
- if( pTBB->IsSeparator() )
- return CRect( 1, 1, 1, 1 );
- const CExtRibbonButtonGroup * pGroupTBB = DYNAMIC_DOWNCAST( CExtRibbonButtonGroup, pTBB );
- if( pGroupTBB != NULL )
- {
- if( pGroupTBB->ParentButtonGet() == NULL )
- return CRect( 2, 2, 2, 0 );
- if( pGroupTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) ) )
- return CRect( 1, 0, 1, 0 );
- return CRect( 0, 0, 0, 0 );
- }
- if( pTBB->IsKindOf( RUNTIME_CLASS(CExtRibbonButton) )
- || pTBB->IsKindOf( RUNTIME_CLASS(CExtBarColorButton) )
- )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL )
- {
- if( pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) ) )
- return CRect( 0, 0, 0, 0 );
- if( pParentTBB->ParentButtonGet() == NULL )
- return CRect( 2, 0, 2, 0 );
- }
- return CRect( 3, 0, 3, 0 );
- }
- return CRect( 0, 0, 0, 0 );
- }
- CSize CExtPaintManager::Ribbon_GetDropDownArrowSize(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- dc;
- nILV;
- pTBB;
- lParam;
- CSize _size( 10, 6 );
- _size.cx = UiScalingDo( _size.cx, __EUIST_X );
- _size.cy = UiScalingDo( _size.cy, __EUIST_Y );
- return _size;
- }
- INT CExtPaintManager::Ribbon_GetTextToIconDistance(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- dc;
- pTBB;
- lParam;
- INT nTextToIconDistance = 0;
- if( nILV == __EXT_RIBBON_ILV_SIMPLE_LARGE )
- nTextToIconDistance = UiScalingDo( 1, __EUIST_Y );
- else
- nTextToIconDistance = UiScalingDo( 2, __EUIST_X );
- return nTextToIconDistance;
- }
- CSize CExtPaintManager::Ribbon_CalcButtonSize(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- if( pTBB->IsSeparator() )
- return CSize( 2, 2 );
- const CExtRibbonNode * pRibbonNode = pTBB->Ribbon_GetNode();
- if( pRibbonNode == NULL )
- return CSize( 0, 0 );
- ASSERT_VALID( pRibbonNode );
- if( nILV < 0 )
- nILV = pTBB->RibbonILV_Get( 0 );
- CSize _sizeIcon = Ribbon_GetIconSize( pTBB, nILV, lParam );
- const CExtCmdIcon * pCmdIcon = pTBB->GetIconPtr();
- bool bHaveIcon = ( pCmdIcon != NULL && (! pCmdIcon->IsEmpty() ) ) ? true : false;
- CExtSafeString strText;
- if( ! ( nILV == __EXT_RIBBON_ILV_SIMPLE_SMALL && bHaveIcon ) )
- strText = pTBB->GetText();
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE && pCmdIcon == 0 )
- _sizeIcon.cx = _sizeIcon.cy = 0;
- CSize _sizeText( 0, 0 );
- UINT nDT = 0;
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- strText.Replace( _T("r"), _T(" ") );
- strText.Replace( _T("n"), _T(" ") );
- strText.Replace( _T("t"), _T(" ") );
- strText.Replace( _T(" "), _T(" ") );
- strText.TrimLeft( _T(" ") );
- strText.TrimRight( _T(" ") );
- nDT = DT_SINGLELINE|DT_LEFT|DT_TOP;
- } // if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- else
- nDT = DT_LEFT|DT_TOP;
- if( ! strText.IsEmpty() )
- {
- CFont * pFont = ((CExtToolControlBar*)(pTBB->GetBar()))->OnGetToolbarFont( false, true );
- _sizeText = stat_CalcTextDimension( dc, *pFont, strText, nDT|DT_CALCRECT ).Size();
- // _sizeText.cx = UiScalingDo( _sizeText.cx, __EUIST_X );
- // _sizeText.cy = UiScalingDo( _sizeText.cy, __EUIST_Y );
- if( _sizeText.cx > 0 )
- _sizeText.cx += 4;
- } // if( ! strText.IsEmpty() )
- CSize _sizeDDA( 0, 0 );
- if( pTBB->IsAbleToTrackMenu() )
- _sizeDDA = Ribbon_GetDropDownArrowSize( dc, nILV, pTBB, lParam );
- CRect rcCP = pTBB->OnRibbonGetContentPadding();
- rcCP.left = UiScalingDo( rcCP.left, __EUIST_X );
- rcCP.top = UiScalingDo( rcCP.top, __EUIST_Y );
- rcCP.right = UiScalingDo( rcCP.right, __EUIST_X );
- rcCP.bottom = UiScalingDo( rcCP.bottom, __EUIST_Y );
- INT nTextToIconDistance = Ribbon_GetTextToIconDistance( dc, nILV, pTBB, lParam );
- CSize _size = _sizeIcon;
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- INT nBasicHeight = _TxtM.tmHeight;
- if( nILV == __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- _sizeText.cx += _sizeDDA.cx;
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cy += nTextToIconDistance;
- }
- _size.cy += _sizeText.cy;
- _size.cx = max( _sizeText.cx, _size.cx );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- // CSize _sizeAdjust( 42, 66 );
- CSize _sizeAdjust( 42, nBasicHeight * 2 + 40 );
- _sizeAdjust.cx = UiScalingDo( _sizeAdjust.cx, __EUIST_X );
- _sizeAdjust.cy = UiScalingDo( _sizeAdjust.cy, __EUIST_Y );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- else
- {
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cx += _sizeDDA.cx;
- if( bHaveIcon )
- _sizeText.cx += nTextToIconDistance;
- _size.cx += 4;
- }
- else
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- )
- _size.cx += 8;
- else if(
- pTBB->IsAbleToTrackMenu()
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButton ) ) )
- )
- _size.cx += 7;
- }
- _size.cx += _sizeText.cx;
- _size.cy = max( _sizeText.cy, _size.cy );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- if( pTBB->IsAbleToTrackMenu() )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- bool bInToolGroup =
- ( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- ) ? true : false;
- if( bInToolGroup
- || ( nILV < __EXT_RIBBON_ILV_SIMPLE_LARGE
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonGroup ) ) )
- )
- )
- {
- INT nDropDownButtonWidth = GetDropDownButtonWidth( (CObject*)pTBB, lParam );
- _size.cx += nDropDownButtonWidth;
- }
- }
- // CSize _sizeAdjust( 22, 22 );
- CSize _sizeAdjust( nBasicHeight + 6, nBasicHeight + 6 );
- _sizeAdjust.cx = max( _sizeAdjust.cx, 22 );
- _sizeAdjust.cy = max( _sizeAdjust.cy, 22 );
- _sizeAdjust.cx = UiScalingDo( _sizeAdjust.cx, __EUIST_X );
- _sizeAdjust.cy = UiScalingDo( _sizeAdjust.cy, __EUIST_Y );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- return _size;
- }
- CSize CExtPaintManagerOffice2007_Impl::Ribbon_CalcButtonSize(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- if( pTBB->IsSeparator() )
- return CSize( 2, 2 );
- const CExtRibbonNode * pRibbonNode = pTBB->Ribbon_GetNode();
- if( pRibbonNode == NULL )
- return CSize( 0, 0 );
- ASSERT_VALID( pRibbonNode );
- if( nILV < 0 )
- nILV = pTBB->RibbonILV_Get( 0 );
- CSize _sizeIcon = Ribbon_GetIconSize( pTBB, nILV, lParam );
- const CExtCmdIcon * pCmdIcon = pTBB->GetIconPtr();
- bool bHaveIcon = ( pCmdIcon != NULL && (! pCmdIcon->IsEmpty() ) ) ? true : false;
- CExtSafeString strText;
- if( ! ( nILV == __EXT_RIBBON_ILV_SIMPLE_SMALL && bHaveIcon ) )
- strText = pTBB->GetText();
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE && pCmdIcon == 0 )
- _sizeIcon.cx = _sizeIcon.cy = 0;
- CSize _sizeText( 0, 0 );
- UINT nDT = 0;
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- strText.Replace( _T("r"), _T(" ") );
- strText.Replace( _T("n"), _T(" ") );
- strText.Replace( _T("t"), _T(" ") );
- strText.Replace( _T(" "), _T(" ") );
- strText.TrimLeft( _T(" ") );
- strText.TrimRight( _T(" ") );
- nDT = DT_SINGLELINE|DT_LEFT|DT_TOP;
- } // if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- else
- nDT = DT_LEFT|DT_TOP;
- if( ! strText.IsEmpty() )
- {
- CFont * pFont = ((CExtToolControlBar*)(pTBB->GetBar()))->OnGetToolbarFont( false, true );
- _sizeText = stat_CalcTextDimension( dc, *pFont, strText, nDT|DT_CALCRECT ).Size();
- // _sizeText.cx = UiScalingDo( _sizeText.cx, __EUIST_X );
- // _sizeText.cy = UiScalingDo( _sizeText.cy, __EUIST_Y );
- if( _sizeText.cx > 0 )
- _sizeText.cx += 4;
- } // if( ! strText.IsEmpty() )
- CSize _sizeDDA( 0, 0 );
- if( pTBB->IsAbleToTrackMenu() )
- _sizeDDA = Ribbon_GetDropDownArrowSize( dc, nILV, pTBB, lParam );
- CRect rcCP = pTBB->OnRibbonGetContentPadding();
- // rcCP.left = UiScalingDo( rcCP.left, __EUIST_X );
- // rcCP.top = UiScalingDo( rcCP.top, __EUIST_Y );
- // rcCP.right = UiScalingDo( rcCP.right, __EUIST_X );
- // rcCP.bottom = UiScalingDo( rcCP.bottom, __EUIST_Y );
- INT nTextToIconDistance = Ribbon_GetTextToIconDistance( dc, nILV, pTBB, lParam );
- CSize _size = _sizeIcon;
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- INT nBasicHeight = _TxtM.tmHeight;
- if( nILV == __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- _sizeText.cx += _sizeDDA.cx;
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cy += nTextToIconDistance;
- }
- _size.cy += _sizeText.cy;
- _size.cx = max( _sizeText.cx, _size.cx );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- // CSize _sizeAdjust( 42, 66 );
- CSize _sizeAdjust(
- UiScalingDo( 42, __EUIST_X ),
- nBasicHeight * 2 + UiScalingDo( 40, __EUIST_Y )
- );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- else
- {
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cx += _sizeDDA.cx;
- if( bHaveIcon )
- _sizeText.cx += nTextToIconDistance;
- _size.cx += 4;
- }
- else
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- )
- _size.cx += 8;
- else if(
- pTBB->IsAbleToTrackMenu()
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButton ) ) )
- )
- _size.cx += 7;
- }
- _size.cx += _sizeText.cx;
- _size.cy = max( _sizeText.cy, _size.cy );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- if( pTBB->IsAbleToTrackMenu() )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- bool bInToolGroup =
- ( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- ) ? true : false;
- if( bInToolGroup
- || ( nILV < __EXT_RIBBON_ILV_SIMPLE_LARGE
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonGroup ) ) )
- )
- )
- {
- INT nDropDownButtonWidth = GetDropDownButtonWidth( (CObject*)pTBB, lParam );
- _size.cx += nDropDownButtonWidth;
- }
- }
- // CSize _sizeAdjust( 22, 22 );
- CSize _sizeAdjust( nBasicHeight + 6, nBasicHeight + 6 );
- if( g_PaintManager.m_bIsWinVistaOrLater && g_PaintManager.m_nLPY <= 96 )
- {
- _sizeAdjust.cx = max( _sizeAdjust.cx, 22 );
- _sizeAdjust.cy = max( _sizeAdjust.cy, 22 );
- }
- _sizeAdjust.cx = UiScalingDo( _sizeAdjust.cx, __EUIST_X );
- _sizeAdjust.cy = UiScalingDo( _sizeAdjust.cy, __EUIST_Y );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- return _size;
- }
- CSize CExtPaintManagerOffice2007_R1::Ribbon_CalcButtonSize(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- return CExtPaintManagerOffice2003::Ribbon_CalcButtonSize( dc, nILV, pTBB, lParam );
- }
- CSize CExtPaintManagerOffice2010_Impl::Ribbon_CalcButtonSize(
- CDC & dc,
- INT nILV,
- const CExtBarButton * pTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT_VALID( pTBB );
- if( pTBB->IsSeparator() )
- return CSize( 2, 2 );
- const CExtRibbonNode * pRibbonNode = pTBB->Ribbon_GetNode();
- if( pRibbonNode == NULL )
- return CSize( 0, 0 );
- ASSERT_VALID( pRibbonNode );
- if( nILV < 0 )
- nILV = pTBB->RibbonILV_Get( 0 );
- CSize _sizeIcon = Ribbon_GetIconSize( pTBB, nILV, lParam );
- const CExtCmdIcon * pCmdIcon = pTBB->GetIconPtr();
- bool bHaveIcon = ( pCmdIcon != NULL && (! pCmdIcon->IsEmpty() ) ) ? true : false;
- CExtSafeString strText;
- if( ! ( nILV == __EXT_RIBBON_ILV_SIMPLE_SMALL && bHaveIcon ) )
- strText = pTBB->GetText();
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE && pCmdIcon == 0 )
- _sizeIcon.cx = _sizeIcon.cy = 0;
- CSize _sizeText( 0, 0 );
- UINT nDT = 0;
- if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- strText.Replace( _T("r"), _T(" ") );
- strText.Replace( _T("n"), _T(" ") );
- strText.Replace( _T("t"), _T(" ") );
- strText.Replace( _T(" "), _T(" ") );
- strText.TrimLeft( _T(" ") );
- strText.TrimRight( _T(" ") );
- nDT = DT_SINGLELINE|DT_LEFT|DT_TOP;
- } // if( nILV != __EXT_RIBBON_ILV_SIMPLE_LARGE )
- else
- nDT = DT_LEFT|DT_TOP;
- if( ! strText.IsEmpty() )
- {
- CFont * pFont = ((CExtToolControlBar*)(pTBB->GetBar()))->OnGetToolbarFont( false, true );
- _sizeText = stat_CalcTextDimension( dc, *pFont, strText, nDT|DT_CALCRECT ).Size();
- // _sizeText.cx = UiScalingDo( _sizeText.cx, __EUIST_X );
- // _sizeText.cy = UiScalingDo( _sizeText.cy, __EUIST_Y );
- if( _sizeText.cx > 0 )
- _sizeText.cx += 4;
- } // if( ! strText.IsEmpty() )
- CSize _sizeDDA( 0, 0 );
- if( pTBB->IsAbleToTrackMenu() )
- _sizeDDA = Ribbon_GetDropDownArrowSize( dc, nILV, pTBB, lParam );
- CRect rcCP = pTBB->OnRibbonGetContentPadding();
- rcCP.left = UiScalingDo( rcCP.left, __EUIST_X );
- rcCP.top = UiScalingDo( rcCP.top, __EUIST_Y );
- rcCP.right = UiScalingDo( rcCP.right, __EUIST_X );
- rcCP.bottom = UiScalingDo( rcCP.bottom, __EUIST_Y );
- INT nTextToIconDistance = Ribbon_GetTextToIconDistance( dc, nILV, pTBB, lParam );
- CSize _size = _sizeIcon;
- CFont * pMeasureFont = (CFont*)&m_FontRibbonNormal;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- INT nBasicHeight = _TxtM.tmHeight;
- if( nILV == __EXT_RIBBON_ILV_SIMPLE_LARGE )
- {
- _sizeText.cx += _sizeDDA.cx;
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cy += nTextToIconDistance;
- }
- _size.cy += _sizeText.cy;
- _size.cx = max( _sizeText.cx, _size.cx );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- // CSize _sizeAdjust( 42, 66 );
- CSize _sizeAdjust(
- UiScalingDo( 42, __EUIST_X ),
- nBasicHeight * 2 + UiScalingDo( 40, __EUIST_Y )
- );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- else
- {
- if( ! strText.IsEmpty() )
- {
- _sizeText.cy = max( _sizeText.cy, _sizeDDA.cy );
- _sizeText.cx += _sizeDDA.cx;
- if( bHaveIcon )
- _sizeText.cx += nTextToIconDistance;
- _size.cx += 4;
- }
- else
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- if( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- )
- _size.cx += 8;
- else if(
- pTBB->IsAbleToTrackMenu()
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButton ) ) )
- )
- _size.cx += 7;
- }
- _size.cx += _sizeText.cx;
- _size.cy = max( _sizeText.cy, _size.cy );
- _size.cx += rcCP.left + rcCP.right;
- _size.cy += rcCP.top + rcCP.bottom;
- if( pTBB->IsAbleToTrackMenu() )
- {
- const CExtBarButton * pParentTBB = pTBB->ParentButtonGet();
- bool bInToolGroup =
- ( pParentTBB != NULL
- && pParentTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonToolGroup ) )
- ) ? true : false;
- if( bInToolGroup
- || ( nILV < __EXT_RIBBON_ILV_SIMPLE_LARGE
- && (! pTBB->IsKindOf( RUNTIME_CLASS( CExtRibbonButtonGroup ) ) )
- )
- )
- {
- INT nDropDownButtonWidth = GetDropDownButtonWidth( (CObject*)pTBB, lParam );
- _size.cx += nDropDownButtonWidth;
- }
- }
- // CSize _sizeAdjust( 22, 22 );
- CSize _sizeAdjust( nBasicHeight + 6, nBasicHeight + 6 );
- _sizeAdjust.cx = max( _sizeAdjust.cx, 22 );
- _sizeAdjust.cy = max( _sizeAdjust.cy, 22 );
- // _sizeAdjust.cx = UiScalingDo( _sizeAdjust.cx, __EUIST_X );
- // _sizeAdjust.cy = UiScalingDo( _sizeAdjust.cy, __EUIST_Y );
- _size.cx = max( _size.cx, _sizeAdjust.cx );
- _size.cy = max( _size.cy, _sizeAdjust.cy );
- }
- return _size;
- }
- bool CExtPaintManager::Ribbon_GroupCaptionIsAtTop(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- ) const
- {
- ASSERT_VALID( this );
- pGroupTBB;
- lParam;
- return true;
- }
- bool CExtPaintManagerOffice2007_Impl::Ribbon_GroupCaptionIsAtTop(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- ) const
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GroupCaptionIsAtTop(
- pGroupTBB,
- lParam
- );
- return m_bRibbonGroupCaptionAtTop;
- }
- INT CExtPaintManager::Ribbon_GroupCaptionGetHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- ) const
- {
- ASSERT_VALID( this );
- lParam;
- if( pGroupTBB != NULL )
- {
- ASSERT_VALID( pGroupTBB );
- const CExtRibbonPage * pRibbonPage = pGroupTBB->GetRibbonPage();
- if( pRibbonPage != NULL )
- {
- ASSERT_VALID( pRibbonPage );
- if( pRibbonPage->m_bHelperPopupMode
- && ( ! pRibbonPage->m_bHelperAutoHideMode )
- && ( ! Ribbon_IsPopupGroupWithCaption( (CObject*)pRibbonPage ) )
- )
- return 0;
- } // if( pRibbonPage != NULL )
- } // if( pGroupTBB != NULL )
- CFont * pMeasureFont = (CFont*)&m_FontRibbonGroupCaption;
- ASSERT( pMeasureFont->GetSafeHandle() != NULL );
- CWindowDC dc( NULL );
- CFont * pOldFont = dc.SelectObject( pMeasureFont );
- TEXTMETRIC _TxtM;
- ::memset( &_TxtM, 0, sizeof(TEXTMETRIC) );
- if( ! dc.GetTextMetrics( &_TxtM ) )
- _TxtM.tmHeight = 17;
- dc.SelectObject( pOldFont );
- INT nCaptionHeight = _TxtM.tmHeight;
- nCaptionHeight = UiScalingDo( nCaptionHeight, __EUIST_Y );
- if( g_PaintManager.m_nLPY <= 96 )
- nCaptionHeight += 5;
- return nCaptionHeight;
- }
- INT CExtPaintManagerOffice2007_Impl::Ribbon_GroupCaptionGetHeight(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- ) const
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return CExtPaintManagerXP::Ribbon_GroupCaptionGetHeight( pGroupTBB, lParam );
- return CExtPaintManagerOffice2003::Ribbon_GroupCaptionGetHeight( pGroupTBB, lParam );
- }
- CExtCmdIcon * CExtPaintManager::Ribbon_GetGroupCollapsedIcon(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- lParam;
- if( pGroupTBB == NULL )
- return NULL;
- ASSERT_VALID( pGroupTBB );
- CExtRibbonNode * pRibbonNode = (CExtRibbonNode *)pGroupTBB->Ribbon_GetNode();
- if( pRibbonNode == NULL )
- return NULL;
- ASSERT_VALID( pRibbonNode );
- if( ! pRibbonNode->m_iconBig.IsEmpty() )
- return (& pRibbonNode->m_iconBig );
- if( ! pRibbonNode->m_iconSmall.IsEmpty() )
- {
- CSize _size = Ribbon_GetIconSize( pGroupTBB, __EXT_RIBBON_ILV_SIMPLE_LARGE );
- pRibbonNode->m_iconBig = pRibbonNode->m_iconSmall;
- pRibbonNode->m_iconBig.Scale( _size );
- return (& pRibbonNode->m_iconBig );
- }
- return NULL;
- }
- CExtCmdIcon * CExtPaintManagerOffice2007_Impl::Ribbon_GetGroupCollapsedIcon(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetGroupCollapsedIcon(
- pGroupTBB,
- lParam
- );
- if( pGroupTBB == NULL )
- return NULL;
- ASSERT_VALID( pGroupTBB );
- CExtRibbonNode * pRibbonNode = (CExtRibbonNode *)pGroupTBB->Ribbon_GetNode();
- if( pRibbonNode == NULL )
- return NULL;
- ASSERT_VALID( pRibbonNode );
- if( ! pRibbonNode->m_iconSmall.IsEmpty() )
- return (& pRibbonNode->m_iconSmall );
- if( ! pRibbonNode->m_iconBig.IsEmpty() )
- {
- CSize _sizeSmall = Ribbon_GetIconSize( pGroupTBB, __EXT_RIBBON_ILV_SIMPLE_SMALL );
- pRibbonNode->m_iconSmall = pRibbonNode->m_iconBig;
- pRibbonNode->m_iconSmall.Scale( _sizeSmall );
- return (& pRibbonNode->m_iconSmall );
- }
- return NULL;
- }
- CExtCmdIcon * CExtPaintManagerOffice2007_R1::Ribbon_GetGroupCollapsedIcon(
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- if( IsHighContrast() )
- return
- CExtPaintManagerXP::Ribbon_GetGroupCollapsedIcon(
- pGroupTBB,
- lParam
- );
- CExtCmdIcon * pCmdIcon = CExtPaintManager::Ribbon_GetGroupCollapsedIcon( pGroupTBB, lParam );
- if( pCmdIcon != NULL && (! pCmdIcon->IsEmpty() ) )
- pCmdIcon->Scale( CSize( 32, 32 ) );
- return pCmdIcon;
- }
- void CExtPaintManager::Ribbon_PaintText(
- CDC & dc,
- __EXT_MFC_SAFE_LPCTSTR strText,
- const RECT & rcText,
- UINT nDrawTextFlags,
- bool bDrawDropDownArrow,
- CExtBitmap * pBmpAlternativeDropDownArrow,
- CObject * pHelperSrc,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT( dc.GetSafeHdc() != NULL );
- pHelperSrc;
- lParam;
- CExtSafeString strCaptionText = ( strText == NULL ) ? _T("") : strText;
- strCaptionText.TrimLeft( _T(" rt") );
- strCaptionText.TrimRight( _T(" rt") );
- CExtSafeStringArray strArray;
- INT nPartIndex, nPartCount, nMeasuredTextHeight = 0;
- if( ! strCaptionText.IsEmpty() )
- {
- nPartCount = 2;
- for( nPartIndex = 0; nPartIndex < nPartCount; nPartIndex ++ )
- {
- INT nSepPos = strCaptionText.Find( 'n' );
- if( nSepPos >= 0 )
- {
- CExtSafeString s = strCaptionText.Left( nSepPos );
- s.TrimLeft( _T(" rt") );
- s.TrimRight( _T(" rt") );
- if( ! s.IsEmpty() )
- {
- strArray.Add( s );
- CRect rcCalc( 0, 0, 0, 0 );
- dc.DrawText(
- LPCTSTR(s),
- INT( _tcslen( LPCTSTR(s) ) ),
- rcCalc,
- DT_SINGLELINE|DT_LEFT|DT_TOP|DT_CALCRECT
- );
- nMeasuredTextHeight += rcCalc.Height();
- }
- INT nRightPartSize =
- strCaptionText.GetLength() - nSepPos - 1;
- ASSERT( nRightPartSize >= 0 );
- if( nRightPartSize == 0 )
- break;
- strCaptionText = strCaptionText.Right( nRightPartSize );
- strCaptionText.TrimLeft( _T(" rt") );
- strCaptionText.TrimRight( _T(" rt") );
- if( strCaptionText.IsEmpty() )
- break;
- } // if( nSepPos >= 0 )
- else
- {
- strArray.Add( strCaptionText );
- CRect rcCalc( 0, 0, 0, 0 );
- dc.DrawText(
- LPCTSTR(strCaptionText),
- INT( _tcslen( LPCTSTR(strCaptionText) ) ),
- rcCalc,
- DT_SINGLELINE|DT_LEFT|DT_TOP|DT_CALCRECT
- );
- nMeasuredTextHeight += rcCalc.Height();
- break;
- } // else from if( nSepPos >= 0 )
- } // for( nPartIndex = 0; nPartIndex < nPartCount; nPartIndex ++ )
- } // if( ! strCaptionText.IsEmpty() )
- nPartCount = INT( strArray.GetSize() );
- static const POINT g_ptArrDist = { 2, 4 };
- CPoint ptArrow( 0, 0 );
- CSize _sizeArrow( 0, 0 );
- glyph_t * pGlyph = g_DockingCaptionGlyphs[ __DCBT_ARROW_DOWN ];
- if( bDrawDropDownArrow )
- {
- if( pBmpAlternativeDropDownArrow != NULL
- && (! pBmpAlternativeDropDownArrow->IsEmpty() )
- )
- _sizeArrow = pBmpAlternativeDropDownArrow->GetSize();
- else
- _sizeArrow = pGlyph->Size();
- } // if( bDrawDropDownArrow )
- CRect rcWalk = rcText;
- if( nPartCount <= 1
- && pHelperSrc != NULL
- && pHelperSrc->IsKindOf( RUNTIME_CLASS( CExtBarButton ) )
- && ((CExtBarButton*)pHelperSrc)->RibbonILV_Get() < __EXT_RIBBON_ILV_SIMPLE_LARGE
- )
- {
- CRect rcDraw = rcText;
- CRect rcArrow = rcDraw;
- if( nPartCount == 1 || bDrawDropDownArrow )
- {
- if( _sizeArrow.cx > 0
- && _sizeArrow.cy > 0
- )
- {
- rcDraw.right -= _sizeArrow.cx;
- rcArrow.left = rcDraw.right;
- if( pBmpAlternativeDropDownArrow != NULL
- && (! pBmpAlternativeDropDownArrow->IsEmpty() )
- )
- {
- rcArrow.left += ( rcArrow.Width() - _sizeArrow.cx ) / 2;
- rcArrow.top += ( rcArrow.Height() - _sizeArrow.cy ) / 2;
- rcArrow.right = rcArrow.left + _sizeArrow.cx;
- rcArrow.bottom = rcArrow.top + _sizeArrow.cy;
- if( nPartCount == 0 )
- rcArrow.OffsetRect( 0, 1 );
- // rcArrow.OffsetRect(
- // 0,
- // ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2
- // );
- pBmpAlternativeDropDownArrow->AlphaBlend( dc.m_hDC, rcArrow );
- }
- else
- {
- ptArrow.y -= 4;
- COLORREF ColorValues1[2] =
- {
- RGB(0,0,0),
- GetColor(COLOR_3DHILIGHT),
- };
- COLORREF ColorValues2[2] =
- {
- RGB(0,0,0),
- GetColor(COLOR_BTNTEXT),
- };
- if( nPartCount == 0 )
- {
- ptArrow.x += 3;
- ptArrow.y ++;
- }
- // ptArrow.y += ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2;
- ptArrow.y ++;
- PaintGlyphCentered( dc, rcArrow, *pGlyph, ColorValues1 );
- ptArrow.y --;
- PaintGlyphCentered( dc, rcArrow, *pGlyph, ColorValues2 );
- }
- }
- }
- if( nPartCount == 1 )
- {
- CExtSafeString & s = strArray.ElementAt( 0 );
- INT nLen = s.GetLength();
- ASSERT( nLen > 0 );
- // rcDraw.OffsetRect(
- // 0,
- // ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2
- // );
- dc.DrawText( LPCTSTR(s), nLen, rcDraw, nDrawTextFlags );
- }
- }
- else
- {
- nDrawTextFlags &= ~(DT_SINGLELINE);
- for( nPartIndex = 0; nPartIndex < nPartCount; nPartIndex ++ )
- {
- CExtSafeString & s = strArray.ElementAt( nPartIndex );
- INT nLen = s.GetLength();
- ASSERT( nLen > 0 );
- CRect rcCalc( 0, 0, 0, 0 );
- dc.DrawText( LPCTSTR(s), nLen, rcCalc, DT_SINGLELINE|DT_LEFT|DT_TOP|DT_CALCRECT );
- INT nTextHeight = rcCalc.Height();
- rcWalk.bottom = rcWalk.top + nTextHeight;
- CRect rcDraw = rcWalk;
- if( _sizeArrow.cx > 0
- && _sizeArrow.cy > 0
- && nPartCount > 1
- && nPartIndex == ( nPartCount - 1 )
- )
- {
- if( ( nDrawTextFlags & DT_CENTER ) != 0 )
- {
- INT nTextWidth = rcCalc.Width();
- rcDraw.left += ( rcWalk.Width() - nTextWidth - _sizeArrow.cx - g_ptArrDist.x ) / 2;
- rcDraw.right = rcDraw.left + nTextWidth;
- } // if( ( nDrawTextFlags & DT_CENTER ) != 0 )
- ptArrow.x = rcDraw.right + g_ptArrDist.x;
- ptArrow.y = rcWalk.top + ( nTextHeight - _sizeArrow.cy ) / 2;
- }
- // rcDraw.OffsetRect(
- // 0,
- // ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2
- // );
- dc.DrawText( LPCTSTR(s), nLen, rcDraw, nDrawTextFlags );
- rcWalk.OffsetRect( 0, nTextHeight );
- } // for( nPartIndex = 0; nPartIndex < nPartCount; nPartIndex ++ )
- if( _sizeArrow.cx > 0
- && _sizeArrow.cy > 0
- )
- {
- if( nPartCount <= 1 )
- {
- ptArrow.x = rcWalk.left + ( rcWalk.Width() - _sizeArrow.cx ) / 2;
- ptArrow.y = rcWalk.top + g_ptArrDist.y;
- }
- if( pBmpAlternativeDropDownArrow != NULL
- && (! pBmpAlternativeDropDownArrow->IsEmpty() )
- )
- {
- CRect rcArrow( ptArrow, _sizeArrow );
- // rcArrow.OffsetRect(
- // 0,
- // ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2
- // );
- pBmpAlternativeDropDownArrow->AlphaBlend( dc.m_hDC, rcArrow );
- }
- else
- {
- ptArrow.y -= 4;
- COLORREF ColorValues1[2] =
- {
- RGB(0,0,0),
- GetColor(COLOR_3DHILIGHT),
- };
- COLORREF ColorValues2[2] =
- {
- RGB(0,0,0),
- GetColor(COLOR_BTNTEXT),
- };
- // ptArrow.y += ( rcText.bottom - rcText.top - nMeasuredTextHeight ) / 2;
- ptArrow.y ++;
- PaintGlyph( dc, ptArrow, *pGlyph, ColorValues1 );
- ptArrow.y --;
- PaintGlyph( dc, ptArrow, *pGlyph, ColorValues2 );
- }
- }
- }
- }
- void CExtPaintManagerOffice2007_Impl::Ribbon_PaintText(
- CDC & dc,
- __EXT_MFC_SAFE_LPCTSTR strText,
- const RECT & rcText,
- UINT nDrawTextFlags,
- bool bDrawDropDownArrow,
- CExtBitmap * pBmpAlternativeDropDownArrow,
- CObject * pHelperSrc,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT( dc.GetSafeHdc() != NULL );
- if( IsHighContrast() )
- {
- CExtPaintManagerXP::Ribbon_PaintText(
- dc,
- strText,
- rcText,
- nDrawTextFlags,
- bDrawDropDownArrow,
- pBmpAlternativeDropDownArrow,
- pHelperSrc,
- lParam
- );
- return;
- }
- if( bDrawDropDownArrow
- && ( pBmpAlternativeDropDownArrow == NULL
- || pBmpAlternativeDropDownArrow->IsEmpty()
- )
- )
- pBmpAlternativeDropDownArrow = &m_bmpRibbonDDA;
- CExtPaintManager::Ribbon_PaintText(
- dc,
- strText,
- rcText,
- nDrawTextFlags,
- bDrawDropDownArrow,
- pBmpAlternativeDropDownArrow,
- pHelperSrc,
- lParam
- );
- }
- bool CExtPaintManager::Ribbon_PaintQuickAccessGroupButton(
- CDC & dc,
- const RECT & rcGroupBk,
- const CExtRibbonButtonGroup * pGroupTBB,
- LPARAM lParam // = 0L
- )
- {
- ASSERT_VALID( this );
- ASSERT( dc.GetSafeHdc() != NULL );
- dc;
- rcGroupBk;
- pGroupTBB;
- lParam;
- return false;
- }
- bool CExtPaintManagerOffice2007_Impl::Ribbon_PaintQuickAccessGroupButton(