Ported package from year 2004 to class and xelatex