Windows-rs: Support for creating composable types

Created on 18 May 2020  路  3Comments  路  Source: microsoft/windows-rs

Is it possible to use the Xaml Island with this crate in Rust?

It seems that it's very difficult to create the DesktopWindowXamlSource class which is under a ComposableAttribute and should be created via a factory class(IDesktopWindowXamlSourceFactory) which is undocumented.

If further efforts are planed to make, I am wondering if you could share any information on when that will be scheduled? Thanks.

enhancement

Most helpful comment

It should be possible, although it is not simple. There are a few issues that need to be addressed before broader Xaml support becomes more feasible including #119 #92 #91 and #81

We're working hard at these remaining issues. It may still be some time, but the goal is to make procedural Xaml (at the very least) very simple with Rust.

All 3 comments

It should be possible, although it is not simple. There are a few issues that need to be addressed before broader Xaml support becomes more feasible including #119 #92 #91 and #81

We're working hard at these remaining issues. It may still be some time, but the goal is to make procedural Xaml (at the very least) very simple with Rust.

I've got a working XAML Island, see https://github.com/roblabla/ubuntu-installer

In particular the DesktopWindowXamlSource can be created with winrt::factory, see https://github.com/roblabla/ubuntu-installer/blob/master/src/main.rs#L33

Yes, once we're done you'll be able to use use something like this:

let source = DesktopWindowXamlSource::new()?;

I'm going to reopen this issue to support this simple construction code generation before the full authoring support arrives.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Susurrus picture Susurrus  路  3Comments

13r0ck picture 13r0ck  路  4Comments

joverwey picture joverwey  路  3Comments

DJankauskas picture DJankauskas  路  3Comments

AyashiNoCeres picture AyashiNoCeres  路  4Comments