From 5e185ed50df75ff647490cae43094fa54886c13f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Mal=C3=BD?= Date: Tue, 8 Oct 2019 15:56:50 +0200 Subject: Force white background in SrcEditor --- qtmips_gui/srceditor.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'qtmips_gui/srceditor.cpp') diff --git a/qtmips_gui/srceditor.cpp b/qtmips_gui/srceditor.cpp index 2d4a5ec..aaed0f2 100644 --- a/qtmips_gui/srceditor.cpp +++ b/qtmips_gui/srceditor.cpp @@ -35,6 +35,7 @@ #include #include +#include #include #include #include @@ -52,6 +53,12 @@ void SrcEditor::setup_common() { setFont(font); tname = "Unknown"; highlighter = new HighlighterAsm(document()); + + QPalette p = palette(); + p.setColor(QPalette::Active, QPalette::Base, Qt::white); + p.setColor(QPalette::Inactive, QPalette::Base, Qt::white); + p.setColor(QPalette::Disabled, QPalette::Base, Qt::white); + setPalette(p); } SrcEditor::SrcEditor(QWidget *parent) : Super(parent) { -- cgit v1.2.3 From ef2279d14d7ef20a3bc32020215ddb6b3f99a9d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20Mal=C3=BD?= Date: Tue, 8 Oct 2019 16:00:01 +0200 Subject: Force black text in SrcEditor --- qtmips_gui/srceditor.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'qtmips_gui/srceditor.cpp') diff --git a/qtmips_gui/srceditor.cpp b/qtmips_gui/srceditor.cpp index aaed0f2..43e9075 100644 --- a/qtmips_gui/srceditor.cpp +++ b/qtmips_gui/srceditor.cpp @@ -59,6 +59,8 @@ void SrcEditor::setup_common() { p.setColor(QPalette::Inactive, QPalette::Base, Qt::white); p.setColor(QPalette::Disabled, QPalette::Base, Qt::white); setPalette(p); + + setTextColor(Qt::black); } SrcEditor::SrcEditor(QWidget *parent) : Super(parent) { -- cgit v1.2.3