substitute function implementation

A public branch to allow direct collaboration on the render function implementation.  This takes the previous implementation and modifies it to use the StrSubstitutor.