Guillaume Ayoub
66d2b4da3c
First SVG text test
2021-04-14 16:56:30 +02:00
Guillaume Ayoub
0d8fb23145
Clean SVG support
2021-04-11 16:13:59 +02:00
Guillaume Ayoub
882681a99c
Preserve ratio for svg tags
2021-03-23 13:58:31 +01:00
Guillaume Ayoub
b7392374e2
Handle linear gradients
2021-03-19 15:58:22 +01:00
Guillaume Ayoub
561734e8ae
Make SVG tests pass again
2021-03-12 16:59:02 +01:00
Guillaume Ayoub
de9359ad46
Fix intrinsic sizes calculation
2021-03-12 15:20:20 +01:00
Guillaume Ayoub
43ec426f6b
Add all SVG shapes, inheritance and transformations
2021-03-07 20:34:24 +01:00
Guillaume Ayoub
9d300c1528
First SVG shapes
2021-03-07 18:00:38 +01:00
Lucie Anglade
a4ed61f1b6
Transform is done in pydyfsvg
2021-03-07 18:00:37 +01:00
Lucie Anglade
a5e20cfe4c
Support SVG with pydyf
2021-03-07 18:00:37 +01:00
Guillaume Ayoub
30c21d92e9
Fully remove Cairo from documentation and code
2020-12-10 22:47:27 +01:00
Guillaume Ayoub
f10b3b56c8
Fix error raised when SVG images are rendered
2020-12-08 15:51:35 +01:00
Guillaume Ayoub
cfb9017e84
Remove CairoSVG
...
Fix #1263 .
2020-12-07 12:27:18 +01:00
Guillaume Ayoub
5ed5b54d59
Handle transparent colors in gradients correctly
...
Gradients must be drawn using a pre-multiplied color space. It means that stop
colors are "weighted" by their alpha channel when we define how transition is
done between two colors.
To explain why this is needed, the best example is "transparent". The
"trasparent" color is set to rgba(0, 0, 0, 0), also known as transparent
black. When there’s a transition from red to transparent, we don’t want to have
a transition to black, as it would be if RGBA values were extrapolated. We want
to have a transition to transparent red.
This problem appears for each transition between colors whose RGB and A
channels are both different.
To fix this, we use the same plain color as the one from the previous stop for
transitions to transparent, and the same plain color as the one from the next
stop for transitions from transparent. For semi-transparent colors, we set a
weight proportional to the color alpha, meaning that opaque colors will take
more place than transparent ones.
This bug appears in Safari: https://bugs.webkit.org/show_bug.cgi?id=150940 .
It obviously means that we’re better than Apple. Obviously.
2020-11-30 20:54:26 +01:00
Guillaume Ayoub
5f5f30d3e8
Support transparent gradients
2020-11-30 19:12:41 +01:00
Guillaume Ayoub
94cf4bf5e0
Fix colors in repeating linear gradients
2020-10-25 20:18:13 +01:00
Guillaume Ayoub
8cd28aee31
Small fixes on linear gradients
2020-10-25 15:52:58 +01:00
Guillaume Ayoub
1ff768c103
Support linear gradients
2020-10-25 14:54:08 +01:00
Guillaume Ayoub
60df2d174e
Handle repeating radial gradients
2020-10-25 13:41:23 +01:00
Guillaume Ayoub
02e6beb041
Fix gradient documentation and comments
2020-10-25 07:32:41 +01:00
Guillaume Ayoub
b37feca543
Fix radial gradients and related tests
2020-10-24 21:35:17 +02:00
Guillaume Ayoub
7f2c64e5a6
Handle degenerate radial gradients
2020-10-24 20:49:42 +02:00
Guillaume Ayoub
18e567c95e
Fix radial gradients
2020-10-24 20:46:38 +02:00
Guillaume Ayoub
04f40ae9b2
Fix various tests
2020-10-24 18:00:48 +02:00
Guillaume Ayoub
bd0a6eee45
Fix non-repeating linear gradients
2020-10-24 17:42:13 +02:00
Guillaume Ayoub
9d29716b91
Merge remote-tracking branch 'origin/master' into pydyf
2020-07-31 14:46:36 +02:00
Guillaume Ayoub
c56b96b3c1
Add an option to optimize embedded images size
2020-06-22 16:05:14 +02:00
Guillaume Ayoub
30db42b08a
Fix gradients domain
2020-06-08 16:34:36 +02:00
Guillaume Ayoub
6aa16733ec
Remove useless import
2020-06-08 16:10:24 +02:00
Guillaume Ayoub
8f9e15a57e
Handle image-rendering
2020-06-08 00:01:09 +02:00
Guillaume Ayoub
58016053a0
Handle solid gradients
2020-06-07 23:40:01 +02:00
Guillaume Ayoub
d6cdb690a2
Handle multi-color gradients
2020-06-07 11:40:30 +02:00
Guillaume Ayoub
29365f3318
Re-enable user_to_device_distance
2020-06-07 11:04:12 +02:00
Guillaume Ayoub
0350a8c055
Handle very simple gradients
2020-06-07 00:32:47 +02:00
Lucie Anglade
f2a7614138
Rotate image
2020-06-03 19:47:34 +02:00
Lucie Anglade
f530502e05
Handle jpg images
2020-06-03 17:58:53 +02:00
Guillaume Ayoub
9372b94e8d
Clean formatted strings
2020-05-30 15:55:44 +02:00
Guillaume Ayoub
58599d325e
Don’t crash when trying to display images
2020-05-18 01:29:59 +02:00
Guillaume Ayoub
70e195f464
Use transform instead of scale and translate
2020-05-16 00:19:25 +02:00
Guillaume Ayoub
bf2b21b6e0
First steps to replace cairo with pydyf
2020-04-18 00:19:35 +02:00
Guillaume Ayoub
b40ad461be
Remove repeated copyright assignments in files
...
Everything is replaced by a more explicit message in the COPYRIGHT file.
Inspired by rust-lang/rust#43498 and rust-lang/rust#57108 .
2020-01-02 14:10:09 +01:00
Guillaume Ayoub
47ec97bcaf
Remove useless explicit object inheritance
2020-01-02 12:06:58 +01:00
Guillaume Ayoub
4865b97a22
Remove useless super() arguments
2019-12-23 15:34:49 +01:00
Guillaume Ayoub
9f442be640
Move percentage function into percentages module
2019-06-02 18:06:25 +02:00
Manuel Barkhau
20afa51175
refactor: factor out "precentage" function
2019-06-01 01:39:40 +02:00
Guillaume Ayoub
37e788e8c3
Force SVG size
...
Related to #867 .
2019-05-20 12:31:30 +02:00
Guillaume Ayoub
b7a9fe7dcc
Update copyright
2019-03-04 11:04:06 +01:00
Guillaume Ayoub
56904baa79
Use the same copyright line everywhere
2018-09-20 18:46:27 +02:00
Guillaume Ayoub
d0f0490890
Remove dead and old code from tests
2018-03-12 19:02:17 +01:00
Guillaume Ayoub
16e8186568
Drop Python 2 support
2018-01-14 01:48:17 +01:00