Use the same link color consistently in frontend
authorWuzzy <almikes@aol.com>
Mon, 10 Apr 2017 23:32:03 +0200
changeset 12220 a7c08e4748ff
parent 12219 072ece492a65
child 12221 c6034081cac2
Use the same link color consistently in frontend
QTfrontend/hwform.cpp
QTfrontend/ui/widget/about.cpp
--- a/QTfrontend/hwform.cpp	Mon Apr 10 23:10:56 2017 +0200
+++ b/QTfrontend/hwform.cpp	Mon Apr 10 23:32:03 2017 +0200
@@ -411,6 +411,7 @@
 
 void HWForm::CustomizePalettes()
 {
+    // Scroll bar widget palette
     QList<QScrollBar *> allSBars = findChildren<QScrollBar *>();
     QPalette pal = palette();
     pal.setColor(QPalette::WindowText, QColor(0xff, 0xcc, 0x00));
@@ -420,6 +421,11 @@
 
     for (int i = 0; i < allSBars.size(); ++i)
         allSBars.at(i)->setPalette(pal);
+
+    // Set default hyperlink color
+    QPalette appPal = qApp->palette();
+    appPal.setColor(QPalette::Link, QColor(0xff, 0xff, 0x6e));
+    qApp->setPalette(appPal);
 }
 
 void HWForm::UpdateWeapons()
--- a/QTfrontend/ui/widget/about.cpp	Mon Apr 10 23:10:56 2017 +0200
+++ b/QTfrontend/ui/widget/about.cpp	Mon Apr 10 23:32:03 2017 +0200
@@ -71,10 +71,6 @@
     QLabel *lbl1 = new QLabel(this);
     lbl1->setOpenExternalLinks(true);
     lbl1->setText(
-        "<style type=\"text/css\">"
-        "a { color: #ffcc00; }"
-//            "a:hover { color: yellow; }"
-        "</style>"
         //: %1 contains Hedgewars' version number
         "<div align=\"center\"><h1>"+QString(tr("Hedgewars %1")).arg(*cVersionString) + "</h1>"
         //: “Revision” stands for a revision in Mercurial, a distributed version control system. %1 is the revision, %2 is the hexadecimal hash.
@@ -100,9 +96,8 @@
 
     /* Library information */
 
-    QString libinfo = "<style type=text/css>a:link { color: #FFFF6E; }</style>";
     //: For the version numbers of Hedgewars' software dependencies
-    libinfo.append(QString(tr("Dependency versions:") + QString("<br>")));
+    QString libinfo = QString(tr("Dependency versions:") + QString("<br>"));
 
 #ifdef __GNUC__
     libinfo.append(QString(tr("<a href=\"http://gcc.gnu.org\">GCC</a>: %1")).arg(__VERSION__));