diff options
author | Thorbjørn Lindeijer <thorbjorn.lindeijer@nokia.com> | 2010-04-15 19:07:05 +0200 |
---|---|---|
committer | Thorbjørn Lindeijer <thorbjorn.lindeijer@nokia.com> | 2010-04-15 19:16:37 +0200 |
commit | 01a0ec161cf5e814b53151a040afc2ac1acd69f8 (patch) | |
tree | 6dcc4b6e673767c05b0c7186bb1a0379c60361fc /src/plugins/cppeditor/cpphoverhandler.cpp | |
parent | 02ebee6d23eaea537b571a56d51876c33b942565 (diff) | |
download | qt-creator-01a0ec161cf5e814b53151a040afc2ac1acd69f8.tar.gz |
Fixed unwanted wrapping of code editor tooltips
Turns out the <nobr> actually caused wrapping in some cases because the
tag made the QToolTip turn on its wrapping feature due to the text being
rich text. So avoid adding it to plain text tooltips unnecessarily.
Reviewed-by: hunger
Task-number: QTCREATORBUG-1169
Diffstat (limited to 'src/plugins/cppeditor/cpphoverhandler.cpp')
-rw-r--r-- | src/plugins/cppeditor/cpphoverhandler.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/cppeditor/cpphoverhandler.cpp b/src/plugins/cppeditor/cpphoverhandler.cpp index a4fd089c6a..a2e270b3e1 100644 --- a/src/plugins/cppeditor/cpphoverhandler.cpp +++ b/src/plugins/cppeditor/cpphoverhandler.cpp @@ -427,7 +427,7 @@ void CppHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in .arg(m_toolTip); } editor->setContextHelpId(m_helpId); - } else if (!m_toolTip.isEmpty()) { + } else if (!m_toolTip.isEmpty() && Qt::mightBeRichText(m_toolTip)) { m_toolTip = QString(QLatin1String("<nobr>%1")).arg(m_toolTip); } } |