Commit graph

16 commits

Author SHA1 Message Date
Jonathan Johnson
6726855ed0
Cleaning up figures usage in examples 2024-07-26 10:34:30 -07:00
Jonathan Johnson
76a42e2788
Updated to wgpu 0.19.0
Most of the changes were figures-related. Go figure.
2024-01-18 06:37:29 -08:00
Jonathan Johnson
e70e92726c
Source<T> + Destination<T> (breaking)
Refs #98

This refactor overhauls the reactive system to move all the reactive
methods to traits. The side effect of this change is that now
DynamicReader's API is the same as Dynamic's API, but because it only
implements Source<T>, DynamicReader does not offer any mutation
functions.

While it's unfortunate to have more traits to include to use Cushy, this
seems like the best option, and it offers a path to try to integrate
this into the tuple ForEach/MapEach traits. Unfortunately, my attempt at
doing those in this set of changes led to issues specifying generic
associated lifetimes for the DynamicGuard. But, I was also in the middle
of this larger refactoring, so it might be that a fresh attempt will
succeed.
2024-01-02 09:00:29 -08:00
Jonathan Johnson
2fe28729df
Directly depending on figures
While this was a workaround for a docs.rs issue (Px/Lp are not
linked), I decided having the shorter import path would look better in
the examples.

It probably wasn't necessary to update all of the references in the
internal code, but I decided it was worth the consistency.
2023-12-28 09:35:24 -08:00
Jonathan Johnson
df479e983e
Renaming crate to Cushy
Refs #117
2023-12-27 19:02:59 -08:00
Jonathan Johnson
f1a2a711ff
Multi-window support
Closes #91

There's some details to still figure out, which are in new issues:

- #109: When opening a window, no handle is returned that gives access to the
  window from the opener. Technically this can all be wired up manually,
  with exception of requeesting the window close.
- #107: How can a window close itself? Once we have a handle type, we still
  need a mechanism to allow a button on a window request that the window
  closes gracefully. The examples that currently close the window
  call exit instad.
2023-12-21 14:57:29 -08:00
Jonathan Johnson
5c720e6009
Align + Overlay + Shadow fixes
- Blur no longer expands the shadow geometry, but instead is clamped to
  avoid overlapping drawing calls.
- Overlay now handles hit tests correctly with regards to the original
  relative widget.
- Align was using an Into conversion that wasn't actually correct,
  causing the contents to not actually get aligned in some situations.
2023-12-13 08:26:09 -08:00
Jonathan Johnson
a7efe9a3d5
Container Shadows 2023-12-12 13:49:03 -08:00
Jonathan Johnson
55eea5fad3
Added Copy to Clipboard to theme editor
This also wires up the beginnings of the application type
2023-12-03 07:38:56 -08:00
Jonathan Johnson
e15ae59c5c
Refactored root resize behavior
Closes #84, Closes #77, Closes #78
2023-11-25 12:00:59 -08:00
Jonathan Johnson
4a4bc5de1a
Added slidable enum demo
Also moved into_button to MakeWidget
2023-11-14 11:44:32 -08:00
Jonathan Johnson
4c7c3be5ba
Helpers galore 2023-11-14 09:31:56 -08:00
Jonathan Johnson
ca81c3702c
Updating examples 2023-11-14 08:02:31 -08:00
Jonathan Johnson
a04619a279
Layout caching, Lerp underflow fix, label fix 2023-11-14 07:38:39 -08:00
Jonathan Johnson
40343e163f
Scroll fixes, resize helpers 2023-11-13 11:30:45 -08:00
Jonathan Johnson
96d407ddc2
Container, query_parent_style 2023-11-12 13:37:32 -08:00