Skip to content

Add Polish translation#10

Open
pmrochen wants to merge 2 commits intodevohmycode:mainfrom
pmrochen:polish
Open

Add Polish translation#10
pmrochen wants to merge 2 commits intodevohmycode:mainfrom
pmrochen:polish

Conversation

@pmrochen
Copy link

@pmrochen pmrochen commented Mar 23, 2026

Summary by CodeRabbit

  • New Features
    • Polish language support added across the app and installer. Users can now choose Polish in Settings to see the UI, menus, dialogs, player/status messages, search/sort, metadata editor, equalizer, sleep timer, tray notifications, and installer texts localized in Polish.

@coderabbitai
Copy link

coderabbitai bot commented Mar 23, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: a2486707-ffa7-4082-ab20-e15393e781d4

📥 Commits

Reviewing files that changed from the base of the PR and between e40f6a0 and 601461a.

📒 Files selected for processing (1)
  • installer.iss
✅ Files skipped from review due to trivial changes (1)
  • installer.iss

📝 Walkthrough

Walkthrough

Adds Polish ("pl") localization across the app: registers Polish in the Settings UI, populates Polish translations in the Strings catalog, and adds Polish to the installer language configuration. (≈30 new/changed translation entries plus UI/installer wiring.)

Changes

Cohort / File(s) Summary
UI Language Registration
Audiomatic/MainWindow.xaml.cs
Added AddLanguageOption("pl", Strings.T("Polish")) to the Settings language list; minor indentation adjustment.
Translation Strings
Audiomatic/Strings.cs
Extended the Translations dictionary with ["pl"] entries for many UI strings (navigation, player, tooltips, dialogs, settings, status messages, etc.); whitespace/comment formatting updated.
Installer Configuration
installer.iss
Registered Polish in [Languages] (Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl") and added polish.AutoStartProgram to [CustomMessages].

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🐰 W polskim tonie dziś skaczę w krąg,
Dodałem słowa do każdego tłumaczeń rąk,
Ustawień, instalatora, menu ślad —
Trzy języki teraz śpiewają nam rad! 🎶

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Add Polish translation' directly and accurately summarizes the main change: adding Polish language support across the application's UI strings, installer configuration, and related files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@qodo-code-review
Copy link

Review Summary by Qodo

Add Polish language translation support

✨ Enhancement

Grey Divider

Walkthroughs

Description
• Add Polish language support to application
• Register Polish language option in settings menu
• Translate 200+ UI strings to Polish
• Include Polish language in installer configuration
Diagram
flowchart LR
  A["Language System"] --> B["MainWindow.xaml.cs"]
  A --> C["Strings.cs"]
  A --> D["installer.iss"]
  B --> E["Add Polish Option"]
  C --> F["Polish Translations"]
  D --> G["Polish Installer"]
Loading

Grey Divider

File Changes

1. Audiomatic/MainWindow.xaml.cs ✨ Enhancement +2/-1

Register Polish language option in UI

• Add Polish language option to language selection menu
• Register AddLanguageOption("pl", Strings.T("Polish")) call
• Fix indentation formatting for consistency

Audiomatic/MainWindow.xaml.cs


2. Audiomatic/Strings.cs ✨ Enhancement +166/-165

Add comprehensive Polish translation dictionary

• Add Polish translations for 200+ UI strings across all categories
• Update translation dictionary header to include Polish language
• Add new ["Polish"] entry with translations for English, French, and Polish
• Cover all UI sections: navigation, player, tooltips, search, radio, podcasts, dialogs, settings,
 and status messages

Audiomatic/Strings.cs


3. installer.iss ⚙️ Configuration changes +1/-0

Add Polish language to installer

• Register Polish language in installer configuration
• Add Polish.isl language file reference for installer UI

installer.iss


Grey Divider

Qodo Logo

@qodo-code-review
Copy link

qodo-code-review bot commented Mar 23, 2026

Code Review by Qodo

🐞 Bugs (2) 📘 Rule violations (0) 📎 Requirement gaps (0) 📐 Spec deviations (0)

Grey Divider


Remediation recommended

1. Installer task string not Polish 🐞 Bug ✓ Correctness
Description
installer.iss enables Polish as an installer UI language, but the custom message used by the startup
task is only defined for english/french, leaving Polish without a language-specific value for that
message.
Code

installer.iss[22]

+Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl"
Evidence
The PR adds Polish to the installer language list, and the installer defines a startup task label
via a custom message key. In the current file, that custom message key is only provided for english
and french, with no polish.* entry visible.

installer.iss[19-22]
installer.iss[32-41]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
`installer.iss` enables Polish installer language, but the custom message `AutoStartProgram` (used by the `startupicon` task) is only defined for `english` and `french`. This leaves Polish without a language-specific value for that key.

### Issue Context
- `[Tasks]` uses `{cm:AutoStartProgram,Audiomatic}` for the startup task label.
- `[CustomMessages]` currently defines `english.AutoStartProgram` and `french.AutoStartProgram` only.

### Fix Focus Areas
- installer.iss[19-22]
- installer.iss[32-41]

### Suggested change
Add a Polish entry, e.g.:
- `polish.AutoStartProgram=Uruchamiaj %1 wraz z systemem Windows`

(Any appropriate Polish phrasing is fine as long as the `polish.AutoStartProgram` key exists.)

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Advisory comments

2. Misleading supported-language comment 🐞 Bug ⚙ Maintainability
Description
The settings model comment still claims only "fr"/"en" language codes are used, but the UI now saves
"pl" as well, making the comment incorrect and likely to mislead future language validation or
refactors.
Code

Audiomatic/MainWindow.xaml.cs[4368]

+		AddLanguageOption("pl", Strings.T("Polish"));
Evidence
MainWindow now persists the language code "pl" via SettingsManager.SaveLanguage. In
SettingsManager.cs, the AppSettings.Language comment still documents the value set as only "fr" and
"en".

Audiomatic/MainWindow.xaml.cs[4354-4363]
Audiomatic/MainWindow.xaml.cs[4366-4370]
Audiomatic/SettingsManager.cs[15-36]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
After adding Polish ("pl") as a selectable language, the comment documenting `AppSettings.Language` is now stale (it still lists only "fr" and "en").

### Issue Context
The application persists the language string directly and uses it to set `Strings.Language`, so accurate documentation helps prevent future validation or migration code from accidentally rejecting "pl".

### Fix Focus Areas
- Audiomatic/SettingsManager.cs[15-24]
- Audiomatic/MainWindow.xaml.cs[4366-4368]

### Suggested change
Update the comment to include Polish, e.g.:
- `string Language,     // "en", "fr", "pl"`
(or remove the hardcoded list if you expect more languages in the future).

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

ⓘ The new review experience is currently in Beta. Learn more

Grey Divider

Qodo Logo

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (2)
Audiomatic/MainWindow.xaml.cs (1)

4368-4368: Sync AppSettings.Language inline docs with the new locale set.

After adding Line 4368, Audiomatic/SettingsManager.cs still documents language as only "fr", "en". Please update that comment to include "pl" to avoid stale guidance.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@Audiomatic/MainWindow.xaml.cs` at line 4368, Update the inline documentation
for AppSettings.Language in SettingsManager.cs to reflect the new Polish locale
by adding "pl" to the documented list (currently only "fr", "en"); locate the
AppSettings.Language comment in SettingsManager.cs and edit the comment text to
include "pl" alongside "fr" and "en" so the guidance matches the new
AddLanguageOption("pl", ...) entry in MainWindow.xaml.cs.
Audiomatic/Strings.cs (1)

38-246: Add an automated locale/placeholder consistency test for this dictionary.

Line 38 onward is now large enough that manual upkeep is error-prone. Add a test that verifies each key has en/fr/pl and that placeholder sets ({0}, {1}, …) match across locales.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@Audiomatic/Strings.cs` around lines 38 - 246, Add a unit test (e.g.,
TranslationsConsistencyTests.VerifyLocaleKeysAndPlaceholders) that loads the
Translations dictionary from the Strings class and asserts for each outer key
that the inner map contains "en", "fr", and "pl", then extracts placeholders
(regex like {\d+}) from each locale string and asserts the sets of placeholders
are identical across the three locales for that key; fail the test with a clear
message naming the Translations key when a locale is missing or when placeholder
sets differ.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@installer.iss`:
- Line 22: Add a Polish translation for the custom message key used by the
installer: the message identifier {cm:AutoStartProgram,Audiomatic} (key
AutoStartProgram with parameter "Audiomatic") is missing Polish text causing
fallback to another language; update the Polish messages file (Polish.isl
referenced by MessagesFile) to include a Polish definition for AutoStartProgram
that mirrors the English/French entries but translated into Polish so
Polish-language installs show coherent text.

---

Nitpick comments:
In `@Audiomatic/MainWindow.xaml.cs`:
- Line 4368: Update the inline documentation for AppSettings.Language in
SettingsManager.cs to reflect the new Polish locale by adding "pl" to the
documented list (currently only "fr", "en"); locate the AppSettings.Language
comment in SettingsManager.cs and edit the comment text to include "pl"
alongside "fr" and "en" so the guidance matches the new AddLanguageOption("pl",
...) entry in MainWindow.xaml.cs.

In `@Audiomatic/Strings.cs`:
- Around line 38-246: Add a unit test (e.g.,
TranslationsConsistencyTests.VerifyLocaleKeysAndPlaceholders) that loads the
Translations dictionary from the Strings class and asserts for each outer key
that the inner map contains "en", "fr", and "pl", then extracts placeholders
(regex like {\d+}) from each locale string and asserts the sets of placeholders
are identical across the three locales for that key; fail the test with a clear
message naming the Translations key when a locale is missing or when placeholder
sets differ.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 75815076-b2d5-4b67-811f-f0bc2945ae70

📥 Commits

Reviewing files that changed from the base of the PR and between 83bc0da and e40f6a0.

📒 Files selected for processing (3)
  • Audiomatic/MainWindow.xaml.cs
  • Audiomatic/Strings.cs
  • installer.iss

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.

1 participant