当前位置: 首页>>代码示例>>C++>>正文


C++ CBCGPRibbonBar::EnablePrintPreview方法代码示例

本文整理汇总了C++中CBCGPRibbonBar::EnablePrintPreview方法的典型用法代码示例。如果您正苦于以下问题:C++ CBCGPRibbonBar::EnablePrintPreview方法的具体用法?C++ CBCGPRibbonBar::EnablePrintPreview怎么用?C++ CBCGPRibbonBar::EnablePrintPreview使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CBCGPRibbonBar的用法示例。


在下文中一共展示了CBCGPRibbonBar::EnablePrintPreview方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: ConstructRibbonBar

void CBCGPRibbonConstructor::ConstructRibbonBar (CBCGPRibbonBar& bar) const
{
	const CBCGPRibbonInfo::XRibbonBar& infoBar = GetInfo ().GetRibbonBar ();

	CBCGPRibbonPanel::m_nNextPanelID = (UINT)-10;

	bar.m_VersionStamp = GetInfo ().GetVersionStamp ();
	bar.EnableToolTips     (infoBar.m_bToolTip, infoBar.m_bToolTipDescr);
	bar.EnableKeyTips      (infoBar.m_bKeyTips);
	bar.EnablePrintPreview (infoBar.m_bPrintPreview);
	bar.SetBackstageMode   (infoBar.m_bBackstageMode);

	CBCGPRibbonFontComboBox::m_bDrawUsingFont = infoBar.m_bDrawUsingFont;

	const_cast<CBCGPToolBarImages&>(infoBar.m_Images.m_Image).CopyTo (bar.m_PanelIcons);

	if (infoBar.m_btnMain != NULL)
	{
		CBCGPRibbonMainButton* btnMain = bar.GetMainButton ();
		if (btnMain == NULL)
		{
			btnMain = CreateMainButton (bar);
		}

		if (btnMain != NULL)
		{
			ConstructElement (*btnMain, *infoBar.m_btnMain);
		}
	}

	if (infoBar.m_MainCategory != NULL)
	{
		ConstructCategoryMain (bar, *infoBar.m_MainCategory);
	}

	if (infoBar.m_BackstageCategory != NULL)
	{
		ConstructCategoryBackstage (bar, *infoBar.m_BackstageCategory);
	}

	ConstructTabElements (bar, infoBar);

	int i = 0;
	for (i = 0; i < infoBar.m_arCategories.GetSize (); i++)
	{
		const CBCGPRibbonInfo::XCategory& infoCategory = 
			*(const CBCGPRibbonInfo::XCategory*)infoBar.m_arCategories[i];

		CBCGPRibbonCategory* pCategory = CreateCategory (bar, infoCategory);
		if (pCategory != NULL)
		{
			ASSERT_VALID (pCategory);
			ConstructCategory (*pCategory, infoCategory);
		}
	}

	for (i = 0; i < infoBar.m_arContexts.GetSize (); i++)
	{
		const CBCGPRibbonInfo::XContext* context = infoBar.m_arContexts[i];
		for (int j = 0; j < context->m_arCategories.GetSize (); j++)
		{
			const CBCGPRibbonInfo::XCategory& infoCategory = 
				*(const CBCGPRibbonInfo::XCategory*)context->m_arCategories[j];

			CBCGPRibbonCategory* pCategory = CreateCategoryContext (bar, *context, infoCategory);
			if (pCategory != NULL)
			{
				ASSERT_VALID (pCategory);
				ConstructCategory (*pCategory, infoCategory);
			}
		}
	}

	ConstructQATElements (bar, infoBar);
}
开发者ID:iclosure,项目名称:jframework,代码行数:75,代码来源:BCGPRibbonConstructor.cpp


注:本文中的CBCGPRibbonBar::EnablePrintPreview方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。