Added support for xpm reading.