KDE-wide Animation settings

Hugo Pereira Da Costa hugo.pereira at free.fr
Sun Jan 5 09:04:00 UTC 2014


On 01/04/2014 11:21 PM, Dominik Haumann wrote:
> On Saturday 04 January 2014 23:11:14 David Faure wrote:
>> On Saturday 04 January 2014 23:02:35 Dominik Haumann wrote:
>>> On Saturday 04 January 2014 20:56:30 Hugo Pereira Da Costa wrote:
>>>> ok. So this should go to kstyle (nothing oxygen explicit in there).
>>>>
>>>> In fact, kstyle returns:
>>>>
>>>> KConfigGroup g(KSharedConfig::openConfig(), "KDE-Global GUI Settings");
>>>>
>>>> return g.readEntry("GraphicEffectsLevel", 0);
>>>>
>>>> mmm. No clue which KCM sets this :)
>>>> (but that answers Dominik's original question I guess)
>>> Yes, that answers my question. In particular, using the code
>>>
>>>    widget->style()->styleHint(QStyle::SH_Widget_Animate, 0, widget)
>>>
>>> is correct *if* we use a KStyle based style.
>> No, it's correct in all cases :)
>> With the other Qt styles you get "true", which is the correct default value.
> Ok, I missed this one, thanks for the clarification!
>
>
>>> What I personally would like more is to always be able to read this.
>>>
>>> I of course can use a KSharedConfig::openConfig() and then read the config
>>> value myself. However, would it be of interest to have a static accessor
>>> for this? Downside is that there are quite a lot of kdeglobals dependent
>>> entries...
>>>
>>> Is the preferred way to read this value manually then in KatePart?
>>> Would that also be the preferred way in KMessageWidget?
>> I don't really see what the issue is. Do you care that much for Windows
>> users to be able to turn animations off?
> Nevermind, was a misunderstanding then.
>
>>> Another issue we have in Kate code: kdeglobals right now do not have this
>>> effects enabled by default. A unit test from kde4 times now fails in kf5,
>>> because the timings are different, because the effects are off.
>>>
>>> Are there plans to have a kdeglobals that has enabled effects?
>> As I said, it's a bug in the readEntry() call above. The default is supposed
>> to be 1, so you don't need a special kdeglobals.
> Ok, so who is going to fix it? ;) Hugo?
Question
should the default simply be "1"
or should kstyle re-introduce the same enumeration that was in 
KGlobalSettings ?


enum GraphicEffect {

NoEffects = 0x0000, ///< GUI with no effects at all.

GradientEffects = 0x0001, ///< GUI with only gradients enabled.

SimpleAnimationEffects = 0x0002, ///< GUI with simple animations enabled.

ComplexAnimationEffects = 0x0006 ///< GUI with complex animations enabled.

///< Note that ComplexAnimationsEffects implies SimpleAnimationEffects.

};


and the default be ComplexAnimationEffects ?



>
> Greetings,
> Dominik

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140105/66194366/attachment.html>


More information about the Kde-frameworks-devel mailing list