When overridden in a derived class, is invoked whenever application
code or internal processes (such as a rebuilding layout pass) call ApplyTemplate.
In simplest terms, this means the method is called just before a UI element displays
in an application. For more information, see Remarks.