fixes headed title punctuation
retired removing empty tags
checks for xref.tail, accounts for null previous tail or parent text