Version: 3.1.0 (using KDE 3.1.9) Compiler: gcc version 2.95.3 20010315 (SuSE) OS: Linux (i686) release 2.4.18-SMP With the file-manager i have set the bgcolor to black and the text color to white. When renaming the files, i don't see the filename, because both text and background have the same color. greetings, Stephan
CVS commit by pletourn: Fix text color for rename lineedit Cleanups CCMAIL: 51940-done@bugs.kde.org M +5 -28 konq_propsview.cc 1.85 --- kdebase/libkonq/konq_propsview.cc #1.84:1.85 @@ -19,4 +19,5 @@ #include "konq_propsview.h" +#include "konq_settings.h" #include <kdebug.h> @@ -109,5 +110,6 @@ KonqPropsView::KonqPropsView( KInstance d->previewsEnabled = config->readBoolEntry( "PreviewsEnabled", true ); - m_textColor = config->readColorEntry( "TextColor" ); // will be set to QColor() if not found + QColor tc = KonqFMSettings::settings()->normalTextColor(); + m_textColor = config->readColorEntry( "TextColor", &tc ); m_bgColor = config->readColorEntry( "BgColor" ); // will be set to QColor() if not found m_bgPixmapFile = config->readPathEntry( "BgImage" ); @@ -536,36 +538,11 @@ QPixmap KonqPropsView::loadPixmap() cons void KonqPropsView::applyColors(QWidget * widget) const { - //kdDebug(1203) << "KonqPropsView::applyColors " << (void*)this << endl; - QColorGroup a = widget->palette().active(); - QColorGroup d = widget->palette().disabled(); // is this one ever used ? - QColorGroup i = widget->palette().inactive(); // is this one ever used ? - bool setPaletteNeeded = false; - if ( m_bgPixmapFile.isEmpty() ) - { - QColor col = bgColor(widget); - a.setColor( QColorGroup::Base, col ); - d.setColor( QColorGroup::Base, col ); - i.setColor( QColorGroup::Base, col ); - widget->setBackgroundColor( col ); - setPaletteNeeded = true; - } + widget->setPaletteBackgroundColor( bgColor( widget ) ); else - { widget->setPaletteBackgroundPixmap( loadPixmap() ); - } if ( m_textColor.isValid() ) - { - a.setColor( QColorGroup::Text, m_textColor ); - d.setColor( QColorGroup::Text, m_textColor ); - i.setColor( QColorGroup::Text, m_textColor ); - setPaletteNeeded = true; - } - - // Avoid calling setPalette if we are fine with the default values. - // This makes us react to the palette-change event accordingly. - if ( setPaletteNeeded ) - widget->setPalette( QPalette( a, d, i ) ); + widget->setPaletteForegroundColor( m_textColor ); }