Added NSAttributeString support.

Also fixed a warning in 64 bit compilation.