kwin clients - virtual colorsSupported()?
Matthew Woehlke
mw_triad at users.sourceforge.net
Tue Nov 27 19:29:34 GMT 2007
Lubos Lunak wrote:
> On Tuesday 27 of November 2007, Matthew Woehlke wrote:
>> aseigo and I have been having a little discussion [1] about kwin colors,
>> the upshot of which seems to be that kwinclients should communicate what
>> colors they support, similar I suppose to how they report what buttons
>> they support.
>>
>> Without knowing kwin very well, my gut reaction is that the "best" way
>> to do this is with a pure virtual, which means making the change *now*
>> since it is BIC+SIC. (aseigo says a getter+setter can be done BC but
>> agrees that a virtual is probably better.)
>>
>> Lubos, your thoughts?
>
> If all you need is querying a decoration whether it supports something, see
> KDecorationFactory::supports(). This is already done for buttons - there's
> one flag for querying whether the client supports announcing supported
> buttons :) and then there's one flag per button. You can have the same for
> window roles.
Ok. aseigo and I talked on IRC, and came up with two recommended solutions:
1. add color types to Ability
+ no new API, BC
- all clients must be updated or result will be wrong
2a. add 'virtual supports(ColorType) const;' to KDecorationFactory
+ reuses existing enum
- BIC
- clients might forget to override it
2b. add 'virtual supports(ColorType) const = 0;' to KDecorationFactory
+ reuses existing enum
+ clients must override it, more likely to do it correctly
- BIC
- all clients must be updated
Lubos, you're the maintainer, what do you think? aseigo and I both
prefer 2; aseigo likes 2a, while I lean a bit toward 2b.
--
Matthew
"Still not King." -- Aragorn
(as quoted in The Very Secret Diaries by Cassandra Claire)
http://www.ealasaid.com/misc/vsd/
More information about the kde-core-devel
mailing list