Skip to content

Commit

Permalink
Merge pull request bitcoin#7214
Browse files Browse the repository at this point in the history
fa2f4bc qt5: Use the fixed font the system recommends (MarcoFalke)
  • Loading branch information
jonasschnelli committed Dec 23, 2015
2 parents 97d8373 + fa2f4bc commit be9a9a3
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/qt/guiutil.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@
#include <QUrlQuery>
#endif

#if QT_VERSION >= 0x50200
#include <QFontDatabase>
#endif

#if BOOST_FILESYSTEM_VERSION >= 3
static boost::filesystem::detail::utf8_codecvt_facet utf8;
#endif
Expand Down Expand Up @@ -90,13 +94,17 @@ QString dateTimeStr(qint64 nTime)

QFont fixedPitchFont()
{
#if QT_VERSION >= 0x50200
return QFontDatabase::systemFont(QFontDatabase::FixedFont);
#else
QFont font("Monospace");
#if QT_VERSION >= 0x040800
font.setStyleHint(QFont::Monospace);
#else
font.setStyleHint(QFont::TypeWriter);
#endif
return font;
#endif
}

void setupAddressWidget(QValidatedLineEdit *widget, QWidget *parent)
Expand Down

0 comments on commit be9a9a3

Please sign in to comment.