Optimize some codes, Fixed a bug in Font