I want my nodes to be manually resizable only in the width. The height should be autosized according to the content of the node. I have been able to get the width only resize to work. However, once the node has been manually resized, the height no longer autoresizes if the content size changes. Do you have any suggestions how to handle this?
In the SpotPanelStyle I have set Resizable=“True” and ResizableElementName=“Shape”. In the NodePanelStyle I have set Sizing=“Auto”. In the Diagram’s ResizingTool I have set "MinSize=“0 NaN” and MaxSize=“9999 NaN”.
<DataTemplate x:Key="MyKey"> <go:SpotPanel Style="{StaticResource SpotPanelStyle}"> <go:NodePanel Style="{StaticResource NodePanelStyle}"> <go:NodeShape x:Name="Shape" Style="{StaticResource NodeShapeStyle}" Width="{Binding Path=Data.Width, Mode=OneWayToSource}"/> <DockPanel Margin="0" DataContext="{Binding Path=Data}" Width="{Binding Path=Width, Mode=OneWay}"> ... </DockPanel> </go:NodePanel> </go:SpotPanel> </DataTemplate>