Hi all,
Ive been struggling to make a dockpanel component wider than around 900 pixels - im using one as a header on my application - it therefore needs to expand to fill the full width of the application.
It seems to be limited by the application of a BitmapEffect drop shadow. For example with the followign code the dockpanel downt paint anywhere near 1700 pixels wide, but when i comment out the bitmap effect element the panel fills the width of the screen as it should. I really need the drop shadow though! I think this may be a bug in WPF. By the way - the Border is inside a Canvas....
<Border Width="1700" Margin="39, 0, 0, 0" Canvas.Left="0" Canvas.Top="120" BorderThickness="2" Height="26" Background="#2B7ABF">
<Border.BorderBrush >
<SolidColorBrush Color="White" />
</Border.BorderBrush>
<Border.BitmapEffect>
<DropShadowBitmapEffect Color="Black" ShadowDepth="3" Opacity="0.7">
</DropShadowBitmapEffect>
</Border.BitmapEffect>
</Border>

DockPanel Width Limited by Bitmap effect?
igoro1975
Hi Scott,
Thanks for your input.
I was under the impression that it was fixed with the Feb CTP. Can you clarify which CTP you are using
Some background:
Due to perf issues, we originally decided to force a max size. The user feedback suggested we remove this upper bound. When we removed the upper bounds, users started to hit Out of memory conditions when large scales were applied.
The next fix was to use the size of the screen, and then process the effect. Any updates to the visual itself, like scrolling etc, should automatically update the effect.
The following seems to work fine with the recent bits we have here.
<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:sys="clr-namespace:System;assembly=mscorlib" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" >
<ScrollViewer HorizontalScrollBarVisibility="Visible">
<TextBox Width="1900" Margin="39, 0, 0, 0" Canvas.Left="0" Canvas.Top="120" BorderThickness="2" Height="26" Background="#2B7ABF">
<TextBox.BitmapEffect>
<BlurBitmapEffect />
</TextBox.BitmapEffect>
</TextBox>
</ScrollViewer>
</Page>
Kars Blom
thanks for confirming that. I guess i'll just wait and see what the future ctp's bring.
Regards,
Scott.
APEXnow
Philip York
The issue does indeed appear to have been fixed in the February CTP! The bug was originally noticed in the January CTP.
Glad that issue is sorted,
Thanks,
Scott.
"You threw a monkey in the sea " Alan Partridge 1999.