Fix a crash bug due to a nullptr dereference

Caused crashes when setting the contents of a field.
Fix to MCStringConvertToCFStringRef

Wrong character encoding was being used.
Merge branch 'refactor-syntax_unicode' into refactor-syntax_unicode_button