Enchilada
Enchilada

Reputation: 3919

The correct way to create an app that is in a non-English language only

I need to create an iPhone/Mac app that is in a non-English language only. What’s the right way to do this? The app’s name even has some non-English (unicode) characters in it. I can separate the problem into three specific questions:

  1. How should I deal with the fact that my app’s name is, say, “Déclaration”? I know I should probably not name my project Déclaration.xcodeproj from the start (e.g. because that makes output from git on the Terminal look painful). How should I set up my project?

  2. How should I deal with NSStrings in my code? Should I just write things like NSString *labelTitle = @"Bienvenue à la déclaration!"; without any hesitation? I know that a more proper way would be to use localization techniques, but isn’t that too much pain, given that I only need the foreign language? It seems rather fishy having to make the whole app in English, even if I don’t need it.

  3. Are there any other things I should take into consideration, when writing a non-English only app?

Upvotes: 4

Views: 164

Answers (2)

user207968
user207968

Reputation:

Note that in order to share git repositories with non-ASCII letters in file names, you need to set the core.precomposeunicode option to true on the Mac, before cloning the repository on the Mac:

git config --global core.precomposeunicode true

As described in git config man page, the option is related to the particular decomposition of Unicode characters in Mac OS:

This option is only used by Mac OS implementation of git. When core.precomposeunicode=true, git reverts the unicode decomposition of filenames done by Mac OS. This is useful when sharing a repository between Mac OS and Linux or Windows. (Git for Windows 1.7.10 or higher is needed, or git under cygwin 1.7). When false, file names are handled fully transparent by git, which is backward compatible with older versions of git.

Reference: Answer by Leo Koppelkamm in "Git and the Umlaut problem on Mac OS X"

Upvotes: 0

Dietrich Epp
Dietrich Epp

Reputation: 213338

  1. Don't worry about the Git output. Mac filenames have been Unicode for a very long time now. Git is using UTF-8 but it's cautious about printing out non-ASCII characters so it escapes them. You can still do things like this:

    git init
    git add Déclaration.xcodeproj
    

    You can turn the escaping off using the core.quotepath setting:

    git config core.quotepath false
    
  2. Yes, you do not need to hesitate. You can always localize later, using strings in your native language as the starting point.

  3. Yes, in the Info.plist change the "Localization native development region" to the language you are using instead of English.

Upvotes: 4

Related Questions