Closed imJack6 closed 2 months ago
This is a limitation of Rider's (already quite flawed) XAML previewer. It never worked particularly well for WPF, subsequently it works even less competently for Avalonia. In this case it's because we use some Skia APIs for rendering and the previewer doesn't seem to support them.
It's not something we're in a position to fix unfortunately, my only advice would be to avoid using the previewers for any SukiWindow
.
Just thought I'd quickly follow up, I'd like to know if this happens in VS too - if anyone who has VS set up locally already could just open a SukiWindow in the previewer and let me know I'd be grateful. Rider's AXAML previewer is actually part of a 3rd party plugin so if that's the source of the issue I'd like to chase that up rather than trying to implement workarounds on our end.
I fail on the same code pathway in VS using SukiUI.Demo
I just downloaded Visual Studio 2022 Community to try it out and it also doesn't work for SukiWindow Avalonia=11.2.0-beta1 SukiUI=6.0.0-beta8
Excellent. I'll get a minimal repro together and push this up to Avalonia. If this isn't something they can or want to fix then we have some scope to implement workarounds if they're necessary (though I'd rather not) or in the worst case document this issue clearly.
Looks like this is by design and in fact platforms such as web do actually require software rendering fallbacks.
I'll take a look at this tomorrow, hopefully I can put together a gracefull fallback that will allow the previewer to work and open up the opportunity to support web possibly in the future as well as apparently Linux/MacOS VM's which tend to fall back to software rendering.
doesn't work for `
Check the following items
Description of the issue
rt, when I look at the preview window after building, a white window is displayed first, and then the following error appears:
Package Version
6.0.0-beta8
Environment
Windows 11 22631
Expected Behavior
SukiWindow can be previewed using Rider IDE
Reproduction
Use Rider IDE, follow the documentation to install SukiUI, and see the preview of MainWindow
Additional Information
No response