I'm super enjoying my holidays as I'm finally getting a first end-to-end proof of concept of my UI prototype in C# πŸ₯³

Nothing impressive captured in this GIF πŸ˜… but the code behind is still substantial: layout machinery, Button UI styling with themed colors following WinUI3 design, dirty regions rendering, mouse events, bi-directional bindings with automatic update of the UI elements, zero alloc (apart the string!), NativeAOT optimized (under 2.3MB)

Next step: animations! πŸš€

UI code associated with the video

Look at these animations! 🀩

On every counter update, it modifies the horizontal alignment of the YStack and colors differently the sphere, while automatic binding dependencies are able to determine which variables to animate. The sample code is still a bit messy (and limited - one running animation for one visual), but it will hopefully get refined and even simpler!

And all of this is still running with delta rendering / dirty rectangles. πŸͺŸ

The POC is completed. πŸ₯³

Associated C# code
0

If you have a fediverse account, you can quote this note from your own instance. Search https://mastodon.social/users/xoofx/statuses/111658480044904207 on your instance and quote it. (Note that quoting is not supported in Mastodon.)

Been revisiting my old UI experiments again: mastodon.social/@xoofx/1116584 can't believe that was almost 2 years ago! 🀯

Looking at the code now, the whole "declarative view β†’ actual visual objects β†’ state change β†’ diffing" pipeline still feels laborious for control authoring... πŸ₯±

0