Closed scottcg closed 2 years ago
What scenario would this enable? Both are functionally equivalent.
A core rule of C# markup API is that child controls are specified as parameters, not in extension methods. This allows for consistency (one place to specify children) and performance optimization (C# markup is almost allocation free because controls are only created in parameters, not in the middle of a fluent extension method chain).
If it helps, content support has been improved since this issue was reported; e.g. in WPF use Label(UIObject Content)
to specify content of any type that accepts - string, DateTime, UIElement, Panel
I don't recall my thinking, if it was having a "separate thing" once I'd gotten around to working out FrameworkElementFactory - but as you say there's no real difference.
Thanks for clarifying; I will close this as not an issue.
Add a Label Content property helper to allow attaching text/string to a Label; Label as only a constructor at the monent
To allow for this (currently this is an error):