Unwanted cropping in WrapPanel
I need to create a ListBox using WrapPanel ItemsTemplate.
My item displays as a map with a small top toolbar that is dynamically displayed on the mouse.
[dyn. toolbar] [card]
Everything works well except for the first line.
I need to have the cards very close to each other. Hence the Element Height is set to the map height without the panel height. The toolbar was created with Margin.Top <0.
The problem is the toolbar is being clipped by the list.
Do you know any methods for dealing with this situation?
Thanks everyone!
source to share
Xaml will be helpful. One rule of thumb I've found is to never set the actual height or width properties of a control. Try to take out the height property and that should get rid of the clipping. You should be able to get whatever spacing you want with Margin, Padding or MinHeight.
source to share