Re: [AD] Config routines bug (2)

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> I've tried to build a little rationale on the topic:
>
> 1. The behaviour that should have been implemented (as exposed in the
docs)
> is unsatisfactory: what if two sections contain the same entry ? Why
picking
> the first one and not the last one ? So passing NULL shouldn't mean
> searching the entire file.
>
> 2. Users may want to store only few datas in config files, without
> specifying any section. So we should have a mechanism to have access to
> 'sectionless' datas, and using NULL seems to be the most natural one.
>
> 3. Using an end-of-section marker would overload config files, so
> 'sectionless' datas should be put at the beginning of the files.
>
> 4. Using the NULL section for Allegro settings would be dangerous: simply
> adding a section before them in the config files would break them. So we
> should encapsulate every Allegro setting into a section.
>
> The only remaining question would then be: how many sections ?
> Currently, there are already: [fb_mode_XxY], [sound], [grabber],
[joystick].
> I'd propose to add: [system], [graphics], [keyboard], [mouse] and [timer].

Seems very sensible to me. I don't like the idea of Allegro config
spreaded over globals and sectioned parts



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/