本文整理汇总了C++中SmartPointer::FirstKey方法的典型用法代码示例。如果您正苦于以下问题:C++ SmartPointer::FirstKey方法的具体用法?C++ SmartPointer::FirstKey怎么用?C++ SmartPointer::FirstKey使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SmartPointer
的用法示例。
在下文中一共展示了SmartPointer::FirstKey方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SessionWrapper
void
InverseSearchOptionsPage::CollectEditors ()
{
string program;
string arguments;
/// free editors
if (MakeXEmacsCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("XEmacs"), program, arguments));
}
if (MakeNTEmacsCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("NTEmacs"), program, arguments));
}
if (MakeNTEmacsClientCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("NTEmacs (Single Instance)"),
program,
arguments));
}
if (MakeTeXnicCenterCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("TeXnicCenter"), program, arguments));
}
if (MakeVisualTeXCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("Visual TeX"), program, arguments));
}
/// non-free editors
if (MakeWinEdtCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("WinEdt"), program, arguments));
}
if (MakeLaTeXMngCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("LaTeXMng"), program, arguments));
}
if (MakeWinTeXXPCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("WinTeX XP"), program, arguments));
}
if (MakeWinShellCommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("WinShell"), program, arguments));
}
if (MakeLaTeXWIDECommandLine(program, arguments))
{
editors.push_back (EditorInfo(T_("LaTeX WIDE"), program, arguments));
}
/// user-defined
firstCustomIdx = static_cast<int>(editors.size());
for (unsigned r = SessionWrapper(true)->GetNumberOfTEXMFRoots();
r > 0;
-- r)
{
PathName editorsIni = SessionWrapper(true)->GetRootDirectory(r - 1);
editorsIni += MIKTEX_PATH_EDITORS_INI;
if (File::Exists(editorsIni))
{
SmartPointer<Cfg> pCfg (Cfg::Create());
pCfg->Read (editorsIni);
char szName[BufferSizes::MaxCfgName];
for (char * lpszName =
pCfg->FirstKey(szName, BufferSizes::MaxCfgName);
lpszName != 0;
lpszName = pCfg->NextKey(szName, BufferSizes::MaxCfgName))
{
editors.push_back
(EditorInfo(lpszName,
pCfg->GetValue(lpszName, T_("program")),
pCfg->GetValue(lpszName, T_("arguments"))));
}
}
}
}