Skip to content

Commit

Permalink
Merge pull request #226 from jim-easterbrook/devel
Browse files Browse the repository at this point in the history
Devel
  • Loading branch information
jim-easterbrook committed Jan 13, 2024
2 parents 263c6cc + 8d9e709 commit d2de9a6
Show file tree
Hide file tree
Showing 29 changed files with 297 additions and 211 deletions.
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ Licence

| Photini - a simple photo metadata editor.
| http://github.com/jim-easterbrook/Photini
| Copyright (C) 2012-23 Jim Easterbrook [email protected]
| Copyright (C) 2012-24 Jim Easterbrook [email protected]
| Catalan translation by Joan Juvanteny
| Czech translation by Pavel Fric
Expand All @@ -101,7 +101,7 @@ Licence
| Korean translation by Soohyeon Park
| Norwegian Bokmål translation by Allan Nordhøy
| Polish translation by Dawid Głaz, Eryk Michalak
| Spanish translation by Esteban Martinena, Cristos Ruiz, Kamborio
| Spanish translation by Esteban Martinena, Cristos Ruiz, Kamborio, gallegonovato
This program is free software: you can redistribute it and/or
modify it under the terms of the GNU General Public License as
Expand Down
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Photini - a simple photo metadata editor.
# http://github.com/jim-easterbrook/Photini
# Copyright (C) 2023 Jim Easterbrook [email protected]
# Copyright (C) 2023-24 Jim Easterbrook [email protected]
#
# This program is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
Expand Down Expand Up @@ -43,7 +43,8 @@ dependencies = [
"appdirs >= 1.3",
"cachetools >= 3.0",
"chardet >= 3.0",
"exiv2 >= 0.15.1",
"exiv2 >= 0.16",
"filetype >= 1.0",
"requests >= 2.4",
]
dynamic = ["version"]
Expand Down
7 changes: 3 additions & 4 deletions src/lang/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Edit translation locally::

git checkout main # switch to main branch
git pull # fetch new content
python3 utils/lang_update.py -l xx # update from source, with line numbers
python3 utils/lang_update.py -q -l xx # update from source, with line numbers and suitable for Qt Linguist
pyside6-linguist src/lang/xx/photini.ts # edit translation of language xx
python3 utils/lang_update.py -s -l xx # remove line numbers
git push # push updated translation to GitHub
Expand All @@ -51,13 +51,12 @@ Before a new release of Photini::

git checkout main # switch to main branch
git pull # fetch new content
python3 utils/lang_update.py # update from source
python3 utils/lang_update.py -q # update from source, suitable for Qt Linguist
python3 utils/build_lang.py # "compile" language files

Plurals
-------

Qt Linguist and Transifex have different ideas about how many plural forms some languages have.
For example, Transifex expects French to have three plurals ``1``, ``many``, and ``other``, but Qt Linguist expects two ``singular`` and ``plural``.
Transifex provides languages such as ``Italian (QT FILETYPE)`` that use Qt's plural definitions.
Weblate just considers the missing plural forms to be an error that can be ignored.
The -q option to lang_update.py strips extra plurals to make the file suitable for Qt's tools. Without the -q option extra plurals "unused" are inserted to suit Weblate and Transifex.
7 changes: 6 additions & 1 deletion src/lang/ca/photini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -883,12 +883,17 @@
<name>LatLongDisplay</name>
<message>
<source>Lat, long</source>
<translation>Lat, long</translation>
<translation type="vanished">Lat, long</translation>
</message>
<message>
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a space.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lat, long</source>
<comment>Short abbreviation of &quot;Latitude, longitude&quot;</comment>
<translation>Lat, long</translation>
</message>
</context>
<context>
<name>LoggerWindow</name>
Expand Down
7 changes: 6 additions & 1 deletion src/lang/cs/photini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -890,12 +890,17 @@
<name>LatLongDisplay</name>
<message>
<source>Lat, long</source>
<translation>Zeměpisná šířka, délka</translation>
<translation type="vanished">Zeměpisná šířka, délka</translation>
</message>
<message>
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a space.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lat, long</source>
<comment>Short abbreviation of "Latitude, longitude"</comment>
<translation>Zeměpisná šířka, délka</translation>
</message>
</context>
<context>
<name>LoggerWindow</name>
Expand Down
7 changes: 6 additions & 1 deletion src/lang/de/photini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@
<name>LatLongDisplay</name>
<message>
<source>Lat, long</source>
<translation>Breite, Länge</translation>
<translation type="vanished">Breite, Länge</translation>
</message>
<message>
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a comma.</source>
Expand All @@ -902,6 +902,11 @@
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a space.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Lat, long</source>
<comment>Short abbreviation of &quot;Latitude, longitude&quot;</comment>
<translation>Breite, Länge</translation>
</message>
</context>
<context>
<name>LoggerWindow</name>
Expand Down
5 changes: 3 additions & 2 deletions src/lang/en/photini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -830,11 +830,12 @@
<context>
<name>LatLongDisplay</name>
<message>
<source>Lat, long</source>
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a space.</source>
<translation></translation>
</message>
<message>
<source>Latitude and longitude (in degrees) as two decimal numbers separated by a space.</source>
<source>Lat, long</source>
<comment>Short abbreviation of &quot;Latitude, longitude&quot;</comment>
<translation></translation>
</message>
</context>
Expand Down
Loading

0 comments on commit d2de9a6

Please sign in to comment.