This commit allows the theme designer to just enable and disable the
effect (enable=true). If no color values are set, values are picked
based on the background color. This essentially restores the hardcoded
values in some other places, and makes them available as sensible
defaults to other themes.
Also, make sure colors are read before the effect is applied (as we need
the new bg color to decide whether it's light or dark).
From its api docs:
This method allows Plasma to enable and disable the background
contrast effect for a given theme, improving readability. The
value is read from the "enabled" key in the "ContrastEffect"
group in the Theme's metadata file.
The configuration in the metadata.desktop file of the theme
could look like this (for a lighter background):
[ContrastEffect]
enabled=true
contrast=0.45
intensity=0.45
saturation=1.7
The minimumWidth of a plasma button is based on the paintedWidth
of the text item. There is no way to work out the correct width it
should be if we set the text to elide.
(except for the hack of using a hidden fake text item)
We should always fit contents. This won't cause any problems unless a
developer has a broken layout, at which point that should be fixed
REVIEW: 115500
to avoid possible collisions, use the private looking name "_plasma_graphicObject" for the dynamic property of Applet that represents the AppletInterface* pointer
This patch makes two changes:
1) don't rely on window()->screen() it's rubbish.
2) if the dialog is parented to a desktop, we want to position
inside the parent, not outside the parent object
REVIEW: 115448
BUG: 330546
this ports revision c03052935b082 on kdelibs
improve cache file dropping
* fix regression: version the image cache file name
* version the svg elements
* drop old svg elements files
* respond to changes at runtime by watching the theme's metadata.desktop for changes
* move creation of the svg elements file into ThemePrivate::useCache()
REVIEW:115397
This reads the global animation duration value from plasmarc, and gets
notified of changes: change the file, all animations are updated
automatically.
Put this into your plasmarc to disable animations globally:
[Units]
longDuration=0
As you might guess, other values will work as well.
shortDuration will always be 1/5 of this. (For now.)