Change fill of mimize, window state and close buttons

2 posts, 0 answers
  1. lkeel
    lkeel avatar
    115 posts
    Member since:
    Jul 2012

    Posted 14 Sep 2009 Link to this post

    Let me start by saying I am new to the Visual Style Builder.  I have found that the delivered themes have been sufficient in the past.  However, my company has recently mandated common UI schemes and therefore it seems easier to create separate theme than to try and manage all applications colors.  So with that said...

    I have a ShapedForm with a RibbonBar at the top.  I want to change the backcolors of the three buttons at the top of the form.  I found how to do it, but when I change one, it changes all three.  How do I change each one individually?  Just as an example (and this is not exactly the case, but) what if I want the minimize button to have green back color, the window state button to have blue and the close button to have red back color.  Is there a way to do this?

    Also, how do I change the image for these buttons?  I have tried clicking on the image for the button, but it will not let me set a new image.

    Thanks in advance,
  2. Deyan
    Deyan avatar
    2147 posts

    Posted 17 Sep 2009 Link to this post

    Hello Lee,

    Thanks for contacting us and for your questions. Our theming mechanism makes use of some of CSS concepts used in the styling of websites. That said, our elements have different class names and our stylesheets define appearance for the different classes. RadRibbonBar control defines different classes for its system buttons but does not define different class names for the primitives that build these buttons (fills, borders etc.). Therefore, when you set properties for a FillPrimitive of one of these buttons, the settings are applied to the other two buttons.

    Currently, these buttons use images to represent their mouse over, mouse down and normal states. These images are set directly to RadImageButtonElement object by using the Image, ImageHovered, and ImageClicked properties -- you can see these settings in Visual Style Builder. RadImageButtonElement that represents a single button can also have a class. The minimize, maximize, and close buttons in the RadRibbonBar control all define different class names on RadImage ButtonElement level and therefore you will be able to set different images for the properties mentioned above for each button. My advice is to use images to style your buttons and achieve the effect of having different colors for the system buttons.

    I hope this is helpful. Do not hesitate to write back if you need further assistance.

    Best wishes,
    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.
Back to Top