diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2012-05-10 23:54:53 -0700 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2012-05-10 23:54:53 -0700 |
commit | b8a5e30d9136673163555615e17098c07b4c821f (patch) | |
tree | ffcb6685a887564859e1deae822af46f6b30c5d2 /src/qt/bitcoingui.cpp | |
parent | f93727aa56d9c38fdaebe7caa227188772ba4ac5 (diff) | |
parent | 3793fa09ff920fc720dfad3738f105d2c9563662 (diff) |
Merge pull request #1090 from laanwj/2012_04_wraptooltips
Allow Qt to wrap long tooltips (fixes #1063)
Diffstat (limited to 'src/qt/bitcoingui.cpp')
-rw-r--r-- | src/qt/bitcoingui.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index 91363a6ee0..e6f8aec755 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -563,22 +563,25 @@ void BitcoinGUI::setNumBlocks(int count) // Set icon state: spinning if catching up, tick otherwise if(secs < 90*60 && count >= nTotalBlocks) { - tooltip = tr("Up to date") + QString(".\n") + tooltip; + tooltip = tr("Up to date") + QString(".<br>") + tooltip; labelBlocksIcon->setPixmap(QIcon(":/icons/synced").pixmap(STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE)); } else { - tooltip = tr("Catching up...") + QString("\n") + tooltip; + tooltip = tr("Catching up...") + QString("<br>") + tooltip; labelBlocksIcon->setMovie(syncIconMovie); syncIconMovie->start(); } if(!text.isEmpty()) { - tooltip += QString("\n"); + tooltip += QString("<br>"); tooltip += tr("Last received block was generated %1.").arg(text); } + // Don't word-wrap this (fixed-width) tooltip + tooltip = QString("<nobr>") + tooltip + QString("</nobr>"); + labelBlocksIcon->setToolTip(tooltip); progressBarLabel->setToolTip(tooltip); progressBar->setToolTip(tooltip); |