This project is read-only.

How to make the DocumentPane behave like the VS2010 one?

Mar 13, 2010 at 11:24 AM

I have been using VS2010 lately,

The text editor in VS2010 can be dragged out of the main window and can be maximized in

my second monitor, I found this functionality really useful.

So I wonder can we do this by using AvalonDock?

Thank you!

Mar 13, 2010 at 7:15 PM

try to change in DocumentFloatingWindow.cs  in

public DocumentFloatingWindow(DockingManager manager, DocumentContent content)
            : this(manager)



            if (IsDocumentFloatingAllowed)
                AllowsTransparency = false;
                WindowStyle = WindowStyle.ToolWindow;


            if (IsDocumentFloatingAllowed)
                AllowsTransparency = false;
                WindowStyle = WindowStyle.SingleBorderWindow;

It should work.


Ado, is it a problem to add a property (DefaultDocumentFloatingWindowStyle or something else) for that?
Maybe it's usefull for other users.


Mar 15, 2010 at 2:50 AM

I tried it , and it worked.

Thanks a lot!

Mar 15, 2010 at 8:34 AM

But there is a little problem.

The dragged-out DocumentContent is not treated like a real window in Win7.

By real window I mean a window which can be maximized by being dragged to the top of the

screen and can be docked by being dragged to the left or right side of the screen.


Is there any possible way so solve this?


Mar 15, 2010 at 10:26 PM

I think it's based on the drag-drop system of AvalonDock.
Maybe it overrides some system messages.

I don't know exactly. Maybe Ado can answer this question.

Mar 16, 2010 at 8:33 AM

Never mind

I figured it out

Just right click on the dragged-out DocumentContent and select "Floating"

Then it's all OK.

Mar 17, 2010 at 9:15 PM

Maybe it's possible to do this automatically.
When you drag the window out of the DockingManager it should be in FloatingMode.
If it's inside it should be in DockingMode.

I'll have to check this.

Apr 30, 2010 at 6:09 PM

Have you figured out a way to automatically switch between FloatingMode and DockingMode based on whether you are inside or outside the DockingManager area?