add utf-8 encoding support