-
Notifications
You must be signed in to change notification settings - Fork 336
Open
Description
Using Auto
for DockHeight
on a LayoutAnchorablePane
works some of the time when editing the XAML in Visual Studio but doesn't work at run time. Here's a simple example that demonstrates the problem:
<Window x:Class="MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:avalonDock="clr-namespace:AvalonDock;assembly=AvalonDock"
xmlns:avalonDockLayout="clr-namespace:AvalonDock.Layout;assembly=AvalonDock"
xmlns:local="clr-namespace:AutoDockHeightTest"
mc:Ignorable="d"
Title="Auto Dock Height"
Height="450"
Width="800">
<Grid>
<avalonDock:DockingManager x:Name="dockingManager"
AllowMixedOrientation="True">
<avalonDockLayout:LayoutRoot x:Name="layoutRoot">
<avalonDockLayout:LayoutPanel x:Name="mainLayoutPanel"
Orientation="Vertical">
<avalonDockLayout:LayoutAnchorablePane DockHeight="Auto"
Name="autoSizePane">
<avalonDockLayout:LayoutAnchorable Title="Auto Size">
<Border Background="Aquamarine">
<Expander Header="Auto Size Anchorable">
<Border Background="Fuchsia"
Height="100">
<TextBlock Text="Hidden content" />
</Border>
</Expander>
</Border>
</avalonDockLayout:LayoutAnchorable>
</avalonDockLayout:LayoutAnchorablePane>
<avalonDockLayout:LayoutAnchorablePane DockHeight="*"
Name="relativeSizePane">
<avalonDockLayout:LayoutAnchorable Title="Relative Size">
<Border Background="Aquamarine">
<TextBlock Text="Relative Size Anchorable" />
</Border>
</avalonDockLayout:LayoutAnchorable>
</avalonDockLayout:LayoutAnchorablePane>
</avalonDockLayout:LayoutPanel>
</avalonDockLayout:LayoutRoot>
</avalonDock:DockingManager>
</Grid>
</Window>
This is how the Window shows up in Visual Studio:
When you run the project though, the Window shows up like this:
Metadata
Metadata
Assignees
Labels
No labels