Set Attributes for a Property
[DefaultValue(typeof(AlignmentType), "BottomRight")] public AlignmentType Alignment { }
Edit: in fact, this only helps the developer determine if the property should otherwise be specified in the initialization code.
With this in mind, you simply use your constructor to set a default value or set a default value with a variable declaration.
pinkfloydx33
source share