1. 23 Jun, 2017 1 commit
  2. 07 Nov, 2016 2 commits
  3. 06 Nov, 2016 1 commit
  4. 16 May, 2016 1 commit
  5. 19 Mar, 2016 2 commits
  6. 04 Feb, 2016 1 commit
  7. 07 Jan, 2016 1 commit
  8. 07 Jul, 2015 1 commit
    • Murray Cumming's avatar
      C++11: range-based for loops: Don't get the container separately. · 12453ef5
      Murray Cumming authored
      Don't use an intermediate variable to get the container.
      Range-based for loops only evaluate the second part once so this is
      fine. This simplifies code by not making us think about whether the
      variable is used later in the method.
      This is only useful with containers that don't need to be
      const-iterated. We can const_cast<> the container, but that is
      lengthy and involves mentining the type.
  9. 02 Jul, 2015 1 commit
  10. 01 Jul, 2015 1 commit
  11. 30 Jun, 2015 1 commit
  12. 31 Oct, 2013 2 commits
  13. 29 Oct, 2013 1 commit
  14. 12 Apr, 2012 1 commit
  15. 23 Jan, 2012 1 commit
    • Murray Cumming's avatar
      Document: Allow the database title to be translated. · 18ec0082
      Murray Cumming authored
      * glom/libglom/filelist.am:
      * glom/libglom/database_title.[h|cc]: Add this new TranslatableItem.
      * glom/libglom/document/document.[h|cc]: Use DatabaseTitle instead of just
      a string, and load/save it in the database.
      get_database_title(): Add a locale parameter and add
      * glom/application.cc:
      * glom/libglom/connectionpool.cc:
      * glom/libglom/data_structure/translatable_item.[h|cc]:
      * glom/libglom/db_utils.cc:
      * glom/libglom/example_document_load.cc:
      * glom/libglom/translations_po.cc:
      * tests/test_document_autosave.cc:
      * tests/test_document_change.cc:
      * tests/test_document_load.cc:
      * tests/test_document_load_translations.cc: Adapt.
  16. 16 Jan, 2012 1 commit
  17. 10 Jan, 2012 1 commit
    • Murray Cumming's avatar
      Allow creation of .pot files for .glom files. · 06295b45
      Murray Cumming authored
      * glom/libglom/translations_po.[h|cc]: Added write_pot_file().
      * glom/glom_export_po.cc: Add a --template option to genereate
      .pot files.
      * Makefile.am: Use this new option to generate .pot files
      when exporting all .po files.
      * examples/po_files/*/*.pot: Add these generated files to git,
      to help translators to start new translations.
  18. 09 Jan, 2012 2 commits
    • Murray Cumming's avatar
      Exporting of .po files: Do not lose non-ASCII characters. · 090c44ef
      Murray Cumming authored
      * glom/libglom/translations_po.cc: write_translations_to_po_file():
        Write the file manually instead of using gettext-po.h and its po_file_write(),
        because that loses non-ASCII characters (see previous commit).
        make check now works.
    • Murray Cumming's avatar
      Add glom_import_po_all command-line utility. · ddb7ebe4
      Murray Cumming authored
      	* glom/libglom/translations_po.cc: write_translations_to_po_file():
        Mark the document as modified so the changes will (or can be) saved.
      	* Makefile_libglom.am:
      	* glom/glom_import_po_all.cc: Add this command-line utility to read all
      	.po files in a directory back into the .glom file.
  19. 08 Jan, 2012 2 commits
    • Murray Cumming's avatar
      Export to po file: Write a po file header. · b610f2ef
      Murray Cumming authored
      * glom/libglom/translations_po.[h|cc]: write_translations_to_po_file():
      Add an optional locale_name parameter. We cannot discover this inside
      the function because we only use iso-codes in glom, not libglom, and
      I would prefer not to move that static data into libglom.
      * glom/mode_design/translation/window_translations.cc:
      on_button_export():Pass the extra locale_name parameter.
      * tests/translations_po/data/test.po: Resave.
      This makes the written .po file pass validation by msgfmt -c on the
      command line.
    • Murray Cumming's avatar
      Import of po files: Handle empty gettext strings. · 3b190ebe
      Murray Cumming authored
      * glom/libglom/translations_po.cc: Handle empty msgid, msgstr and
  20. 07 Jan, 2012 2 commits
    • Murray Cumming's avatar
      Export to po file: Improve the msgtxt hints. · eaec5468
      Murray Cumming authored
      * glom/libglom/data_structure/translatable_item.[h|cc]:
      get_translatable_item_type(): Make this const.
      * glom/libglom/document/document.[h|cc]: get_translatable_items():
      Now return a list of pairs, so each TranslatableItem also has a hint
      for the msgtxt for the po (gettext) file, so that each can be
      identified uniquely and so that the translator has some context.
      * glom/libglom/translations_po.[h|cc]: Adapt.
      * glom/mode_design/translation/window_translations.[h|cc]: Adapt,
      showing the actual hint instead of just the item type.
      * tests/test_document_load_translations.cc: Adapted.
      * tests/translations_po/data/test.po: Reexported.
    • Murray Cumming's avatar
      Move po file (gettext) import and export into libglom and test it. · ffd6bd9a
      Murray Cumming authored
      * glom/mode_design/translation/window_translations.[h|cc]:
      load_from_document(), save_to_document(): Move the collecting of
      translatable items to:
      * glom/libglom/document/document.[h|cc]: get_translatable_items();
      Also move the gettext/po import/export to:
      * Makefile_libglom.am:
      * glom/libglom/filelist.am:
      * glom/libglom/translations_po.[h|cc]: write_translations_to_po_file()
      and import_translations_from_po_file().
      * Makefile_tests.am
      * tests/translations_po/data/test.po:
      * tests/translations_po/test_document_export_po.cc:
      * tests/translations_po/test_document_import_po.cc: Add tests of the new
      libglom functions.
      * Makefile_glom.am
      * glom/glom_export_po.cc: Added a new command-line tool that uses the
      new libglom API.