Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 7

Qt-interest Archive, August 2006
Simulating deprecated QSettings::resetGroup() [Qt 4.x]


Message 1 in thread

In Qt3 QSettings had a resetGroup() method which would blast
you back to the settings "root" without you having to know
how deeply-nested in groups you were.

resetGroup() is now a Qt3 support function.  What's the Qt4
equivalent?  The docs say "use endGroup() (perhaps multiple
times)".  But what if you don't know how deep you are and just
want to get back to the "root" level?

Can you just call endGroup() in a loop until group().isEmpty()
return true?

Or is there a more convenient way to do it?  And why did TT
do away with resetGroup(), anyway?

== Rich Carreiro

--
 [ signature omitted ]