Skip to content

Localize Core Messages#2664

Draft
GLWine wants to merge 2 commits into
EDCD:developfrom
GLWine:Localize-Core-Message
Draft

Localize Core Messages#2664
GLWine wants to merge 2 commits into
EDCD:developfrom
GLWine:Localize-Core-Message

Conversation

@GLWine
Copy link
Copy Markdown
Contributor

@GLWine GLWine commented May 14, 2026

Description:

This PR implements localization for core application messages in EDMarketConnector.py, enabling translation of critical user-facing strings such as error popups, notifications, and startup warnings. The changes standardize message formatting and consolidate i18n handling across the application.

This work is a parallel integration to PR #2617, which localized the authentication success message. Together, these changes expand localization coverage to additional core UI elements while maintaining consistency with the established patterns.

Key Changes:

  • Import Optimization: Moved l10n import earlier and removed duplicate imports to ensure translations are available throughout the file.
  • String Localization: Replaced hard-coded strings in popups, notifications, and dialogs with tr.tl() calls for proper translation support.
  • Newline Standardization: Introduced {LF}{CR} placeholders in localization strings to handle line breaks consistently, replacing manual replace('\\n','\n').replace('\\r','\r') post-processing.
  • New Localization Entries: Added translations for startup messages including journal lock warnings and duplicate process detection.
  • Updated Templates: Modified en.template to include new entries and standardize existing ones with newline placeholders.

Files Modified:

  • EDMarketConnector.py: 58 lines changed (+34/-24) - Added translation calls and removed manual formatting.
  • en.template: 18 lines changed (+12/-6) - Added new strings and updated formatting.

Benefits:

  • Improves user experience for non-English speakers by localizing core error and status messages.
  • Centralizes message handling, making future translations easier.
  • Ensures consistent formatting across all localized messages.

This PR targets the develop branch and maintains backward compatibility while enhancing internationalization support. All changes are based on the existing l10n infrastructure and follow the project's translation patterns established in PR #2617.

Attention: @Rixxan

GLWine added 2 commits May 14, 2026 02:05
Import l10n translations earlier and replace hard-coded popup/notification strings with tr.tl(...) calls using CR/LF placeholders. Standardize message formatting across journal-lock, process-already-running, update notifications, provider reset, plugin errors and critical error dialogs, remove manual \"replace('\\n','\n').replace('\\r','\r')\" post-processing and the duplicate l10n import. This consolidates i18n handling and normalizes linebreak formatting for localized messages.
Update L10n/en.template to replace literal CRLF sequences in several localized popup strings with {LF}{CR} placeholders for consistent newline handling. Also add two new localization entries for journal-lock and duplicate-process startup warnings and adjust plugin, provider-reset, and update-track messages to use the new placeholders.
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