Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
180
Focus gets lost when using Ribbon
posted

I have an app that is using XamRibbonWindow, a suitable ribbon menu (not too complicated yet), and a series of "forms" that appear based on the menu selections.  Each form is simply a UserControl that contains the usual kinds of items including some Xam..Editors and regular WPF controls.  The "form" is placed in a simple tab control that is being hosted by the window's content host item.

The last item in the tab sequence experiences some strange behavior as you tab out of it.  The item that gets the focus is in the Ribbon and, of course, the style of that item doesn't show focus (and probably shouldn't).  I used snoop.exe to find out some of this.  Basically, the ButtonTool immediately after my item (a textbox) is marked both Focusable and IsTabStop.  I turned that off in the style and that stopped the ButtonTools from getting any focus.  But, ApplicationMenuPresenter grabs it and you are pretty much lost after that.  No tabbing ever gets you out of the ribbon.

I suppose I could keep digging and wrestle focus back into my objects, but that doesn't seem like the right thing to do.

Is there a simple thing I'm missing to get the ribbon to stop participating in the tab sequence?  I just want it to tab around to the next keyboard-focusable control on the window.  Perhaps this is something I should post as a problem with the ribbon.

Thanks for the help.

Dave

Parents
No Data
Reply
  • 9694
    posted

    Thank you for taking the time detail this issue.

    I can reproduce the issue. I consider it a bug. If you would, please report the issue to our developer support department:
    http://devcenter.infragistics.com/Protected/SubmitSupportIssue.aspx

    You can set Focusable to false for the xamRibbon. Unfortunately, if the user explicitly moves keyboard focus to the ApplicationMenu, it will not be relinquished until the user clicks back into the content. If you request a work-around, engineering may be able to come up with one (perhaps there is an event you can respond to where you could explicitly reset keyboard focus back into your content).

    Thank you,

Children
No Data