I want to create a sort of a popup window like the Overloads window in Visual Studio. And just like the Overloads window, it can pop up pretty much anywhere on the screen.
I have a Window that has a child TextBlock control.
The Window changes its size according to the TextBlock size by setting its SizeToContent property to WidthAndHeight. If the TextBlock Text is too long, the Window resizes its width beyond the screen's width resulting in a partially visible Window. I would like the Text to wrap when it reaches the end of the screen, so to say.
I tried setting the TextBlock TextWrapping property to Wrap to hopefully stop this behavior, but it doesn't help because of the SizeToContent property being set. Any suggestions/workarounds?
Thanks for your help!