Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Gettext i18n system - internationalization for gettext

Gettext is a popular internationalization and localization system. You'll find an official library for using gettext in your application in almost any programming language. So we've summarized all important aspects of the gettext i18n system.

  • Login to see the comments

  • Be the first to like this

Gettext i18n system - internationalization for gettext

  1. 1. https://lingohub.com MADE WITH BY LINGOHUB INTERNATIONALIZATION FOR GETTEXT GETTEXT i18n SYSTEM
  2. 2. GETTEXT i18n SYSTEM − Gettext has implementation in almost any programming language − “The grandfather” of all i18n resource files − You’ll find a library for using gettext in your application for almost any programming language − Gettext can be a great choice if you are forced to use different i18n systems and to replace it with a pervasive solution https://lingohub.com MADE WITH BY LINGOHUB ⟶ With a tool like LingoHub resource files and syntax won’t matter anymore. LingoHub supports various resource files and their syntax.
  3. 3. GETTEXT i18n SYSTEM Gettext offers features your standard system might be missing: − Pluralization support − Enumerations − Different types of comments − Different types of flags for every segment https://lingohub.com MADE WITH BY LINGOHUB
  4. 4. GETTEXT RESOURCE FILE FORMATS AND GETTEXT i18n PO (Portable Objects) − .po files represent the central file format for using gettext translation − The files are human readable and editable text files − You can split up PO files for different categorizations https://lingohub.com MADE WITH BY LINGOHUB Example PO file ⟶ Read a detailed format description about PHP internationalization with gettext tutorial on LingoHub!
  5. 5. GETTEXT RESOURCE FILE FORMATS AND GETTEXT i18n PO (Portable Objects) − Using LingoHub you don’t have to pass your PO files on to your translator. − Translators don’t have to edit the files. Your files need to be machine readable and follow a strong syntax − The file won’t be readable by the gettext system if the person editing the file forgets about a quote or uses charactersnot allowed by the used character set. https://lingohub.com MADE WITH BY LINGOHUB ⟶ LingoHub checksthe validity of files at import. Translators use the LingoHub editor for translations. They no longer have to deal with the syntax of PO files. After finishing translationsyou can export syntactically correct PO files.
  6. 6. GETTEXT RESOURCE FILE FORMATS AND GETTEXT i18n POT (Portable Object Templates) − POT have the same structure as PO files, they just contain the keys (“msgid”) of your translatable content − Use POT files if you have chosen the strategy that your keys hold texts of your source language (instead of generic keys) https://lingohub.com MADE WITH BY LINGOHUB
  7. 7. GETTEXT RESOURCE FILE FORMATS AND GETTEXT i18n POT (Portable Object Templates) Workflowusing POT files for translations 1. POT files are created by extracting translatable strings form your source code or CMS. 2. You pass the POT files on to your translators. 3. Your translators import the files into their CAT tool. 4. After translations are finished, translators will create PO files and send them back. Workflowusing POT files with LingoHub − LingoHub allows you to import POT files and export corresponding PO files. That’s great for starting a translation project. − LingoHub offers a feature called Continuous Translation. If you export-adapt-import your resource files, LingoHub will detect changes automatically and keep the project in-sync to your resource files. https://lingohub.com MADE WITH BY LINGOHUB
  8. 8. GETTEXT RESOURCE FILE FORMATS AND GETTEXT i18n MO (Machine Objects) − MO files are machine readable representationsof PO files. − They are smaller in size and valid after creation. − Using an invalid PO file might break your application. You won’t be able to create an MO file if the source PO file is incorrect. − The easiest way to create a MO file is: https://lingohub.com MADE WITH BY LINGOHUB msgfmt en.po –o  en.mo
  9. 9. BROUGHT TO YOU BY LINGOHUB ANJA OBERMÜLLER BUSINESS DEVELOPMENT& MARKETING AT LINGOHUB anja.obermueller@lingohub.com @LingoHub @anjaobermueller Read the whole article. https://lingohub.com MADE WITH BY LINGOHUB

×