Runtime Appearance Doesn't Match VSB Preview

3 posts, 0 answers
  1. kyle kepley
    kyle kepley avatar
    1 posts
    Member since:
    Oct 2009

    Posted 08 Oct 2009 Link to this post

    Hello,   I am evaluating your product to make sure I can get it to work before I buy it and am having some problems making a custom theme in Visual Style Builder.  I am working on making a customized combo box and am having two problems:

    1) If I  put a fill gradient on the RadComboBoxItem->FillPrimitive, it shows up fine in the design and preview images in VSB but it's just a plain white background when the combo drop-down appears in the application.  When I go back into VSB the fill setting is still there, so it is getting saved. Run time doesn't match design time.

    2) In VSB, some of the design elements don't seem to change color to reflect changes I've made.  For example, in the combo box I'm working on, all the elements in the combo box reflect the settings correctly but nothing I do with the scroll bars in the dropdown list  seems to effect the design and preview images.  If I click the ScrollBarButton->FillPrimitive in the tree and change the BackColor in either the Expert Mode properties or by picking a color in the Initial State tab, the design and preview images do not reflect these changes.  The control also doesn't reflect these changes in the app at runtime.  Is there something that locks out these changes or overrides what I am doing?

    My method of using the theme was to drop a radThemeManager on the form, open the Telerik theme, make my changes and then saved it as a new theme under a different name.  I then used the theme manager option "load theme from file", and finally picked the theme name on the control's menu which is using it.  It gets the combo box part of the custom theme correct, but ignores anything I do to the drop down portion of the combo box.

    I'm running Visual Studio 2005 on XP.

  2. Deyan
    Deyan avatar
    2147 posts

    Posted 12 Oct 2009 Link to this post

    Hi Kyle,

    Thanks for contacting us and for your interest in RadControls for WinForms. I have investigated the case and it seems to be an issue with StylesheetRelations in RadComboBox control. The StylesheetRelations are defined in an XML file and they determine which elements are styles in the applied theme.

    However, there is a quick and easy way to circumvent this. I have prepared a few simple steps which should guide you through:

    1. Open the XML theme in a text editor and find the following construct:

            <RadStylesheetRelation ControlType="ComboPopupForm" ElementType="Telerik.WinControls.UI.RadFormElementOld" ControlName="" ElementName="" />

    2. Change the ElementType from Telerik.WinControls.UI.RadFormElementOld to Telerik.WinControls.UI.RadFormElement

    3. Save the XML theme and load it by using RadThemeManager. You should be able to see your custom modifications now.

    The theming of the scrollbars in RadComboBox is done separately in Visual Style Builder. To achieve this, you should open RadHScrollbar and RadVScrollbar in Visual Style Builder, and create your custom themes as you did with RadComboBox. Please note that you should give the themes for the scrollbars the same name as the theme name for RadComboBox.

    Note: You do not need to do XML modifications above for the themes of the scrollbars (since they address an issue in RadComboBox itself).

    I would also like to inform you that we are working on an entirely new theming mechanism which should make the styling of our controls an easy and straightforward process. We are also designing a new and improved Visual Style Builder which is going to make use of the strengths of this mechanism by providing the user with a repository of predefined styles and shapes.

    I hope my hints are helpful and I would be happy if you share with us any feedback you might have regarding the usage of RadControls for WinForms.

    Thanks for your time.

    Kind regards,
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. Stefan
    Stefan avatar
    2911 posts

    Posted 17 Mar 2011 Link to this post

    Hello kyle,

    I am glad to inform you that Q1 2011 is released and the VSB theme preview is greatly improved. Additionally, VSB has a functionality to start the newly introduced tool - ThemeViewer - which gives you the ability to preview the created theme of all RadControls for WinForms together. For more information refer to this blog post.

    I am writing  
    All the best,
    the Telerik team

Back to Top