Package: poxls
Translating via spreadsheetsNot all translators are comfortable with using PO-editors such asPoeditor translation tools likeTransifex. For them this package provides simple tools to
convert PO-files toxlsx-files and back again. This also has another benefit:
it is possible to include multiple languages in a single spreadsheet, which can be
helpful when translating to multiple similar languages at the same time (for
example simplified and traditional chinese).The format for spreadsheets is simple:If any message use a message context the first column will specify the
context.  If message contexts are not used this column will be skipped.The next (or first) column contains the message id. This is generally the
canonical text.A set of columns for any requested comment types (message occurrences, source
comments or translator comments).A column with the translated text for each locale. Fuzzy translations are
marked in italic.The first row contains the column headers.``xls-to-po`` uses these to locale
information in the file, so make sure never to change these!Catalog to spreadshseetConverting one or more PO-files to an xls file is done with thepo-to-xlscommand:po-to-xls nl.poThis will create a new filemessages.xlsxwith the Dutch translations. Multiple
PO files can be specified:po-to-xls -o texts.xlsx zh_CN.po zh_TW.po nl.poThis will generate atexts.xlsxfile with all simplified Chinese,
traditional Chinese and Dutch translations.po-to-xlswill guess the locale for a PO file by looking at theLanguagekey in the file metadata, falling back to the filename if no language information
is specified. You can override this by explicitly specifying the locale on the
commandline. For example:po-to-xs nl:locales/nl/LC_MESSAGES/mydomain.poThis will readlocales/nl/LC_MESSAGES/mydomain.poand treat it as Dutch
(nllocale).You can also use the-cor--commentsoption with one of those choices:translator,extracted,reference,allto add more column in the
output.Spreadshseet to catalogTranslations can be converted back from a spreadsheet into a PO-file using thexls-to-pocommand:xls-to-po nl texts.xlsx nl.poThis will take the Dutch (nl) translations fromtexts.xls, and (re)create anl.pofile using those. You can merge those into an existing po-file using
a tool like gettext’smsgmerge.You can ignore specific sheets by using-ior--ignore. For example:xls-to-po -i ‘Read Me First’ -i Appendix  nl texts.xlsx nl.poWill ignore sheetsRead Me FirstandAppendixof the book.Changelog1.5.0 - November 10, 2019Support both OpenPyxl < 2.5.0b1 and newer versions. Patch from Felix Slager.Fix handling of the comment column in xls-to-po. Patch from Jens Mertelmeyer.Correct typos in README. Patch from Robin Meier.1.4.2 - May 11, 2017Fix another problem with message context handling in po-to-xls.1.4.1 - May 11, 2017Fix po-to-xls handling of messages with a context.1.4.0 - December 23, 2016Fix compatibility with current OpenPyxl releases.Fix Python 3 compatibility.1.3.0 - July 6, 2015Fix another ReST syntax error in package description.Correcty handle rows with a missing translation.1.2.0 - June 12, 2015Fix ReST syntax error in package description.Skip rows without a message id.1.1.0 - 25 March 2015Useopenpyxlinstead of xlrd/xlwt. This
fixes warnings about cell type conversions when opening generated xlsx files
in Apple Numbers (and possibly others).1.0.0 - 15 March 2015Split po-excel conversion tools out fromlingua.Simplify CLI interfaces.