update escape rule for xtemplate.Fixes #526