1
0
Fork 0

fixed mnemonic brief not shown

This commit is contained in:
torusrxxx 2022-01-21 16:44:38 +08:00
parent e2f3c4a26e
commit 2d78e115fe
No known key found for this signature in database
GPG Key ID: A795C73A0F1CFADD
1 changed files with 5 additions and 4 deletions

View File

@ -537,6 +537,7 @@ QString Disassembly::paintContent(QPainter* painter, dsint rowBase, int rowOffse
funcType = Function_end;
break;
}
RichTextPainter::List richText;
int argsize = funcType == Function_none ? 3 : paintFunctionGraphic(painter, x, y, funcType, false);
RichTextPainter::CustomRichText_t richComment;
@ -562,17 +563,16 @@ QString Disassembly::paintContent(QPainter* painter, dsint rowBase, int rowOffse
}
richComment.text = std::move(comment);
richText.emplace_back(std::move(richComment));
}
else if(DbgGetLabelAt(cur_addr, SEG_DEFAULT, label)) // label but no comment
{
richComment.textColor = mLabelColor;
richComment.textBackground = mLabelBackgroundColor;
richComment.text = label;
richText.emplace_back(std::move(richComment));
}
RichTextPainter::List richText;
richText.emplace_back(std::move(richComment));
if(mShowMnemonicBrief)
{
RichTextPainter::CustomRichText_t richBrief;
@ -606,7 +606,8 @@ QString Disassembly::paintContent(QPainter* painter, dsint rowBase, int rowOffse
space.underline = false;
space.flags = RichTextPainter::FlagNone;
space.text = " ";
richText.emplace_back(std::move(space));
if(richText.size())
richText.emplace_back(std::move(space));
richBrief.text = std::move(mnemBrief);