mirror of
https://github.com/MultiMC/MultiMC5.git
synced 2024-12-26 00:15:16 +00:00
Use monospace font in the console.
Still fugly as all hell, now in a slightly more appropriate style.
This commit is contained in:
parent
c1f560d385
commit
dff00a6d2a
@ -58,10 +58,17 @@ ConsoleWindow::~ConsoleWindow()
|
||||
void ConsoleWindow::writeColor(QString text, const char *color)
|
||||
{
|
||||
// append a paragraph
|
||||
if (color != nullptr)
|
||||
ui->text->appendHtml(QString("<font color=\"%1\">%2</font>").arg(color).arg(text));
|
||||
else
|
||||
ui->text->appendPlainText(text);
|
||||
QString newtext;
|
||||
newtext += "<span style=\"";
|
||||
{
|
||||
if(color)
|
||||
newtext += QString("color:") + color + ";";
|
||||
newtext += "font-family: monospace;";
|
||||
}
|
||||
newtext += "\">";
|
||||
newtext += text.toHtmlEscaped();
|
||||
newtext += "</span>";
|
||||
ui->text->appendHtml(newtext);
|
||||
}
|
||||
|
||||
void ConsoleWindow::write(QString data, MessageLevel::Enum mode)
|
||||
|
@ -17,11 +17,6 @@
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QPlainTextEdit" name="text">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>10</pointsize>
|
||||
</font>
|
||||
</property>
|
||||
<property name="undoRedoEnabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
|
Loading…
Reference in New Issue
Block a user