本文整理汇总了C#中IVwEnv.AddIntProp方法的典型用法代码示例。如果您正苦于以下问题:C# IVwEnv.AddIntProp方法的具体用法?C# IVwEnv.AddIntProp怎么用?C# IVwEnv.AddIntProp使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IVwEnv
的用法示例。
在下文中一共展示了IVwEnv.AddIntProp方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: DisplayIterCtxt
void DisplayIterCtxt(IPhIterationContext iterCtxt, int numLines, IVwEnv vwenv)
{
int superOffset = 0;
if (numLines == 1)
{
// if the inner context is a single line, then make the min value a subscript and the max value a superscript.
// I tried to use the Views subscript and superscript properties, but they added extra space so that it would
// have the same line height of a normal character, which is not what I wanted, so I compute the size myself
int fontHeight = GetFontHeight(m_cache.DefaultUserWs);
int superSubHeight = (fontHeight * 2) / 3;
vwenv.set_IntProperty((int)FwTextPropType.ktptFontSize, (int)FwTextPropVar.ktpvMilliPoint, superSubHeight);
vwenv.set_IntProperty((int)FwTextPropType.ktptLineHeight, (int)FwTextPropVar.ktpvMilliPoint, -superSubHeight);
superOffset = superSubHeight / 2;
}
else
{
vwenv.set_IntProperty((int)FwTextPropType.ktptMarginTrailing, (int)FwTextPropVar.ktpvMilliPoint, PILE_MARGIN);
}
vwenv.OpenInnerPile();
if (numLines == 1)
vwenv.set_IntProperty((int)FwTextPropType.ktptOffset, (int)FwTextPropVar.ktpvMilliPoint, superOffset);
vwenv.OpenParagraph();
vwenv.AddProp(PhIterationContextTags.kflidMaximum, this, kfragIterCtxtMax);
vwenv.CloseParagraph();
AddExtraLines(numLines - 2, vwenv);
vwenv.set_IntProperty((int)FwTextPropType.ktptOffset, (int)FwTextPropVar.ktpvMilliPoint, 0);
vwenv.OpenParagraph();
vwenv.AddIntProp(PhIterationContextTags.kflidMinimum);
vwenv.CloseParagraph();
vwenv.CloseInnerPile();
}