I have a .net PropertyGrid. I select an object to view, and a property of that object is a Vector3. I can use ExpandableObjectConverter to automatically expose the properties of the Vector3 into in the PropertyGrid. All fine, except that when the object is selected I'd like the Vector3 to be expanded by default, i.e. so you can see X, Y & Z without having to click [+]. How can I do this?
// Managed C++ :
[TypeConverter(ExpandableObjectConverter::typeid)]
public ref struct Vector3
{
Vector3(float _x, float _y, float _z)
: x(_x)
, y(_y)
, z(_z)
{}
float x, y, z;
property float X
{
float get() { return x; }
}
property float Y
{
float get() { return y; }
}
property float Z
{
float get() { return z; }
}
};