Updated TemplatePrettyPrinter such that it can be used as a
LabelProvider for individual values in the template.