Hacker News new | ask | show | jobs
by TheUnhinged 580 days ago
How does Avalonia do native look-and-feel? Does it use its own custom controls (with themes) or does it try to do what Qt does (using native theming APIs)?
2 comments

Avalonia draws its own controls and supports themes.

In contrast, Uno uses native controls as much as possible.

Uno Platform Dev here.

Uno currently uses some native controls on mobile iOS/Android/Catalyst (text input, mostly) to provide platform features, but the rest is rendered using graphics primitives. On Web, the same happens where CSS is used for most of the rendering. Input interactions are managed entirely by Uno. This allows to have a visually identical UI across platforms, unless the developer chooses otherwise.

On Desktop targets, Uno is rendering everything on an HW accelerated Skia canvas, with GL/Metal backends.

So does that mean you do not use winui calls anymore, but like Avalonia share the same implementation of controls across Linux and Windows?

See the diagrams from here to see what I mean: https://www.codeproject.com/Articles/5366945/Multiplatform-X...

Uno Platform is a cross platform implementation of the WinUI+WinRT APIs. That cross-platform implementation never used the official WinUI/WinAppSDK implementation on Windows.

When running on Windows, which this is where some confusion may lie, you can choose to use the Uno implementation (the netX.0-desktop TFM), or the original WinAppSDK by Microsoft (the netX.0-windows10.YYY TFM), since both implementations share the same API, making user code compatible with either ones.

On the other platforms, Wasm/Linux/iOS/Android/Catalyst/macOS, only the Uno implementation can be used.

Is the hot reload in Platform Studio limited to just UI changes or can any code in the project be hot reloaded? If the latter, what are the limitations?
Qt does custom drawing of controls as well. wxWidgets uses native controls.