Tutorial :How to show a menu on top of the window's title bar


I was trying for some time now to show a menu like this one on my WPF title bar (the orange one in the upper left corner):


I've extended the aero glass into the client area by using the DwmExtendFrameIntoClientArea method. The application icon in the upper left is not visible, and I can show the menu, but one cannot click on it, it doesn't open, and if I put for example a textbox in the title bar, I can't edit its content. I think that my controls are not on top of the title bar. How can I draw them on top of the title bar, so that the menu is clickable?


The WPF Shell Integration library might help you to get this working:

http://code.msdn.microsoft.com/WPFShell (via http://blogs.msdn.com/b/llobo/archive/2010/05/10/wpf-shell-integration-library.aspx)

"The custom chrome feature allows applications control over the outer frame of the window so that WPF content can be drawn over the title bar. This allows applications to integrate with Aero glass to emulate the Office 2007/2010 look and feel, or to completely replace the frame with its own content without having to manage all the system behaviors that get lost when using WindowStyle.None"

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »