本文整理汇总了C#中SIL.FieldWorks.FDO.FdoCache.MakeAnalysisTss方法的典型用法代码示例。如果您正苦于以下问题:C# FdoCache.MakeAnalysisTss方法的具体用法?C# FdoCache.MakeAnalysisTss怎么用?C# FdoCache.MakeAnalysisTss使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SIL.FieldWorks.FDO.FdoCache
的用法示例。
在下文中一共展示了FdoCache.MakeAnalysisTss方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SetDlgInfo
/// <summary>
/// Initialize an InsertEntryDlg from something like an "Insert Major Entry menu".
/// </summary>
/// <param name="cache">The FDO cache to use.</param>
/// <param name="tssForm">The initial form to use.</param>
/// <param name="mediator">The XCore.Mediator to use.</param>
public void SetDlgInfo(FdoCache cache, ITsString tssForm, Mediator mediator)
{
CheckDisposed();
m_mediator = mediator;
if (m_types == null)
m_types = new MoMorphTypeCollection(cache);
string form = tssForm.Text;
int clsidForm;
IMoMorphType mmt;
// Check whether the incoming form is vernacular or analysis.
// (See LT-4074 and LT-7240.)
int wsForm;
bool fVern = IsFormWsInCurrentVernWs(cache, tssForm, out wsForm);
// If form is empty (cf. LT-1621), use stem
if (tssForm.Length == 0 || !fVern)
mmt = m_types.Item(MoMorphType.kmtStem);
else
mmt = MoMorphType.FindMorphType(cache, m_types, ref form, out clsidForm);
int wsVern = fVern ? wsForm : cache.DefaultVernWs;
SetDlgInfo(cache, mmt, wsVern, MorphTypeFilterType.any);
if (fVern)
{
TssForm = tssForm;
TssGloss = cache.MakeAnalysisTss("");
// The lexical form is already set, so shift focus to the gloss when
// the form is activated.
m_fLexicalFormInitialFocus = false;
}
else
{
TssForm = cache.MakeVernTss("");
TssGloss = tssForm;
// The gloss is already set, so shift the focus to the lexical form
// when the form is activated.
m_fLexicalFormInitialFocus = m_fLexicalFormChanged = true;
}
UpdateMatches();
}