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

Localize the string "none" in export styles #17446

Merged

Conversation

victoryforce
Copy link
Collaborator

No description provided.

@ralfbrown
Copy link
Collaborator

I should have passed "_l10n_none" to the localization function instead of "none". We already have lots of localized instances of "none", so the tagged string would have given us the proper localized result without having to special-case the freeing.

@victoryforce
Copy link
Collaborator Author

I should have passed "_l10n_none" to the localization function instead of "none".

You're right, but I thought it would be a little more logical and clear to not pass the string that indicates "no style" to be processed via the dt_util_localize_segmented_name function.

Yes, the _l10n_ prefix also solves the problem. But why it is used here is less clear to the one who reads the code. Also making the string "_l10n_none" and parsing this case with a function just to get rid of the check on freeing is a bit too much unnecessary code execution for my taste.

src/libs/export.c Outdated Show resolved Hide resolved
Copy link
Member

@TurboGit TurboGit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@TurboGit TurboGit merged commit 059e2a3 into darktable-org:master Sep 10, 2024
6 checks passed
@TurboGit TurboGit added this to the 5.0 milestone Sep 10, 2024
@TurboGit TurboGit added the scope: translation / strings make darktable international label Sep 10, 2024
@victoryforce victoryforce deleted the localize-none-in-export-styles branch September 11, 2024 06:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: translation / strings make darktable international
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants