HI,All:
Can thexaml designer of vs2010 be used to design components derived directly from the Object class? My meaning is that the components are not derived from the Visual class. For example, there is a class named MyWindow, which is derived directly from the Object class, it has two properties: Width and Height, the code of the MyWindow class is as flowing:
public class MyWindow
{
public double Width { get; set; }
public double Height { get; set; }
}
The xaml is as fllowing:
<my: MyWindow x:Class="MyApplication. MyWindow "
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:my="clr-namespace:CustomControlLibrary;assembly=CustomControlLibrary" Height="200" Width="200">
</my: MyWindow >
We want to develop a designer base on the xamldesigner of vs2010, when user open the xaml, the designer will show a view like a window, the user can resize the view, and the xaml will change.if user change the xaml, the view will change also. We don’t know if the xamldesigner’s architecture can support the case, we are researching on the beta1, but we found a limitation now, the "ViewProducerBase�class can only support the types derived from theVisual class, if a object is not derived from theVisual class, the ViewProducerBase can’t create ViewItem, This is a design or bug?