I am working on a project in which the free bits of XAML (and some related IronPython code) will be dynamically loaded and executed by the client application. The client will use the WCF user service (and some local caching) to retrieve XAML, support scripts, and related resources (icons, images, etc.).
I would like to register a custom protocol / URI scheme so that it is easier for developers of dynamic packages to reference their resources, for example:
<UserControl xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<UserControl.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="custom://MyPackage/Icons.xaml" />
<ResourceDictionary Source="custom://MyPackage/Styles.xaml" />
<!-- ^^^^^^ -->
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</UserControl.Resources>
</UserControl>
, UriParser , . , URI .
WPF, , URI? , , ?