It's not quite as simple as the title says but I hope you understand.
Consider this scenario:
Class MyClass
Property SubProp1
End Property
-TypeEditor(whatever)-
Property SubProp2
End Property
End Class
Class MyButton
Inherits Button
-MyCustomAttribute-
Property MC as MyClass
End Property
End Class
Next, I put an instance of MyButton into a property grid, expand property MC and edit SubProp2.
From the type editor for SubProp2, I want to get hold of the attribute applied to property MC.
Looking at the context,PropertyDescriptor.ComponentType, we arrive at Type: MyClass. If i look at the attributes applied to MyClass, though, it will only return the attributes applied directly to MyClass, and not the extra attribute applied to the property MC.
I'm struggling to get back to MC so that I can read the attributes applied there. Anyone any ideas?
ETA:
I've answered it below: