]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Make details column text readable
authorFelix Ernst <fe.a.ernst@gmail.com>
Wed, 19 Oct 2022 17:04:39 +0000 (19:04 +0200)
committerFelix Ernst <felixernst@kde.org>
Thu, 27 Oct 2022 09:40:03 +0000 (09:40 +0000)
When not using the full row highlight, the text of non-name columns
in details view mode was wrongly colored in a way that pretended
that the full row selection highlight was active.

When it isn't active we use the normal color that we generally use
when the additional information is not within the selection
highlight.

src/kitemviews/kstandarditemlistwidget.cpp

index 67afbb248f7d9c26ef4e87d162227a9b01a6e74c..ddc7c298811e7d57820483c7163ae601855e499a 100644 (file)
@@ -1456,7 +1456,7 @@ void KStandardItemListWidget::updateAdditionalInfoTextColor()
     QColor c1;
     if (m_customTextColor.isValid()) {
         c1 = m_customTextColor;
-    } else if (isSelected()) {
+    } else if (isSelected() && (m_layout != DetailsLayout || m_highlightEntireRow)) {
         // The detail text colour needs to match the main text (HighlightedText) for the same level
         // of readability. We short circuit early here to avoid interpolating with another colour.
         m_additionalInfoTextColor = styleOption().palette.color(QPalette::HighlightedText);