RadToolBarButton disabled text color

7 posts, 0 answers
  1. Mark
    Mark avatar
    35 posts
    Member since:
    Nov 2008

    Posted 23 Jul 2014 Link to this post

    Hi,

    I recently changed one of my Telerik web applications over to the "silk" theme, as it seems very well done indeed.

    However, I have a minor problem. In my RadToolbar instances, it's very difficult to read the text of RadToolbarButtons when they are disabled. The disabled text color is simply too light.

    I'm attaching a screenshot of my application toolbar so you can see what I mean. The "restore" and "edit" buttons are both disabled, and their captions are very difficult to read.

    How can I change the text color for these disabled buttons?
  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 24 Jul 2014 in reply to Mark Link to this post

    Hi Mark,

    Please try the below C# code snippet to change the color of a disabled RadToolBarButton.

    C#:
    protected void Page_Load(object sender, EventArgs e)
    {
        foreach (RadToolBarButton toolbarButton in RadToolBar1.GetAllItems())
        {
            if (toolbarButton.Enabled == false)
            {
                toolbarButton.ForeColor = System.Drawing.Color.Green;
            }
        }
    }

    Thanks,
    Shinu.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Mark
    Mark avatar
    35 posts
    Member since:
    Nov 2008

    Posted 24 Jul 2014 in reply to Shinu Link to this post

    Thanks, that does the trick.

    Moving forward, I'd like to see Telerik re-consider the default disabled button text color.
  5. Magdalena
    Admin
    Magdalena avatar
    421 posts

    Posted 29 Jul 2014 Link to this post

    Hello Mark,

    Thank you for reporting this issue. We will improve the layout of disabled button in Silk skin. The better workaround for preliminary solution is to set the color with an additional CSS
    html .RadToolBar_Silk .rtbDisabled .rtbWrap {
        color: #999;
    }


    Regards,
    Magdalena
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. Mark
    Mark avatar
    35 posts
    Member since:
    Nov 2008

    Posted 29 Jul 2014 in reply to Magdalena Link to this post

    Thanks, Magdalena.

    How can I apply the same styling to disabled RadMenu items?
  7. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 29 Jul 2014 in reply to Mark Link to this post

    Hi Mark,
     
    Please try the below CSS code snippet to change the fore color of the disabled RadMenuItem.

    CSS:
    .RadMenu_Silk .rmRootLink.rmDisabled
    {
        color: Gray !important;
    }
    .RadMenu_Silk .rmGroup .rmLink.rmDisabled
    {
        color: Gray !important;
    }

    Thanks,
    Shinu.
  8. Magdalena
    Admin
    Magdalena avatar
    421 posts

    Posted 01 Aug 2014 Link to this post

    Hi Mark,

    Disabled items in RadMenu have set the opacity property. If you would like the color to be exactly the same as in the ToolBar after the customization, you should remove the opacity and after that set the same color by the following:
    html .RadMenu .rmRootGroup .rmDisabled > .rmLink {
        opacity: 1;
        color: #999;
    }


    Regards,
    Magdalena
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017