even more on kconfig escapes (Re: KDE/kdelibs/kdeui/icons)

Oswald Buddenhagen ossi at kde.org
Thu Nov 22 08:17:05 GMT 2007


On Thu, Nov 22, 2007 at 12:49:01AM -0600, Thomas Braxton wrote:
> On 11/21/07, Oswald Buddenhagen <ossi at kde.org> wrote:
> >   now we need some way to delimit hierarchy levels. proposals range from
> >   the not-so-fortunate / (current), the probably better | (apaku) or the
> >   even better ^ (me :). this all doesn't really *solve* the problem,
> >   though - it merely lessens the probability of it surfacing. same game
> >   as with list separators in values before ...
> 
> So I propose to use an ASCII control char that I've never heard of,
> and is probably a holdover from some old hardware. It is named
> appropriately for this ASCII char 0x1d (Group Separator). I would
> guess it is *extremely* unlikely to be used in any group names,
>
actually, it is a real solution, as this char would be already encoded
and will thus never be present in a ini file. technically it is
equivalent to the equal sign variant.
however, it never occurred to me to do something like that, as it has
great potential for breaking stuff: it's simply not plain text any more.
various editors offer more or less useful and obvious representations of
such characters, and more or less useful possibilities to enter them,
but it is generally hard to deal with such stuff and highly unexpected.

> But, it would break any current configs that have subgroups, but I
> don't see a way around that.
>
that affects only new code that was already trying to introduce
subgroups, but no kde3 code. so there is relatively little loss.

> I would favor the simplest first, [...]. Then if that isn't good
> enough try one of the other alternatives,
>
that' not gonna work. this is the last moment to get it right; then we
are stuck with it for the next ~7 years.

> even though I don't know which one would be least ugly code-wise and
> file-wise :)
>
bah, the second one already. feared that. :}

> Though your last idea seems interesting.
>
yes. i think i'll simply do it. it looks quite readable (even if a bit
weird at first) and the implementation should be simple.

-- 
Hi! I'm a .signature virus! Copy me into your ~/.signature, please!
--
Chaos, panic, and disorder - my work here is done.




More information about the kde-core-devel mailing list