Mahapps.metro: Flyout Position top element focus inhibited by title bar

Created on 29 Nov 2016  路  4Comments  路  Source: MahApps/MahApps.Metro

What steps will reproduce this issue?

Create a window with a Flyout position "Top" with a grid inside that has a control in the top row.

If you have a control that is in the top row of a grid inside a Flyout, the title bar is in the way causing issues with the control getting focus.

In the simplest example, I use a ComboBox and can only click into the list at the barest strip of the bottom of the control.

This happens even when you set the WindowCommandsOverlayBehavior to Never. I also tried to correct this by adding a top margin to the Flyout and the title bar 'dead zone' remained.

I attached a simple example that shows the issue.

Expected outcome

I would expect that the title bar area would be taken into account when the Flyout is shown on the top allowing the control it is obscuring to work properly.

A work around for the time being is in any Flyout that is position "Top" with a grid inside, too add an 'empty' row that contains a label with no content. Then the Flyout will allocate space to the top of the Flyout to account for the title bar.

--

Environment

  • MahApps.Metro __v1.3.0
  • Windows 10 and Windows 7_
  • Visual Studio 2013 Professional and Visual Studio 2015 Community
  • .NET Framework 4.5.1 and 4.5.2
    FlyoutTopIssue.zip
Bug

All 4 comments

@economypowers This will be fixed in 1.4.0. The draggable area is now really only the header (the complete header now) of the Flyout itself.

/cc @thoemmi Now the complete header area is allowed to drag the window. I think this is a better solution instead to restrict it to the TitleBarHeight.

To remove the window buttons you can set WindowButtonCommandsOverlayBehavior="HiddenTitleBar" on the MetroWindow.

2016-12-06_10h03_05

LGTM. The code is much simpler now 馃憤

Thank you for the wonderfully fast response. I will be looking forward to the next release.

@economypowers You can use and test pre-release 1.4.0-ALPHA036

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Coder-Bryan picture Coder-Bryan  路  3Comments

johanneswanzek picture johanneswanzek  路  3Comments

somil55 picture somil55  路  3Comments

AzureZeng picture AzureZeng  路  3Comments

WillSullivan picture WillSullivan  路  5Comments