forked from qt-creator/qt-creator
Added tooltips on completions proposals
Change-Id: Ic22b99e25159edfa4977e13c98f334ce75809af7 Reviewed-by: Orgad Shaneh <orgads@gmail.com> Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
This commit is contained in:
committed by
Eike Ziller
parent
f43c02d12f
commit
edabcb40fa
@@ -536,7 +536,10 @@ public:
|
||||
ConvertToCompletionItem()
|
||||
: _item(0)
|
||||
, _symbol(0)
|
||||
{ }
|
||||
{
|
||||
overview.setShowReturnTypes(true);
|
||||
overview.setShowArgumentNames(true);
|
||||
}
|
||||
|
||||
BasicProposalItem *operator()(Symbol *symbol)
|
||||
{
|
||||
@@ -575,7 +578,12 @@ protected:
|
||||
}
|
||||
|
||||
virtual void visit(const Identifier *name)
|
||||
{ _item = newCompletionItem(name); }
|
||||
{
|
||||
_item = newCompletionItem(name);
|
||||
if (!_symbol->isScope() || _symbol->isFunction()) {
|
||||
_item->setDetail(overview.prettyType(_symbol->type(), name));
|
||||
}
|
||||
}
|
||||
|
||||
virtual void visit(const TemplateNameId *name)
|
||||
{
|
||||
@@ -587,7 +595,10 @@ protected:
|
||||
{ _item = newCompletionItem(name); }
|
||||
|
||||
virtual void visit(const OperatorNameId *name)
|
||||
{ _item = newCompletionItem(name); }
|
||||
{
|
||||
_item = newCompletionItem(name);
|
||||
_item->setDetail(overview.prettyType(_symbol->type(), name));
|
||||
}
|
||||
|
||||
virtual void visit(const ConversionNameId *name)
|
||||
{ _item = newCompletionItem(name); }
|
||||
|
||||
Reference in New Issue
Block a user