anthon
15th August 2010, 16:11
Hi
I'm using QSettings to parse an INI formated file generated by an external application. The groups in that file are all MAC adresses, like [XX:XX:XX:XX].
Reading this file with QSettings works great. Now I want to do some modifications in that file. The problem is, when QSettings writes in it, it replaces all ":"(colon) in the groups name by the code "%3A". However, colons in values fields are written properly so this is not strictly an encoding issue (besides I tried using "setIniCodec", it didn't help).
Example:
[XX:XX:XX:XX:XX:XX]
value=a:b:c:d:e:f
becomes
[XX%3AXX%3AXX%3AXX%3AXX%3AXX]
value=a:b:c:d:e:f
Does anyone know how to fix it? Or maybe with a different approach than QSettings?
Thanks.
I'm using QSettings to parse an INI formated file generated by an external application. The groups in that file are all MAC adresses, like [XX:XX:XX:XX].
Reading this file with QSettings works great. Now I want to do some modifications in that file. The problem is, when QSettings writes in it, it replaces all ":"(colon) in the groups name by the code "%3A". However, colons in values fields are written properly so this is not strictly an encoding issue (besides I tried using "setIniCodec", it didn't help).
Example:
[XX:XX:XX:XX:XX:XX]
value=a:b:c:d:e:f
becomes
[XX%3AXX%3AXX%3AXX%3AXX%3AXX]
value=a:b:c:d:e:f
Does anyone know how to fix it? Or maybe with a different approach than QSettings?
Thanks.