RibbonView with MVVM

4 posts, 0 answers
  1. yoochul
    yoochul avatar
    15 posts
    Member since:
    Feb 2014

    Posted 07 May 2014 Link to this post

    HI,

    I want to change default image and show text in "Paint with MVVM" Sample.
    Please, show attach file.

    Thank you.
  2. Pavel R. Pavlov
    Admin
    Pavel R. Pavlov avatar
    1182 posts

    Posted 08 May 2014 Link to this post

    Hello,

    When working with the RadRibbonView control you need to have in mind that its RadRibbonGroup control expose Icon property that can be used to customize the referenced picture. Furthermore, there is no string visualized because the RadRibbonGroup that is added in the referenced demo has its Header property not set. You need to set the Header of a group in order to visualize a string when the group is in collapsed variant. You can find more information in our RibbonGroup article

    I hope this information is helpful.

    Regards,
    Pavel R. Pavlov
    Telerik
     
    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
     
  3. UI for WPF is Visual Studio 2017 Ready
  4. yoochul
    yoochul avatar
    15 posts
    Member since:
    Feb 2014

    Posted 08 May 2014 in reply to Pavel R. Pavlov Link to this post

    I know icon, header in RadRibbonGroup

    But,  I can't find how to access RadRibbonGroup in xaml or code in "Paint with MVVM" sample.

    I want to code(or Xaml) sample to insert text('MyText') first RadRibbonGroup header;
  5. Kiril Vandov
    Admin
    Kiril Vandov avatar
    324 posts

    Posted 12 May 2014 Link to this post

    Hi,

    It turns out that there is a bug in the RadRibbonGroup control and its header is not displayed when used in data-bound scenario via HierarchicalDataTemplate. We have logged that bug in our system and you could track its progress in our feedback portal. I have also updated your Telerik points as a small sign of appreciation for your cooperation.

    However until this bug is fixed you could use a custom style for the RadRibbonGroup as a workaround. The problem is caused by the DropDownButton ( you can find that button by searching for x:Name="CollapsedButton" in the template) which is shown when the group is in collapsed state. In the current implementation we have binding to the button's TextProperty which is of type string, the HeaderProperty of the group is of type object and that is why the binding is failing. If we change the binding to target the Content property of the button the header is displayed as expected.

    I have attached a sample project with the customized style for your convenience.

    Please excuse us for any inconvenience caused.

    Regards,
    Kiril Vandov
    Telerik
     
    Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
     
Back to Top