@@ -462,13 +462,19 @@ void RPCConsole::clear()
462462 }
463463
464464 // Set default style sheet
465+ QFontInfo fixedFontInfo (GUIUtil::fixedPitchFont ());
466+ // Try to make fixed font adequately large on different OS
467+ QString ptSize = QString (" %1pt" ).arg (QFontInfo (QFont ()).pointSize () * 8.5 / 9 );
465468 ui->messagesWidget ->document ()->setDefaultStyleSheet (
469+ QString (
466470 " table { }"
467471 " td.time { color: #808080; padding-top: 3px; } "
472+ " td.message { font-family: %1; font-size: %2; white-space:pre-wrap; } "
468473 " td.cmd-request { color: #006060; } "
469474 " td.cmd-error { color: red; } "
470475 " b { color: #006060; } "
471- );
476+ ).arg (fixedFontInfo.family (), ptSize)
477+ );
472478
473479 message (CMD_REPLY, (tr (" Welcome to the Bitcoin Core RPC console." ) + " <br>" +
474480 tr (" Use up and down arrows to navigate history, and <b>Ctrl-L</b> to clear screen." ) + " <br>" +
@@ -494,7 +500,7 @@ void RPCConsole::message(int category, const QString &message, bool html)
494500 if (html)
495501 out += message;
496502 else
497- out += GUIUtil::HtmlEscape (message, true );
503+ out += GUIUtil::HtmlEscape (message, false );
498504 out += " </td></tr></table>" ;
499505 ui->messagesWidget ->append (out);
500506}
@@ -849,4 +855,4 @@ void RPCConsole::showOrHideBanTableIfRequired()
849855 bool visible = clientModel->getBanTableModel ()->shouldShow ();
850856 ui->banlistWidget ->setVisible (visible);
851857 ui->banHeading ->setVisible (visible);
852- }
858+ }
0 commit comments