On Fri, Jun 18, 2010 at 02:08:38PM +0200, Graeme Geldenhuys wrote: > > > > The simple reason is that .ini is one level only, and XML has an infinite > > nesting depth. > > Technically yes, but also no. For example. 'regedit' in Microsoft > Windows can export the registry (a f***ken huge tree and garbled mess) > to a .reg text files which is in fact a INI file. They use nesting as > follows, which could very easy be added to TINIFile (and I'm actually > thinking of doing this - see below). > > -------------------------- > [Level1] > Version=8 > > [Level1\Level2] > Company=Widgets Inc. > > [Level1\Level2\Level3] > FullName=John Doe > Age=35 > --------------------------
Yes. You can always try to map something multilevel on what it is not. But that is not the point. > The TINIFile's Section support could be extended to use '\' which > means no real change needed, or implement a dot notation. eg: A nested > section or value can be referenced as Level1.Version or > Level1.Level2.Level3.FullName It would be a freak format. Better use something standarized. I think that is a high price for notepad editability. If user editability matters so much to you, make a simple treeview based editor. -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
