We have a specialized TabItem defined in xaml:
<TabItem x:Class="MyApp.MyViewTab" xmlns:my="clr-namespace:MyApp">
<my:MyView />
</TabItem>
and code behind: public class MyViewTab : TabItem
.
And MyView
is a UserControl
:
MyView
is correctly shown in the xaml designer and also at run time correctly displayed as the content of the TabItem.
Why does the xaml designer not display the content of MyView
? It is a gray rectangle, top half light-gray, bottom half darker-gray.