summaryrefslogtreecommitdiffstats
path: root/wgpu/src/text.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector@hecrj.dev>2024-07-17 13:00:00 +0200
committerLibravatar GitHub <noreply@github.com>2024-07-17 13:00:00 +0200
commit616689ca54942a13aac3615e571ae995ad4571b6 (patch)
tree763d8926cfa2be97dffa858a04036e207fd06ec8 /wgpu/src/text.rs
parentb518e30610fa53691c727852f70b497dd19cfc7a (diff)
downloadiced-616689ca54942a13aac3615e571ae995ad4571b6.tar.gz
iced-616689ca54942a13aac3615e571ae995ad4571b6.tar.bz2
iced-616689ca54942a13aac3615e571ae995ad4571b6.zip
Update `cosmic-text` and `resvg` (#2416)
* Update `cosmic-text`, `glyphon`, and `resvg` * Fix slow font fallback with `Shaping::Basic` in `cosmic-text` * Update `cosmic-text` and `resvg` * Update `cosmic-text` * Fix `SelectAll` action in `editor` * Fix some panics in `graphics::text::editor` * Remove empty `if` statement in `tiny_skia::vector` * Update `cosmic-text`, `glyphon`, and `rustc-hash`
Diffstat (limited to '')
-rw-r--r--wgpu/src/text.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/wgpu/src/text.rs b/wgpu/src/text.rs
index 05db5f80..bf7eae18 100644
--- a/wgpu/src/text.rs
+++ b/wgpu/src/text.rs
@@ -585,7 +585,13 @@ fn prepare(
(
buffer.as_ref(),
- Rectangle::new(raw.position, Size::new(width, height)),
+ Rectangle::new(
+ raw.position,
+ Size::new(
+ width.unwrap_or(layer_bounds.width),
+ height.unwrap_or(layer_bounds.height),
+ ),
+ ),
alignment::Horizontal::Left,
alignment::Vertical::Top,
raw.color,