TM: minor refactoring
TM: removed unnecessary extra nesting level
TM: call highlighting from templates
TM: get source text directly from the unit
TM: escape markup from target texts

Fixes #202.