I'm not sure if you really can parse a specific ini file with QSettings (you could try playing with QSettings::setPath).
If that doesn't work, take a look at QConfFileSettingsPrivate::readIniFile() in src/corelib/io/qsettings.cpp.
I'm not sure if you really can parse a specific ini file with QSettings (you could try playing with QSettings::setPath).
If that doesn't work, take a look at QConfFileSettingsPrivate::readIniFile() in src/corelib/io/qsettings.cpp.
J-P Nurmi
Why not? The file format is similar as how QSettings would store it, right?Originally Posted by jpn
Why can't i find this path on my installation (Suse 10)???If that doesn't work, take a look at QConfFileSettingsPrivate::readIniFile() in src/corelib/io/qsettings.cpp.
Thanks.
My mistake. The format is no problem at all. But I thought that QSettings would possibly do some assumptions about the path, eg. it's restricted to either $HOME/.config (user scope) or /etc/xdg (system scope) in *nix so you couldn't parse whichever file you want. But that seems not to be the case.Originally Posted by nupul
Qt Code:
settings.beginGroup("Desktop Entry");To copy to clipboard, switch view to plain text mode
J-P Nurmi
nupul (10th April 2006)
http://www.qtcentre.org/forum/showth...=9856#post9856Originally Posted by nupul
J-P Nurmi
Which implies that it is always preferable to use QSettings for such files, right?
As the code you put forth is simpler and more elegant than using Qfile and Qtextstream and splitting the string on '='
Thanks buddy!
Bookmarks