Version: (using KDE KDE 3.1) Installed from: Mandrake RPMs OS: Linux I Can't assign an icon to files like *README*. For example, all my *.cpp files have a particular icon. I assigned a particular icon to all files that end in *.cpp. But, if I do the same for all the files that contains README by typing *README*, it doesn't work. *README and README* work, but not *README*.
Subject: kdelibs/kdecore CVS commit by aseigo: allow matching patterns such as *README* CCMAIL:60724-done@bugs.kde.org M +5 -0 kstringhandler.cpp 1.26 --- kdelibs/kdecore/kstringhandler.cpp #1.25:1.26 @@ -509,4 +509,9 @@ bool KStringHandler::matchFileName( cons // Patterns like "Makefile*" if ( pattern[ pattern_len - 1 ] == '*' && len + 1 >= pattern_len ) { + if ( pattern[ 0 ] == '*' ) + { + return filename.find(pattern.mid(1, pattern_len - 2)) != -1; + } + const QChar *c1 = pattern.unicode(); const QChar *c2 = filename.unicode();