Preview while dragging ToolWindow, or at least set size of "blue rectangle"

Docking/MDI for WPF Forum

Posted 3 years ago by Magnus Larsson - Attentec AB
Version: 15.1.0624
Avatar

I have an application where there are distinct types of windows that the user shall arrange on the screen for best viewing. The windows typically have a "best" sort of shape, e.g., wide but low, or a specific width to height ratio. We do not allow floating windows, all windows are docked. The user can both rearrange existing toolwindows on the screen or create new toolwindows by dragging them from a menu/toolbar.

The users typically have a low computer experience, so they need all help they can get when arranging. 

The best option would of course be to have a preview of the window content while dragging a ToolWindow, so the user know what it is and what the typical shape should be, i.e., hinting to a good placement (on top for a wide and low window, side-by-side with another window for a fixed ratio window etc).

If a live preview is not possible, it wooud be good to be able to set the size of the "blue rectangle" when starting the drag. For a new window we can give it a typical size for the window type, for dragging an existing window a good behavior would be to give the rectangle the same size as the existing, docked, window.

Would this be possible to accomplish?

Thanks, Magnus

[Modified 3 years ago]

Comments (1)

Posted 3 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Magnus,

In the upcoming 2016.1 version that includes everything we've been blogging about called Docking/MDI vNext, we've made an enormous number of improvements.  One is full support for live dragging, meaning that as you tear off a docking window, it will actually undock live by default and you'll see its content as you drag, similar to how Visual Studio does it.  This feature is only active if floating is allowed though.

In your case since you disable floating windows, it will still do blue drag highlights.  However another new feature might help you out.  We have a new event that fires when a floating window is about to be created (happens even for the blue highlights).  In this event, you can specify the width/height of the floating window (or blue highlight).  The purpose of this feature is mainly to limit the initial float size of a docking window that might have been docked in a huge size.  When you start dragging, the floating window will try to be the same size as the original docked window, which could block most of the screen if it was very large.  This event lets you limit that size.  In your scenario, you could use it to also make sure the blue highlight orientation of the docking window is how you want.  And the dock size when it is dropped back down will be that size too.

Check out our blog since we are now calling for 2016.1 preview testers.


Actipro Software Support

The latest build of this product (v2018.1 build 0675) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.