David Edmundson
c127b78d57
Always take the slow path for composeOverBorder
...
We previously only supported compose-over-border when the centre was not
set to tile.
It's possible to use compose over border with tile.. even if it doesn't
make much sense.
Given that creating an opacityMask loads most of the image anyway, we
can make use of the FrameSVG painter path and avoid any additional code
complexity here.
REVIEW: 119406
2014-07-23 15:54:13 +02:00
David Edmundson
bdb0b3b2ca
Check for empty sized elements in original SVG
...
Reviewed-by: Aleix Pol
2014-07-22 13:35:44 +02:00
Aleix Pol
e613662ab5
Make framesvg unit test pass
...
Revert the changes in contentsRect, it was clearly not the best place to
put the code that contains the code that computes the content size.
Instead move the code in FrameSvgItem, duplicates data and code but works.
2014-07-22 03:14:26 +02:00
Aleix Pol
dca3958b44
Stop exposing that many things in FrameSvgItem
...
Move the shared code between FrameSvg and FrameSvgItem into a separate file
that both can link to.
Reviewed by David Edmundson
2014-07-21 18:01:26 +02:00
Aleix Pol
47c7688d02
Move some of the code and make some API public
...
It's unreasonable to use private API, so make everything public API so that
every user of FrameSvg have as much features exposed as possible.
Reviewed by David Edmundson
2014-07-21 15:44:25 +02:00
Aleix Pol
565b2b6f51
Add a guard after figuring out the contentRect for a framesvgitem
2014-07-18 12:44:06 +02:00
David Edmundson
3eee37bd81
Don't allow tiling + compose over border at the same time
...
It wouldn't make any sense. Just choose tiling
2014-07-17 22:42:26 +02:00
David Edmundson
371c9a53dd
Add composeOverBorder support in FrameSVGItem
2014-07-17 22:29:54 +02:00
David Edmundson
2bf3466b53
Put compose over border onto the slow path that renders the entire item
2014-07-17 19:32:17 +02:00
David Edmundson
1924877140
Add code path FastStretch, which resizes without re-rendering
2014-07-16 22:51:29 +02:00
David Edmundson
be05a8394a
Don't remove nodes from a parent whilst we're cycling through them
2014-07-16 22:22:43 +02:00
David Edmundson
6c0dadc1c2
tidy variable + method names + fix crash
2014-07-16 20:40:41 +02:00
David Edmundson
e037203748
Add tiling support
2014-07-16 20:40:41 +02:00
Aleix Pol
a4e3569bbd
Introduce the FrameSvgItem fastPath alternative, opt out of it on overlays
...
Fallback to the old code if there's something not (yet?) handled by the
new implementation. This way we get to optimize for the the common use-case
without breaking former, complex, code-paths.
Reviewed by David Edmundson
2014-07-16 17:01:05 +02:00
Aleix Pol
cbe13ac765
Do a full repaint when frameSvg says a repaintNeeded
2014-07-16 13:51:53 +02:00
Aleix Pol
fc4e09df46
Add warning
2014-07-15 19:57:43 +02:00
Aleix Pol
0a94e1b1b8
Take composeOverBorder into accoun
2014-07-15 19:56:04 +02:00
Aleix Pol
cf0f8d0c91
Make sure all prefixes are being used
2014-07-15 19:54:45 +02:00
Aleix Pol
89536abd9c
Take into account that the requested prefix is not always the actually used prefix
2014-07-15 17:26:25 +02:00
Aleix Pol
4bde2d48dd
Iterate over svgitem
...
Don't upload textures every time we resize, makes the resize much smoother.
Make it possible to show and hide borders
2014-07-15 16:28:41 +02:00
Aleix Pol
83895d8e26
Use proper sizes and positions
2014-07-14 20:02:47 +02:00
David Edmundson
dcbcb8a490
Construct full frame image using nodes inside FrameSVGItem
2014-07-14 18:44:33 +02:00
Harald Sitter
ce329f4402
qmax(qreal, double) is not valid as qreal may be float
...
adjust the call to use qreal for both (floor() returns double)
REVIEW: 118487
2014-06-03 14:37:38 +02:00
Allen Winter
939e01f554
fix build
...
include <cmath> to declare floor()
2014-05-11 20:58:53 -04:00
Kevin Ottens
72ba7b4146
Apply the astyle-kdelibs script
2014-04-26 01:48:37 +02:00
David Edmundson
48e8e588a6
Add documentation on FrameSVGItem updating
2014-03-05 18:07:54 +01:00
David Edmundson
6599c25087
Port FrameSVGItem to paint directly
...
REVIEW: 116618
2014-03-05 17:24:13 +01:00
Marco Martin
b388a0d76b
expose hasElementPrefix() method
2014-03-04 18:13:46 +01:00
Marco Martin
53b2aba558
explain why we only consider integers right now
2014-02-25 19:39:12 +01:00
Marco Martin
a04a87bcec
use units to understand the devicePixelRatio
2014-02-24 16:55:19 +01:00
Marco Martin
c009c7f0cd
concept of fixedMargins
...
sometimes we need to know what the margins are of a framesvg, even if some of them are disabled
2014-02-21 21:13:12 +01:00
Marco Martin
17332257d7
experimental devicePixelRatio in Plasma::Svg
...
Conflicts:
src/declarativeimports/core/framesvgitem.cpp
2014-02-21 19:24:14 +01:00
David Edmundson
6bff4ef469
Avoid frame resizing till componentCompleted
2014-02-13 12:45:30 +01:00
Kevin Ottens
0e590217f8
Port away from kdebug
2013-07-30 08:05:09 +02:00
Marco Martin
e07600a83f
Put all Plasma emums in a Types class
...
This makes possible to use them directly frmo QML
as a minus, is not pretty and requires tons of search and replace in old
c++ code
2013-05-10 19:29:13 +02:00
Marco Martin
799a5989d9
enable blur behind
2013-02-21 14:58:09 +01:00
Sebastian Kügler
7dfe957e66
The Big Move
...
All cpp code moves into the src/ subdirectory, as the Frameworks policy
suggests.
Directory structure should now be in line with other, future frameworks.
2013-02-14 17:17:12 +01:00