Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / WPF > ToolBar > "Border" of the last selected item

Not answered "Border" of the last selected item

Feed from this thread
  • Licensing avatar

    Posted on Jan 23, 2012 (permalink)

    Hello,
    I have a RadToolBar with buttons on it. When I click on a button a "border" appears around it. After focus is moved to another control the border still remains on the button.

    Is it possible to remove that "border" after toolbar loses focus?
    Attached files

    Reply

  • Tina Stancheva Tina Stancheva admin's avatar

    Posted on Jan 26, 2012 (permalink)

    Hello,

    The border in question is the focus indication of the buttons but as the RadToolBar is a FocusScope, the focus of the controls in the toolbar isn't changed when clicking outside the toolbar. This is why the Button is still marked as focused even when moving the focus to the TextBox.

    In order to get over this you can either remove the focused state border from the RadToolBar elements or you can change the RadToolBar IsFocusScope setting:
    <telerik:RadToolBar FocusManager.IsFocusScope="False"/>

    Setting the attached property FocusManager.IsFocusScope to False will allow you to clear the focus of the RadToolBar elements when clicking outside the bar, but it can cause issues if you use ApplicationCommands.

    Basically when using application commands like Cut, Copy, Paste in a control that is in a focus scope, the commands can automatically detect the command target. However, if the RadToolBar isn't a focus scope and you want to define application commands for the bar's button controls, then you'll have to explicitly set the CommandTarget of the commands.

    Regards,
    Tina Stancheva
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

    Reply

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / WPF > ToolBar > "Border" of the last selected item
Related resources for ""Border" of the last selected item"

WPF ToolBar Features  |  Documentation  |  Demos  |  Telerik TV  |  Self-Paced Trainer  ]