Aaron J. Seigo
03ee0a6839
revert these changes as they go violate a number of design principles; this has been patiently explained a number of times now.
...
svn path=/trunk/KDE/kdelibs/; revision=962172
2009-05-01 16:28:10 +00:00
David Nolden
347c0caac4
- Allow painting a background color, or a background pattern behind freely floating elements of the theme, to provide a better fallback mechanism for transparent themes when composition is not available.
...
The color/pattern is given through the configuration file, and updating due to changes of the configuration file works perfectly. A simple user-interface to use this will be added to the panel configuration.
If you want to try this out, put into the [Theme] section of your plasmarc file:
frameBackgroundColor=#aacc00 (Your picked color)
frameBackgroundColorAlpha=120 (Alpha value for the color, between 0 and 255, 0=invisible, 255=opaque)
frameBackgroundPattern=/path/to/image
frameBackgroundPatternAlpha=255 (Alpha value for the pattern, as above)
The color is painted first, then the pattern. They are painted into the mask defined by the theme, so this only works nicely with themes that supply proper masks.
svn path=/trunk/KDE/kdelibs/; revision=961915
2009-05-01 00:41:41 +00:00
Olivier Goffart
9264bd3e76
Plasma::Svg: Round the drawing size to the pixmap size, otherwise we can get bad arctefacts.
...
(noticable on the eyes applet)
svn path=/trunk/KDE/kdelibs/; revision=941021
2009-03-18 18:06:56 +00:00
Arthur Renato Mello
827f5f19be
Add support to check with file timestamp if cache for Plasma::Svg is still valid.
...
svn path=/trunk/KDE/kdelibs/; revision=940638
2009-03-17 21:08:48 +00:00
David Faure
457f6c8c90
A precise warning about a missing icon is much easier to parse than
...
QFSFileEngine::open: No file name specified.
Approved by notmart (which is better than "not approved by mart" ;-)
svn path=/trunk/KDE/kdelibs/; revision=918255
2009-01-29 18:16:05 +00:00
Marco Martin
c532c9fda5
initialize the natural size also for absolute path svgs
...
never insert the whole image (no element) in the invalid list
to backport or not to backport?
CCMAIL plasma-devel@kde.org
svn path=/trunk/KDE/kdelibs/; revision=915328
2009-01-22 19:59:25 +00:00
Marco Martin
22b6670f00
cache on disk the natural svg size
...
svn path=/trunk/KDE/kdelibs/; revision=912132
2009-01-16 19:14:38 +00:00
Marco Martin
8a0159e10e
ensure that size() always return the real size
...
svn path=/trunk/KDE/kdelibs/; revision=912123
2009-01-16 18:43:26 +00:00
Marco Martin
ab3501872d
ensure that resize() resize always to the natural size (cached, so we
...
don't create unnecessary renderers)
svn path=/trunk/KDE/kdelibs/; revision=912093
2009-01-16 17:41:49 +00:00
Aaron J. Seigo
512bcd03a9
insert into the local cache
...
svn path=/trunk/KDE/kdelibs/; revision=911758
2009-01-16 02:46:33 +00:00
Laurent Montel
eebb6178a5
Fix iterator
...
svn path=/trunk/KDE/kdelibs/; revision=906617
2009-01-06 13:09:05 +00:00
Aaron J. Seigo
8c8e40c194
if parented to an applet and the appet has a package, use it.
...
svn path=/trunk/KDE/kdelibs/; revision=906378
2009-01-06 03:45:44 +00:00
Aaron J. Seigo
35304c269d
revert #898716 as it regressed bug #167430 , fix the problem by not transforming the svg in FrameSvgPrivate::updateSizes
...
CCBUG:167430
svn path=/trunk/KDE/kdelibs/; revision=905645
2009-01-04 19:07:46 +00:00
Andrew Lake
fb3d7e75cb
colorScheme and buttonColorScheme need to be updated the color changes
...
for system-color themes. Also clear out itemsToSave on colorChange.
svn path=/trunk/KDE/kdelibs/; revision=898780
2008-12-19 01:48:42 +00:00
Andrew Lake
b8c4897535
Reset size when renderer is erased. Should fix wierd border sizing
...
bug when changing to certain themes.
svn path=/trunk/KDE/kdelibs/; revision=898716
2008-12-18 20:28:09 +00:00
Aaron J. Seigo
f4486e8862
* remove in-memory entries for invalid elements when an svg is no longer in use
...
* remove in-memory entries for invalid elements when the rect cache is invalidated for an svg
svn path=/trunk/KDE/kdelibs/; revision=895570
2008-12-11 02:45:45 +00:00
Marco Martin
232986330b
clear local memory caches and stop cache timers when theme changes
...
svn path=/trunk/KDE/kdelibs/; revision=895370
2008-12-10 14:35:44 +00:00
Marco Martin
2af3225c26
size.isEmpty() does the same and looks nicer, good catch sebas :)
...
svn path=/trunk/KDE/kdelibs/; revision=894919
2008-12-09 16:22:03 +00:00
Marco Martin
e166600984
last commit was indeed correct but the whole thing still a bit wrong..
...
the other problem was that cachePath() did take the wrong size, the size
of the whole svg vs the size of the element to be drawn (and that was my
bad, so we can share the misery now, aaron:)
CCBUG:177172
svn path=/trunk/KDE/kdelibs/; revision=894713
2008-12-09 09:03:12 +00:00
Marco Martin
ff8af18497
a size like QSize(10,0) is valid but will end up in a null pixmap, and
...
this thing did confuse the cache a lot
CCBUG: 177172
does this patch fixes it? will keep open a day to be really sure :)
svn path=/trunk/KDE/kdelibs/; revision=894591
2008-12-08 22:22:18 +00:00
Aaron J. Seigo
7bc2bfd8da
constBegin
...
svn path=/trunk/KDE/kdelibs/; revision=894558
2008-12-08 21:27:42 +00:00
Aaron J. Seigo
e328a0a6c1
build .. =/
...
svn path=/trunk/KDE/kdelibs/; revision=894557
2008-12-08 21:26:46 +00:00
Aaron J. Seigo
12eca1edaf
use a const iterator; some ws fixes
...
svn path=/trunk/KDE/kdelibs/; revision=894551
2008-12-08 21:16:55 +00:00
Marco Martin
becd2b631e
some cleanups in the caching code
...
with that the systray background rendering problems seems somewhat less
frequent
svn path=/trunk/KDE/kdelibs/; revision=893751
2008-12-07 12:44:10 +00:00
Marco Martin
2952fe3e5f
rects cache and pixmap cache needs indeed ids a bit different due to the
...
fact that framesvgs are always at the "natural" size per se...
this should fix the systray breakage
svn path=/trunk/KDE/kdelibs/; revision=893029
2008-12-05 19:50:01 +00:00
Marco Martin
8994cc5ad6
we have the cure cacheId() function, let's use it mmkay?
...
svn path=/trunk/KDE/kdelibs/; revision=892656
2008-12-04 20:40:46 +00:00
Alain Boyer
dd61c4ef02
My first kommit! ;)
...
Use the local rect cache when possible. This gives another performace boost to painting code.
svn path=/trunk/KDE/kdelibs/; revision=892539
2008-12-04 14:25:40 +00:00
Aaron J. Seigo
20260277d3
QSizeF lacks some niceties found in QSize
...
svn path=/trunk/KDE/kdelibs/; revision=891380
2008-12-01 21:40:13 +00:00
Aaron J. Seigo
613383b1ea
clear the local cache on resize; prevent ever growing memory usage due to the cache and looking through our applet code people tend to resize rarely, and not between paints
...
svn path=/trunk/KDE/kdelibs/; revision=891373
2008-12-01 21:10:33 +00:00
Aaron J. Seigo
f25e5b82ff
provide a local rect cache in each Svg object to avoid going through the canonical but slower Theme cache more than once; makes a big difference for performance as these calls are made in painting hot paths
...
svn path=/trunk/KDE/kdelibs/; revision=891325
2008-12-01 18:07:20 +00:00
Marco Martin
6c7c11e934
exactly the same delayed cache insertion did for framesvg,
...
now the thing is really faster
svn path=/trunk/KDE/kdelibs/; revision=891275
2008-12-01 14:35:02 +00:00
Marco Martin
5a987e0a0b
no longer uses plasmarc for the presence or not of those hints but uses
...
the usual theme specific file.
and expires the cache when system color changes and a tinting is
required.
for some reasons a plasma restart is still required to get colors
applied correctly, some renderer doesn't get properly deleted on theme
change?
svn path=/trunk/KDE/kdelibs/; revision=885241
2008-11-16 20:53:24 +00:00
Aaron J. Seigo
4b08c03726
change KDE includes to use the .h style now that we're in libs
...
svn path=/trunk/KDE/kdelibs/; revision=879795
2008-11-04 02:04:34 +00:00
Aaron J. Seigo
1b523b9054
ok, this time JUST the plasma dir ;)
...
svn path=/trunk/KDE/kdelibs/; revision=879759
2008-11-03 23:08:39 +00:00
Aaron J. Seigo
fa5a2d87d9
bum-de-dum! plasma to kdelibs.
...
svn path=/trunk/KDE/kdelibs/; revision=879757
2008-11-03 23:03:26 +00:00
Marco Martin
1da58c95f4
make paint(painter,pos,elementid) work when containsMultipleImages =
...
true
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=878053
2008-10-31 09:43:51 +00:00
Aaron J. Seigo
f1accd0eba
ok, don't need this shouting all the time anymore
...
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872725
2008-10-17 23:41:13 +00:00
Marco Martin
027957f2e5
look ma, no FAILs!
...
use the suffix normal for natural for sizes in the cache, makes not
nevessary the svg size to be initialized
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872706
2008-10-17 21:27:32 +00:00
Davide Bettio
69155230cd
Added a new useful overload.
...
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872636
2008-10-17 17:45:18 +00:00
Aaron J. Seigo
51e053e529
so people can see when we FAIL and hit up an svg.
...
the goal is to see *zero* FAILs on a second run
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872383
2008-10-17 05:17:46 +00:00
Aaron J. Seigo
573306a3af
ok, that was a stupid error. =)
...
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872366
2008-10-17 02:52:51 +00:00
Aaron J. Seigo
de112e34fe
* remove some (apparently accidently) duplicated code
...
* add the size of the element we are looking for to the cache, so multiple sizes of the same svg don't result in reading the renderer
* if found, then don't go and re-check it even if the rect is invalid
this commit introduces some breakage since it actually relies on the cache properly now, it's apparent that there are some caching issues and we're getting incorrect values in/out =)
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872363
2008-10-17 02:30:08 +00:00
Marco Martin
ed626e5869
ahem, there was a missing !
...
:)
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872290
2008-10-16 20:04:51 +00:00
Marco Martin
089fb6ea94
cache on disk rects of elements and the not-existence of them
...
should avoid some calls of createRenderer() the second time it's queried
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=872250
2008-10-16 18:25:20 +00:00
Aaron J. Seigo
6374635bf3
on disk pixmap cache, and use it agressively for svg's. first step towards "no svg parsing on second run"!
...
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=871870
2008-10-15 20:55:07 +00:00
Allen Winter
c4573eae9a
use QString::clear() to clear a QString instead of assigning QString().
...
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=870305
2008-10-12 11:05:42 +00:00
Allen Winter
214ac5f91f
clean up some kDebugs and kWarnings.
...
shorten some extra long lines.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=870290
2008-10-12 10:20:02 +00:00
Allen Winter
a7aebfa60a
a bunch more coding style fixes. still some lines longer than 100 chars.
...
this is definitely helping me find false positives in the Krazy style checker.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=870161
2008-10-11 22:48:38 +00:00
Allen Winter
e88e2faa63
first batch of small coding style fixes.
...
these were found while testing the Krazy style checker, which I'm adapting
for the kdelibs style.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=870051
2008-10-11 16:19:04 +00:00
Andrew Lake
9b312459be
renderers hash table keys created with path but erased with themePath.
...
Corrects memory leak on theme change.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=867965
2008-10-05 04:47:25 +00:00