Commit graph

125 commits

Author SHA1 Message Date
Héctor Ramón Jiménez
3a327e08e9 Rename Empty widget to Space 2019-12-30 21:33:27 +01:00
Héctor Ramón Jiménez
8426bf953c Implement Empty widget
It can be useful if you want to fill some space with nothing.
2019-12-30 19:20:59 +01:00
Héctor Ramón Jiménez
7163e1d8b6 Implement Default for iced_wgpu::Primitive 2019-12-30 19:17:00 +01:00
Héctor Ramón Jiménez
d78ae3c852 Avoid rasterizing SVG when a dimension is 0 2019-12-21 08:16:36 +01:00
Héctor Ramón Jiménez
36e7ac2048 Fix cursor positioning in TextInput on overflow 2019-12-21 05:30:48 +01:00
Héctor Ramón Jiménez
0d7e236039 Resize text measure cache to avoid panic
This should not be really necessary, as we are not really drawing
anything with the measure brush... But we are using `glyph_brush`
in an unconventional way, so that may be the cause. We need to redesign
`wgpu_glyph` or come up with an alternative.
2019-12-18 23:14:54 +01:00
Héctor Ramón Jiménez
514ccf8a72 Cache Svg load result properly
This avoids trying to reload the file constantly on every frame.
2019-12-15 07:07:49 +01:00
Héctor Ramón Jiménez
232d4873ba Put svg rendering behind a feature gate
This reduces binary size when SVG supoprt is not needed.
2019-12-15 06:45:20 +01:00
Héctor Ramón Jiménez
aa29849976 Add svg example 2019-12-15 06:31:53 +01:00
Héctor Ramón Jiménez
09707f29fc Rerasterize SVGs when resized and refactor a bit 2019-12-15 06:19:07 +01:00
Malte Veerman
895eaef99b Merged svg pipeline into image 2019-12-12 01:14:54 +01:00
Malte Veerman
f737c6da24 Improved dpi handling 2019-12-12 00:20:06 +01:00
Malte Veerman
5696afcadd Ran cargo_fmt over changed files. 2019-12-11 22:13:29 +01:00
Malte Veerman
a88aae5e04 Added an Icon widget to native. 2019-12-11 21:34:40 +01:00
Malte Veerman
8032428428 Implemented SVG support in iced_wgpu. 2019-12-11 20:02:43 +01:00
Héctor Ramón Jiménez
14fb7e13fb Place TextInput cursor position on click 2019-12-05 03:09:39 +01:00
Malte Veerman
33ad332ce9 Implemented From<Color for Background 2019-12-04 22:02:07 +01:00
Héctor Ramón Jiménez
561c3641c6 Merge branch 'master' into feature/image-from-bytes 2019-12-04 04:01:12 +01:00
Héctor Ramón
6c145bbb23
Merge pull request #95 from Friz64/scrolling-behaviour
Make scrolling behave like you'd expect it to
2019-12-04 01:14:13 +01:00
Héctor Ramón Jiménez
0b5409c53d Fix TextInput inner border radius in iced_wgpu 2019-12-03 07:40:56 +01:00
Héctor Ramón Jiménez
31e3b6fbcb Unify logic by introducing scrollable::Scrollbar 2019-12-03 06:49:31 +01:00
Friz64
6943041e0f Address suggestions 2019-12-02 19:12:05 +01:00
Friz64
f8fac432c6 Finalize work 2019-12-02 19:10:07 +01:00
Friz64
5eec3a8867 First implementation 2019-12-02 19:09:17 +01:00
Héctor Ramón Jiménez
e648de560d Use PowerPreference::Default in iced_wgpu 2019-12-01 23:36:29 +01:00
Héctor Ramón Jiménez
67570a0a1d Add repr(C) to GPU types 2019-12-01 19:03:05 +01:00
Héctor Ramón Jiménez
fab6d79e84 Implement basic image cache trimming in iced_wgpu 2019-11-30 02:55:14 +01:00
Héctor Ramón Jiménez
505588d585 Allow to load an image from memory
New `image::Handle` opaque type uniquely identifying some `image::Data`,
allowing reliable caching.
2019-11-29 21:44:39 +01:00
Héctor Ramón Jiménez
80a8a57471 Stop loading a mono font just for the debug view 2019-11-26 15:33:38 +01:00
Héctor Ramón Jiménez
a99aa1dd61 Fallback to embedded font when system font fails 2019-11-26 15:32:11 +01:00
Héctor Ramón Jiménez
862859142b Add CHANGELOG to subcrates 2019-11-25 14:55:14 +01:00
Héctor Ramón Jiménez
700390bdb2 Use explicit Uniforms type in image pipeline 2019-11-24 17:25:54 +01:00
Héctor Ramón Jiménez
1a6333c7f3 Fix copy image instance size in iced_wgpu 2019-11-24 17:25:28 +01:00
Héctor Ramón Jiménez
c6edc75f58 Use latest wgpu_glyph 2019-11-24 17:16:19 +01:00
Héctor Ramón Jiménez
422e2a6194 Avoid panic when image load fails in iced_wgpu 2019-11-24 12:03:12 +01:00
Héctor Ramón Jiménez
f943764a29 Fix iced_native widget examples 2019-11-24 10:44:55 +01:00
Héctor Ramón Jiménez
6a0e442ad6 Write docs for iced_wgpu 2019-11-22 22:14:24 +01:00
Héctor Ramón Jiménez
42e775fece Merge branch 'master' into improvement/docs 2019-11-22 20:30:57 +01:00
Héctor Ramón Jiménez
65eb218d3d Move widgets from core to native and web
Also made fields private and improved `Renderer` traits.
2019-11-21 13:47:20 +01:00
Héctor Ramón Jiménez
4b94cf0035 Add installation section to subcrate READMEs 2019-11-20 09:56:16 +01:00
Héctor Ramón Jiménez
cb4827059f Add README for each subcrate 2019-11-20 09:41:04 +01:00
Héctor Ramón Jiménez
2c8ba652a7 Draw proper checkmark for Checkbox in iced_wgpu 2019-11-14 03:34:41 +01:00
Héctor Ramón Jiménez
00479d8bcd Fix text bounds in iced_wgpu on nonintegral DPI 2019-11-14 03:00:57 +01:00
Héctor Ramón Jiménez
2337029602 Remove default styling of Button
- A background will only show if explicitly set.
- `iced_wgpu` won't apply a `min_width` of 100 units anymore.
2019-11-13 07:36:50 +01:00
Héctor Ramón Jiménez
6857829dc3 Draft Font type and implement Text::font 2019-11-13 07:22:21 +01:00
Héctor Ramón Jiménez
f0b1e65ba4 Move text logic in iced_wgpu to a text module 2019-11-13 03:54:36 +01:00
Héctor Ramón Jiménez
73f3c90007 Load default font only in measurement cache 2019-11-11 21:33:05 +01:00
Héctor Ramón Jiménez
860a6923bb Split text measurements cache from rendering cache
This speeds up layouting in the most common scenario considerably!
🎉
2019-11-11 06:07:31 +01:00
Héctor Ramón Jiménez
0240c3981b Draft custom layout engine based on druid 2019-11-11 03:08:00 +01:00
Héctor Ramón Jiménez
2303111e09 Draft new layout API 2019-11-10 01:55:32 +01:00