Instead of MergedDictionary

4 posts, 0 answers
  1. Todor
    Todor avatar
    10 posts
    Member since:
    Aug 2008

    Posted 17 Mar 2009 Link to this post

    Hello,

    For the first time I saw this syntax in your Q1 Silverlight controls "<?include(SomeFile.xaml)?>". What does this means ? Is this a replacement of the MergedDictionaties sytnax ? I searched the documentation and found nothing.

    I guess it is some kind of yours custom implementation of the ResourceDictionary, but I still cannot find it.
  2. Hristo Deshev
    Admin
    Hristo Deshev avatar
    559 posts

    Posted 18 Mar 2009 Link to this post

    Hello Todor,

    Silverlight does not support merging resource dictionaries like WPF does. We have come up with a way to merge our XAML at compile time, and the <?include(SomeFile.xaml)?> parts are the directive we use to merge the file contents.

    Note that users of the controls should not have to see or care about this at all. You may need to dabble with the directives only if you are trying to compile your controls from source code.

    Sincerely yours,
    Hristo Deshev
    the Telerik team


    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  3. Todor
    Todor avatar
    10 posts
    Member since:
    Aug 2008

    Posted 18 Mar 2009 Link to this post

    Hello Hristo,

    I know that as a user of the Controls, I should not care about this. But I am using your Silverlight Implementation of the MergedDictionaries in our appplications and it works quite great. But in the source of your Q1 2009 Controls I noticed this and I thought it is some new implementation of the same mechanism which is much more elegant than the MergedDictionaries. So I thought I can ask you how to use it, since there are not much documented examples of the MergedDictionaries, I thougth there aren't much examples on this also.
  4. Hristo Deshev
    Admin
    Hristo Deshev avatar
    559 posts

    Posted 18 Mar 2009 Link to this post

    Hello Todor,

    If the resource dictionary implementation works for you, I would advise that you continue to use it. The only drawback it has is that it does not support Blend style/template editing which is crucial for our controls.

    That is why we have implemented a XAML preprocessor that is able to merge files at compile time and produce a single XAML resource that Blend can "see". The preprocessor does not come "for free" -- to use it, you would have to modify your projects' MSBuild code to include the custom tasks and targets, which is not for the faint of heart. If you really want to see how we are doing it, open a .csproj file in the source distro and search for the PreprocessXaml strings.

    Kind regards,
    Hristo Deshev
    the Telerik team


    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Back to Top