Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Annotate some strings with xgettext:no-c-format #1908

Merged
merged 1 commit into from Sep 18, 2021

Conversation

cjwatson
Copy link
Contributor

Some descriptions of location properties contain the text "100%
overlap". When extracting text for translation, xgettext
misidentifies this as containing the C format string "% o", and tags it
as c-format. Translation tools that are sensitive to this will
require that translations contain matching format strings; since in this
case the format string is nonsensical, that is often not reasonably
possible. See:

https://answers.launchpad.net/launchpad/+question/698762

The description of the DotRange tag contains the text "0% dot and 100%
dot", which is similarly misidentified.

To fix this, inform xgettext that the messages do not contain C format
strings, as documented here (towards the end):

https://www.gnu.org/software/gettext/manual/html_node/c_002dformat-Flag.html

Some descriptions of location properties contain the text "100%
overlap".  When extracting text for translation, `xgettext`
misidentifies this as containing the C format string "% o", and tags it
as `c-format`.  Translation tools that are sensitive to this will
require that translations contain matching format strings; since in this
case the format string is nonsensical, that is often not reasonably
possible.  See:

  https://answers.launchpad.net/launchpad/+question/698762

The description of the DotRange tag contains the text "0% dot and 100%
dot", which is similarly misidentified.

To fix this, inform `xgettext` that the messages do not contain C format
strings, as documented here (towards the end):

  https://www.gnu.org/software/gettext/manual/html_node/c_002dformat-Flag.html
@codecov
Copy link

codecov bot commented Sep 17, 2021

Codecov Report

Merging #1908 (f643d9b) into main (774e662) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #1908   +/-   ##
=======================================
  Coverage   60.87%   60.87%           
=======================================
  Files          96       96           
  Lines       19041    19041           
  Branches     9726     9726           
=======================================
  Hits        11591    11591           
  Misses       5138     5138           
  Partials     2312     2312           
Impacted Files Coverage Δ
src/properties.cpp 73.36% <ø> (ø)
src/tags_int.cpp 76.34% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 774e662...f643d9b. Read the comment docs.

@kevinbackhouse
Copy link
Collaborator

Thanks!

@kevinbackhouse kevinbackhouse merged commit 1a58f7b into Exiv2:main Sep 18, 2021
@kevinbackhouse kevinbackhouse added this to the v1.00 milestone Sep 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants