Commit graph

378 commits

Author SHA1 Message Date
Héctor Ramón Jiménez
346af3f8b0
Make FontSystem global and simplify Paragraph API 2023-09-11 02:47:24 +02:00
Héctor Ramón Jiménez
b42b24b79a
Fix (more) broken intradoc links
Good thing I just set up CI earlier for this 😅
2023-09-10 00:55:46 +02:00
Héctor Ramón Jiménez
b8e5693a30
Merge branch 'master' into explicit-text-caching 2023-09-10 00:34:21 +02:00
Héctor Ramón Jiménez
9565123389
Remove unused unicode-segmentation dependency from iced_graphics 2023-09-09 23:06:06 +02:00
Héctor Ramón Jiménez
bbb9c2d928
Count grapheme clusters in Paragraph::grapheme_position 2023-09-09 23:05:44 +02:00
Héctor Ramón Jiménez
419d9374b7
Fix outstanding broken intradoc links 2023-09-09 21:08:23 +02:00
Héctor Ramón Jiménez
f60884f6f8
Deny broken_intradoc_links and verify documentation in CI 2023-09-09 20:58:45 +02:00
Matthias Vogelgesang
89d9f1d7d2 Fix majority of unresolved documentation links 2023-09-09 18:59:17 +02:00
Héctor Ramón Jiménez
3450987355
Invalidate existing paragraphs when new fonts are loaded 2023-09-09 11:21:32 +02:00
Héctor Ramón Jiménez
f468e25d0c
Use workspace dependencies and package inheritance
We are also taking this as a chance to synchronize
the versions of all the crates! Because of this, we
will skip the `0.11` version.
2023-09-04 13:08:17 +02:00
Héctor Ramón Jiménez
34495bba1c
Introduce keyed::Column widget 2023-09-04 02:55:09 +02:00
Héctor Ramón Jiménez
6758de2b43
Fix Default implementation for Paragraph 2023-09-01 04:14:06 +02:00
Héctor Ramón Jiménez
51e69d7040
Replace MaybeUninit with Option in paragraph 2023-09-01 04:04:15 +02:00
Héctor Ramón Jiménez
935c722a27
Use Arc::try_unwrap in Paragraph
We use `MaybeUninit` here instead of `Option` to save some cycles, but
I will most likely change it for an `Option` since unsafe code is quite
scary.
2023-09-01 03:59:57 +02:00
Héctor Ramón Jiménez
ce22d661fa
Remove Clone implementation for Paragraph 2023-09-01 03:25:29 +02:00
Héctor Ramón Jiménez
89acf0217e
Use min_bounds for cached text 2023-08-30 05:06:08 +02:00
Héctor Ramón Jiménez
ed3454301e
Implement explicit text caching in the widget state tree 2023-08-30 04:31:21 +02:00
Kxie
76ffbbd06e
Update arc.rs with improved documentation
added units and improved description to field comments of Arc and Ellipse structs.
2023-08-15 07:52:30 +02:00
Héctor Ramón Jiménez
126aef88e7
Bump versions 🎉 2023-07-28 19:48:39 +02:00
Héctor Ramón Jiménez
d666e739cd
Trim text measurements only before layout 2023-06-29 18:23:11 +02:00
Héctor Ramón Jiménez
cdce03cf7f
Revert "Remove layout method from core::Renderer trait"
This reverts commit 2128472c2a.
2023-06-29 18:17:18 +02:00
Héctor Ramón Jiménez
6921564c9f
Write missing docs in iced_graphics and iced_wgpu 2023-06-29 07:55:52 +02:00
Héctor Ramón Jiménez
fa5650cfd1
Decouple Mesh primitives from main Primitive type 2023-06-29 07:48:03 +02:00
Héctor Ramón Jiménez
2128472c2a
Remove layout method from core::Renderer trait 2023-06-29 07:18:24 +02:00
Héctor Ramón Jiménez
0ae1baa37b
Introduce custom backend-specific primitives 2023-06-29 07:18:20 +02:00
Héctor Ramón Jiménez
78ad365db2
Reuse entries in text::Cache in iced_wgpu 2023-06-28 00:35:37 +02:00
Héctor Ramón
c7332c1522
Merge pull request #1885 from bungoboingo/gradient-packing-optimization
Small gradient optimization
2023-06-27 22:10:17 +02:00
Héctor Ramón
f6966268bb
Merge pull request #1845 from bungoboingo/feat/offscreen-rendering
Feat: Offscreen Rendering & Screenshots
2023-06-27 20:37:19 +02:00
Héctor Ramón Jiménez
5bc7cbf5bc
Use subpixel glyph positioning and layout linearity
... for offsetting and scaling text
2023-06-20 06:50:36 +02:00
Bingus
677f564f08
Switched to packing using f16s to maintain acceptable precision. 2023-06-07 11:18:26 -07:00
Bingus
9554c78f3a
Updated color packing into u32 to consider incorrect web-colors. 2023-06-06 17:24:26 -07:00
Bingus
ea7f2626b1
Optimized gradient data packing. 2023-06-06 16:46:20 -07:00
Bingus
233196eb14
Added offscreen rendering support for wgpu & tiny-skia exposed with the window::screenshot command. 2023-06-06 15:37:30 +02:00
Héctor Ramón Jiménez
faa7627ea4
Introduce web-colors feature flag to enable sRGB linear blending
This is how browsers perform color management. They treat
gamma-corrected sRGB colors as if they were linear RGB.

Correctness aside, this mode is introduced for legacy reasons. Most
UI/UX tooling uses this color management as well, and many have created
an intuition about how color should behave from interacting with a
browser.

This feature flag should facilitate application development with `iced`
in those cases.

More details: https://webcolorisstillbroken.com/
2023-05-31 21:31:58 +02:00
Héctor Ramón Jiménez
8ca7b884c0
Make Packed fully opaque
... by only allowing direct conversion from our `Gradient` types
2023-05-29 20:56:51 +02:00
Bingus
902e333148
Changed gradient::Packed to be repr(C) for direct gpu upload. 2023-05-26 10:13:18 -07:00
Bingus
413526ad09
Created "Packed" data structure for gradient data. 2023-05-25 10:49:26 -07:00
Bingus
a395e78596
Made gradient pack public for iced_graphics::gradient mod for use with GradientVertex2D. 2023-05-24 13:08:59 -07:00
Benoît du Garreau
dee8ede5be Update glam to 0.24 2023-05-22 17:23:42 +02:00
Héctor Ramón
cc5d11f1a6
Merge pull request #1846 from bungoboingo/feat/background-gradients
[Feature] Gradients for Backgrounds
2023-05-19 04:37:58 +02:00
Héctor Ramón Jiménez
3d44de9547
Fix imports of geometry::style in iced_graphics 2023-05-19 03:49:42 +02:00
Héctor Ramón Jiménez
4c1a082f04
Remove Builder abstractions for gradients 2023-05-19 03:32:21 +02:00
Bingus
6551a0b2ab
Added support for gradients as background variants + other optimizations. 2023-05-11 11:13:44 -07:00
Héctor Ramón Jiménez
cf434236e7
Enable doc_auto_cfg when generating documentation 2023-05-11 17:28:51 +02:00
Héctor Ramón Jiménez
de638f44a5
Write missing documentation in iced_wgpu 2023-05-11 15:37:56 +02:00
Héctor Ramón Jiménez
8622e998f2
Write missing documentation in iced_graphics 2023-05-11 15:25:58 +02:00
Héctor Ramón Jiménez
9499a8f9e6
Support configurable LineHeight in text widgets 2023-05-04 18:39:31 +02:00
Héctor Ramón Jiménez
4bd290afe7
Introduce text::Shaping enum and replace magic boolean 2023-05-02 01:02:32 +02:00
Héctor Ramón Jiménez
33b5a90019
Make basic text shaping the default shaping strategy 2023-05-02 01:02:13 +02:00
Héctor Ramón Jiménez
38f82ab35f
Expand damage regions of Clip primitives a bit 2023-04-27 15:25:59 +02:00