Hi, thank you for your reply!
I'm trying the following code based on your example but it does not work (nothing appears in the cell):
Where rotate panel is something I found in another thread (about the possibilities for applying LayoutTransform):
public
class
RotatePanel : Panel
{
protected
override
Size MeasureOverride(Size availableSize)
{
foreach
(UIElement child
in
this
.Children)
{
child.Measure(availableSize);
}
double
maxWidth =
this
.Children.MaxOrDefault(child => child.DesiredSize.Width, 0);
double
maxHeight =
this
.Children.MaxOrDefault(child => child.DesiredSize.Height, 0);
return
new
Size(maxHeight, maxWidth);
}
protected
override
Size ArrangeOverride(Size finalSize)
{
foreach
(UIElement child
in
this
.Children)
{
child.Arrange(
new
Rect(0, (finalSize.Height / 2) + (child.DesiredSize.Width / 2), child.DesiredSize.Width, child.DesiredSize.Height));
}
return
finalSize;
}
}
}
internal
static
class
IEnumerableExtensions
{
internal
static
double
MaxOrDefault<TSource>(
this
IEnumerable<TSource> source, Func<TSource,
double
> selector,
double
defaultValue)
{
if
(source.Any<TSource>())
return
source.Max<TSource>(selector);
return
defaultValue;
}
}
However with or withaut RotatePanel it does not work. Do you have an idea what am i doing wrong?
Best Regards