SVN commit 933397 by mjansen: Implement a improvement for group.exists() returning false for groups without content (see kconfigtest). This change only solves my current problem. The real solution is much more complicated. M +12 -1 kconfig.cpp --- trunk/KDE/kdelibs/kdecore/config/kconfig.cpp #933396:933397 @@ -684,7 +684,18 @@ bool KConfig::hasGroupImpl(const QByteArray& aGroup) const { Q_D(const KConfig); - return d->entryMap.hasEntry(aGroup); + + if (d->entryMap.hasEntry(aGroup)) return true; + + QByteArray subGroupMarker = aGroup + '\x1d'; + // Because this group could have only subgroups but no entries we have to + // search for group markers + for (KEntryMap::ConstIterator entryMapIt( d->entryMap.constBegin() ); entryMapIt != d->entryMap.constEnd(); ++entryMapIt) { + if (entryMapIt.key().mGroup.startsWith(subGroupMarker)) { + return true; + } + } + return false; } bool KConfigPrivate::canWriteEntry(const QByteArray& group, const char* key, bool isDefault) const