Commit graph

24 commits

Author SHA1 Message Date
Martin Robinson
423cc34cb0 Bump euclid to 0.22
- Also updates raqote to latest with an upgrade of font-kit to 0.11
  applied on as a patch
- Update lyon_geom to the latest version

Major change:

- All matrices are now stored in row major order. This means that
  parameters to rotation functions no longer should be negated.
- `post_...()` functions are now named `then()`. `pre_transform()` is removed,
  so `then()` is used and the order of operations changed.
2023-01-26 08:59:21 +01:00
Utsav Oza
d1241a8d06 Fix ./mach build --release --with-layout-2020 2020-06-10 22:34:24 +05:30
Utsav Oza
34d0c313dc Enable textAlign, textBaseline and direction attributes for canvas 2020-06-10 22:34:20 +05:30
Utsav Oza
c21fde3751 Implement CanvasRenderingContext2D.font property 2020-06-10 22:11:24 +05:30
Utsav Oza
15fd256302 Store resolved font style in canvas context state 2020-06-10 22:10:44 +05:30
Utsav Oza
f3cb7a1910 Add todos for missing steps while processing parse font query 2020-06-10 22:10:43 +05:30
Utsav Oza
7883718c12 Query layout to resolve canvas font property value 2020-06-10 22:10:42 +05:30
Utsav Oza
726f7d7209 Check for valid arguments before processing canvas.fillText 2020-06-10 22:10:32 +05:30
Julien Tregoat
2742fd2bea Refactor ImageCache::find_image_or_metadata API. 2020-04-17 11:58:18 -04:00
Utsav Oza
bd8fbee12c Resolve mach build warnings 2020-04-10 23:02:31 +05:30
Manish Goregaokar
fccfff11c5 Update euclid 2020-04-07 08:51:08 -07:00
pylbrecht
588c09b580 Implement CanvasRenderingContext2D.getTransform() 2020-02-12 08:49:18 +01:00
pylbrecht
481ef46167 Make create_pattern() return None for incomplete images 2020-02-10 14:23:38 +01:00
pylbrecht
423b86e439 Add canvas usability checks to drawImage() 2020-02-03 22:49:46 +01:00
pylbrecht
ed0973fb1c Add image usability checks to drawImage() 2020-02-03 20:46:03 +01:00
pylbrecht
5a773bf55a Send fill/stroke style along with drawing message 2020-01-25 21:29:36 +01:00
pylbrecht
ebdf4693ab Update fill and stroke style only when required
So far fill and stroke style updates have been sent to the canvas paint
thread by `SetFillStyle()` and `SetStrokeStyle()`. This resulted in
fill/stroke style updates not being considered by the canvas paint
thread between the latest call of `SetFillStyle()`/`SetStrokeStyle()` and
the drawing operation (e.g. fill or stroke).

This issue is solved by making `SetFillStyle()` and `SetStrokeStyle()`
update the local canvas state and propagating the state to the canvas
paint thread right before any drawing operation that requires it.
2020-01-25 21:29:24 +01:00
Bailey Blankenship
deae103042 Addresses Issue: Support OffscreenCanvas as CanvasImageSource #24269
Added methods to canvas_data to support drawing an offscreen canvas onto another canvas
Bug fix: Swapped OffscreenCanvas width and height parameters to match Mozilla spec
Tests: Updated metadata for 866 tests
2019-12-04 18:23:28 -05:00
bors-servo
7da8d75a7e
Auto merge of #24426 - servo:wrup, r=jdm,nox
Update webrender

<!-- Reviewable:start -->
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/24426)
<!-- Reviewable:end -->
2019-11-20 05:08:32 -05:00
Simon Sapin
bea73951db Use #![register_tool] instead of #![register_attr]
CC https://github.com/rust-lang/rust/issues/66079
2019-11-15 17:24:42 +01:00
Anthony Ramine
808c34498b Update webrender and serde_bytes 2019-11-13 11:54:51 -05:00
Bailey Blankenship
ec2961920b Addresses issues raised in #24465; removes redundancy in set_bitmap_dimensions
Removed passing test .ini files and moved euclid extensions to euclidext.rs to factor out redundant code
2019-11-10 18:37:14 -05:00
teapotd
35a48a7577 Return false from CanvasState::IsPointInPath for NaN/infinite values 2019-10-28 17:43:24 +01:00
Hanif Bin Ariffin
31ff2d43cc Moved CanvasState out of canvasrenderingcontext
Cleaned up imports...

Applied clang-tidy

Moved CanvasState  and some other files

Next commit should remove pub modifier from members of CanvasState and use getters/setters instead.

Members of CanvasState are now private and applied test-tidy

Now have getters that return an immutable reference.
Also, I have no idea what to name some_func.rs

Removed need for some_func and made pub(crate)
2019-10-25 02:27:57 -04:00