From e60af00f905321fca2fe39e6263e1f77ff430f24 Mon Sep 17 00:00:00 2001 From: DevExpressExampleBot Date: Thu, 23 Jun 2022 21:26:22 +0400 Subject: [PATCH 1/8] README auto update [skip ci] --- Readme.md | 41 ++++++++++++++++++++--------------------- 1 file changed, 20 insertions(+), 21 deletions(-) diff --git a/Readme.md b/Readme.md index 9320ec8..f273dd6 100644 --- a/Readme.md +++ b/Readme.md @@ -1,21 +1,20 @@ - -![](https://img.shields.io/endpoint?url=https://codecentral.devexpress.com/api/v1/VersionRange/128643681/21.1.5%2B) -[![](https://img.shields.io/badge/Open_in_DevExpress_Support_Center-FF7200?style=flat-square&logo=DevExpress&logoColor=white)](https://supportcenter.devexpress.com/ticket/details/E4845) -[![](https://img.shields.io/badge/πŸ“–_How_to_use_DevExpress_Examples-e9f6fc?style=flat-square)](https://docs.devexpress.com/GeneralInformation/403183) - - -*Files to look at*: - -* [DockLayoutManagerExt.cs](./CS/DXDockingForLayoutPurposes/DockLayoutManagerExt.cs) (VB: [DockLayoutManagerExt.vb](./VB/vb_DXDockingForLayoutPurposes/DockLayoutManagerExt.vb)) -* [Helpers.cs](./CS/DXDockingForLayoutPurposes/Helpers.cs) (VB: [Helpers.vb](./VB/vb_DXDockingForLayoutPurposes/Helpers.vb)) -* [MainWindow.xaml](./CS/DXDockingForLayoutPurposes/MainWindow.xaml) (VB: [MainWindow.xaml](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml)) -* [MainWindow.xaml.cs](./CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs) (VB: [MainWindow.xaml.vb](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml.vb)) - -# How to limit LayoutGroup customization at runtime - - -

We have prepared an example demonstrating how to limit LayoutGroup customization at runtime.

To provide this functionality, we created a DockLayoutManager class descendant and the attached DisableCrossingGroupBoundaries property. The DisableCrossingGroupBoundaries property can be attached only to the LayoutGroup.

In this case, the LayoutGroup with the property assigned to true allows any customization and prevents moving inner elements outside LayoutGroup boundaries. For the LayoutGroup without this property, the default logic is used for arranging elements.

- -
- - + +[![](https://img.shields.io/badge/Open_in_DevExpress_Support_Center-FF7200?style=flat-square&logo=DevExpress&logoColor=white)](https://supportcenter.devexpress.com/ticket/details/E4845) +[![](https://img.shields.io/badge/πŸ“–_How_to_use_DevExpress_Examples-e9f6fc?style=flat-square)](https://docs.devexpress.com/GeneralInformation/403183) + + +*Files to look at*: + +* [DockLayoutManagerExt.cs](./CS/DXDockingForLayoutPurposes/DockLayoutManagerExt.cs) (VB: [DockLayoutManagerExt.vb](./VB/vb_DXDockingForLayoutPurposes/DockLayoutManagerExt.vb)) +* [Helpers.cs](./CS/DXDockingForLayoutPurposes/Helpers.cs) (VB: [Helpers.vb](./VB/vb_DXDockingForLayoutPurposes/Helpers.vb)) +* [MainWindow.xaml](./CS/DXDockingForLayoutPurposes/MainWindow.xaml) (VB: [MainWindow.xaml](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml)) +* [MainWindow.xaml.cs](./CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs) (VB: [MainWindow.xaml.vb](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml.vb)) + +# How to limit LayoutGroup customization at runtime + + +

We have prepared an example demonstrating how to limit LayoutGroup customization at runtime.

To provide this functionality, we created a DockLayoutManager class descendant and the attached DisableCrossingGroupBoundaries property. The DisableCrossingGroupBoundaries property can be attached only to the LayoutGroup.

In this case, the LayoutGroup with the property assigned to true allows any customization and prevents moving inner elements outside LayoutGroup boundaries. For the LayoutGroup without this property, the default logic is used for arranging elements.

+ +
+ + From ce6849b96af9854e84379c0ffd392610093940d6 Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Thu, 23 Jun 2022 21:34:19 +0400 Subject: [PATCH 2/8] Create Readme.md --- Readme.md | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/Readme.md b/Readme.md index f273dd6..a06cfc4 100644 --- a/Readme.md +++ b/Readme.md @@ -1,20 +1,28 @@ +![](https://img.shields.io/endpoint?url=https://codecentral.devexpress.com/api/v1/VersionRange/128643681/21.1.5%2B) [![](https://img.shields.io/badge/Open_in_DevExpress_Support_Center-FF7200?style=flat-square&logo=DevExpress&logoColor=white)](https://supportcenter.devexpress.com/ticket/details/E4845) [![](https://img.shields.io/badge/πŸ“–_How_to_use_DevExpress_Examples-e9f6fc?style=flat-square)](https://docs.devexpress.com/GeneralInformation/403183) + +# WPF Dock Layout Manager - Limit LayoutGroup Customization at Runtime + +This example limits [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) customization at runtime. + + + +This example contains a [DockLayoutManager](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.DockLayoutManager) class descendant and the attached `DisableCrossingGroupBoundaries` property. You can attach the `DisableCrossingGroupBoundaries` property only to the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup). + +In this case, the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) with the property assigned to `true` allows any customization and prevents moving inner elements outside [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) boundaries. For the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) without this property, the default logic is used for arranging elements. + -*Files to look at*: +## Files to Look At * [DockLayoutManagerExt.cs](./CS/DXDockingForLayoutPurposes/DockLayoutManagerExt.cs) (VB: [DockLayoutManagerExt.vb](./VB/vb_DXDockingForLayoutPurposes/DockLayoutManagerExt.vb)) * [Helpers.cs](./CS/DXDockingForLayoutPurposes/Helpers.cs) (VB: [Helpers.vb](./VB/vb_DXDockingForLayoutPurposes/Helpers.vb)) * [MainWindow.xaml](./CS/DXDockingForLayoutPurposes/MainWindow.xaml) (VB: [MainWindow.xaml](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml)) * [MainWindow.xaml.cs](./CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs) (VB: [MainWindow.xaml.vb](./VB/vb_DXDockingForLayoutPurposes/MainWindow.xaml.vb)) -# How to limit LayoutGroup customization at runtime - - -

We have prepared an example demonstrating how to limit LayoutGroup customization at runtime.

To provide this functionality, we created a DockLayoutManager class descendant and the attached DisableCrossingGroupBoundaries property. The DisableCrossingGroupBoundaries property can be attached only to the LayoutGroup.

In this case, the LayoutGroup with the property assigned to true allows any customization and prevents moving inner elements outside LayoutGroup boundaries. For the LayoutGroup without this property, the default logic is used for arranging elements.

- -
+## Documentation +- [Manage Dock Panels in Code](https://docs.devexpress.com/WPF/15540/controls-and-libraries/layout-management/dock-windows/miscellaneous/managing-dock-panels-in-code) From 8b9b484396ece16141584efa952d42e65db5a600 Mon Sep 17 00:00:00 2001 From: DevExpressExampleBot Date: Thu, 23 Jun 2022 21:40:02 +0400 Subject: [PATCH 3/8] README auto update [skip ci] --- Readme.md | 1 - 1 file changed, 1 deletion(-) diff --git a/Readme.md b/Readme.md index a06cfc4..32f761e 100644 --- a/Readme.md +++ b/Readme.md @@ -1,5 +1,4 @@ -![](https://img.shields.io/endpoint?url=https://codecentral.devexpress.com/api/v1/VersionRange/128643681/21.1.5%2B) [![](https://img.shields.io/badge/Open_in_DevExpress_Support_Center-FF7200?style=flat-square&logo=DevExpress&logoColor=white)](https://supportcenter.devexpress.com/ticket/details/E4845) [![](https://img.shields.io/badge/πŸ“–_How_to_use_DevExpress_Examples-e9f6fc?style=flat-square)](https://docs.devexpress.com/GeneralInformation/403183) From 799b974e1a8ba8660f6fc2ebb18ff82bc6b85bbb Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Thu, 23 Jun 2022 23:42:39 +0400 Subject: [PATCH 4/8] Update MainWindow.xaml --- CS/DXDockingForLayoutPurposes/MainWindow.xaml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/CS/DXDockingForLayoutPurposes/MainWindow.xaml b/CS/DXDockingForLayoutPurposes/MainWindow.xaml index f2d4cd1..5598550 100644 --- a/CS/DXDockingForLayoutPurposes/MainWindow.xaml +++ b/CS/DXDockingForLayoutPurposes/MainWindow.xaml @@ -1,4 +1,4 @@ - - - - - + dx:ThemeManager.ThemeName="VS2019Light"> + + @@ -90,11 +87,8 @@ - - - - + From a977d50915958555f25d1c72fb684f627472889c Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Thu, 23 Jun 2022 23:43:12 +0400 Subject: [PATCH 5/8] Update MainWindow.xaml.cs --- .../MainWindow.xaml.cs | 24 +++---------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs b/CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs index 7192e67..111b6cf 100644 --- a/CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs +++ b/CS/DXDockingForLayoutPurposes/MainWindow.xaml.cs @@ -1,31 +1,13 @@ -ο»Ώusing System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Windows; -using System.Windows.Controls; -using System.Windows.Data; -using System.Windows.Documents; -using System.Windows.Input; -using System.Windows.Media; -using System.Windows.Media.Imaging; -using System.Windows.Markup; using DevExpress.Xpf.Core; -using DevExpress.Xpf.Ribbon; -using DevExpress.Xpf.Layout.Core; -using DevExpress.Xpf.Docking; -using DevExpress.Xpf.Docking.Base; -using DevExpress.Xpf.Docking.VisualElements; -using DevExpress.Xpf.Grid; -using DevExpress.Xpf.Core.Native; using System.ComponentModel; using System.Collections.ObjectModel; -namespace DXDockingForLayoutPurposes { +namespace DXDockingForLayoutPurposes +{ /// /// Interaction logic for MainWindow.xaml /// - public partial class MainWindow : DXRibbonWindow { + public partial class MainWindow : ThemedWindow { public MainWindow() { InitializeComponent(); DataContext = new DataSource(); From e7da7b070fa1adbd54652627591b53bb355251ce Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Fri, 24 Jun 2022 11:28:52 +0400 Subject: [PATCH 6/8] Update Readme.md Co-authored-by: Albert Totten <49917542+albertov05@users.noreply.github.com> --- Readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Readme.md b/Readme.md index 32f761e..d0592a9 100644 --- a/Readme.md +++ b/Readme.md @@ -9,7 +9,7 @@ This example limits [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf -This example contains a [DockLayoutManager](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.DockLayoutManager) class descendant and the attached `DisableCrossingGroupBoundaries` property. You can attach the `DisableCrossingGroupBoundaries` property only to the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup). +The example contains a [DockLayoutManager](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.DockLayoutManager) class descendant and the attached `DisableCrossingGroupBoundaries` property. You can attach the `DisableCrossingGroupBoundaries` property only to the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup). In this case, the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) with the property assigned to `true` allows any customization and prevents moving inner elements outside [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) boundaries. For the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) without this property, the default logic is used for arranging elements. From 8b5e57c7d7d51ded37ebf26402a86f1d971b8336 Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Fri, 24 Jun 2022 11:30:18 +0400 Subject: [PATCH 7/8] Update Readme.md --- Readme.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Readme.md b/Readme.md index d0592a9..3f0fea8 100644 --- a/Readme.md +++ b/Readme.md @@ -11,7 +11,8 @@ This example limits [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf The example contains a [DockLayoutManager](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.DockLayoutManager) class descendant and the attached `DisableCrossingGroupBoundaries` property. You can attach the `DisableCrossingGroupBoundaries` property only to the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup). -In this case, the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) with the property assigned to `true` allows any customization and prevents moving inner elements outside [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) boundaries. For the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) without this property, the default logic is used for arranging elements. +In this case, a [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) with the property assigned to `true` allows users to customize the group and prevents them moving inner elements outside [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) boundaries. For the [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Docking.LayoutGroup) without this property, the default logic is used for arranging elements. + ## Files to Look At From a155b8333a06c240754d2fc95963301c8c28fbcd Mon Sep 17 00:00:00 2001 From: Anthony Sam Date: Fri, 24 Jun 2022 11:31:45 +0400 Subject: [PATCH 8/8] Update Readme.md --- Readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Readme.md b/Readme.md index 3f0fea8..fe3fcda 100644 --- a/Readme.md +++ b/Readme.md @@ -25,4 +25,4 @@ In this case, a [LayoutGroup](https://docs.devexpress.com/WPF/DevExpress.Xpf.Doc ## Documentation -- [Manage Dock Panels in Code](https://docs.devexpress.com/WPF/15540/controls-and-libraries/layout-management/dock-windows/miscellaneous/managing-dock-panels-in-code) +- [Runtime Layout Customization](http://docs.devexpress.devx/WPF/7222/)