如何在Objective-C中获取用户的语言环境? [英] How to get language locale of the user in Objective-C?
本文介绍了如何在Objective-C中获取用户的语言环境?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在为Mac OS X开发一个应用程序.我想通过应用程序用户的语言区域(英语,西班牙语等)更改指示内容,如何获得使用哪种语言的信息?
I am developing an application for Mac OS X. I want to change indication contents by the language locale (English, Spanish, etc.) of the application user, how do I get information of which language is used?
推荐答案
NSLog(@"localeIdentifier: %@", [[NSLocale currentLocale] localeIdentifier]);
这篇关于如何在Objective-C中获取用户的语言环境?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文