本文整理汇总了C++中JXWindow::GetTitle方法的典型用法代码示例。如果您正苦于以下问题:C++ JXWindow::GetTitle方法的具体用法?C++ JXWindow::GetTitle怎么用?C++ JXWindow::GetTitle使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类JXWindow
的用法示例。
在下文中一共展示了JXWindow::GetTitle方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: if
//.........这里部分代码省略.........
// in front of 1 or 2 trailing newlines
CBTextEditor* te = GetTextEditor();
te->SetCaretLocation(te->GetTextLength() - (theDoubleSpaceFlag ? 1 : 0));
te->Paste(s);
}
else if (!isJavacError && !isGCCError &&
gccErrorRegex.Match(itsPrevLine, &gccPrevLineRange) &&
text->BeginsWith(gccMultilinePrefix) &&
text->GetLength() > kGCCMultilinePrefixLength &&
!isspace(text->GetCharacter(kGCCMultilinePrefixLength+1)))
{
JString s = *text;
s.RemoveSubstring(1, strlen(gccMultilinePrefix));
CBTextEditor* te = GetTextEditor();
te->SetCaretLocation(te->GetTextLength() - (theDoubleSpaceFlag ? 1 : 0));
te->Paste(s);
}
else
{
CBTextEditor* te = GetTextEditor();
const JIndex startIndex = te->GetTextLength() + 1;
CBExecOutputDocument::AppendText(*text);
if (theDoubleSpaceFlag)
{
te->Paste("\n");
}
itsPrevLine = *text;
// display file name in bold and activate Errors menu
JIndexRange boldRange;
if (isJavacError)
{
JArray<JIndexRange> javacMatchList;
if (javacErrorRegex.Match(*text, &javacMatchList))
{
const JIndexRange r = javacMatchList.GetElement(2);
boldRange.Set(startIndex + r.first-1, startIndex + r.last-1);
}
}
else if (isGCCError)
{
boldRange.Set(startIndex, startIndex + gccRange.first - 1);
}
else if (isFlexError)
{
boldRange.Set(startIndex+1, startIndex + flexRange.first);
}
else if (isBisonError)
{
boldRange.Set(startIndex+2, startIndex + bisonRange.first + 1);
}
else if (isMakeError)
{
boldRange.SetFirstAndLength(startIndex, text->GetLength());
}
else if (isAbsoftError)
{
boldRange = absoftRangeList.GetElement(2);
boldRange += startIndex-1;
}
else if (isMaven2Error)
{
boldRange = maven2RangeList.GetElement(2);
boldRange += startIndex-1;
}
else if (isMaven3Error)
{
boldRange = maven3RangeList.GetElement(2);
boldRange += startIndex-1;
}
if (!boldRange.IsEmpty())
{
te->JTextEditor::SetFont(boldRange.first, boldRange.last, GetErrorFont(), kJTrue);
if (!itsHasErrorsFlag)
{
itsHasErrorsFlag = kJTrue;
itsErrorMenu->Activate();
JXWindow* window = GetWindow();
JString windowTitle = window->GetTitle();
windowTitle.SetCharacter(1, '!');
windowTitle.SetCharacter(2, '!');
windowTitle.SetCharacter(3, '!');
window->SetTitle(windowTitle);
}
}
}
if (deleteText)
{
jdelete text;
}
}