Internationalization & Localization

i18n and l10n

Who am I?

  • Android dev for ~5 years
  • 2 i18n's under my belt
  • Rudimentary knowledge of German

Survey

  • Worked on an android app?
  • Written a 2nd strings.xml file
  • i18n is a conversation, not a recipe

Some things don't go in strings.xml

  • api values
  • format strings
  • order strings
  • How?

Avoid String concatenation!

May %1$s %2$s %3s %4s

en: I, sharpen, my, pencil

Darf %1$s %2$s %3s %4s

de: Ich meinen bleistift spitzen

Api stuff

User Facing: always translate

Application keys: never translate

Beware the default locale

  • Device  language sets the locale
  • Specify the locale you expect
  • AS complains about this better than Eclipse did
  • specify the locale...

Consider how many characters it takes to say what you're trying to say in the new language in which you're working...

Be Brief 

Consistent

Internationalization & Localization

By Travis Himes

Internationalization & Localization

  • 1,123