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

FreeCAD → Tools → Addon manager → Check for updates #336

Open
kaktusus opened this issue Sep 21, 2024 · 3 comments
Open

FreeCAD → Tools → Addon manager → Check for updates #336

kaktusus opened this issue Sep 21, 2024 · 3 comments

Comments

@kaktusus
Copy link
Contributor

OS: Debian GNU/Linux trixie/sid (KDE/plasma)
Word size of FreeCAD: 64-bit
Version: 1.1.0dev.38794 (Git) AppImage
Build type: Release
Branch: main
Hash: a47800d9ccd7d7a7cdb1779d56de03d3c64cd76e
Python 3.11.9, Qt 5.15.13, Coin 4.0.3, Vtk 9.2.6, OCC 7.7.2
Locale: Polish/Poland (pl_PL)
Stylesheet/Theme/QtStyle: OpenDark.qss/OpenDark/Qt default
Installed mods: 
  * Curves 0.6.47
  * Render 2024.8.4
  * Alternate_OpenSCAD 1.0.0
  * Plot 2022.4.17
  * dodo 1.0.1
  * Rocket 3.3.0
  * pcb 6.2023.1
  * freecad.gears 1.3.0
  * Marz 0.1.8
  * Movie 2024.2.15
  * sheetmetal 0.4.26
  * kicadStepUpMod 11.3.3
  * OpenTheme 2024.9.1
  * woodworking.tar.gz
  * woodworking 0.21.2.33771
  * CfdOF 1.27.10
  * Ship 2022.4.11
  * fasteners 0.5.29

The "check for updates" button has dynamic signatures that are not translated.

vokoscreenNG-2024-09-21_15-31-20.webm

The problem occurs when there are more than one update available.

Apply %n available update(s)
https://crowdin.com/editor/freecad/32150/en-pl?view=comfortable#6640594

@luzpaz
Copy link
Collaborator

luzpaz commented Oct 6, 2024

@chennes any chance you know how to fix this so we can get it in to 1.0 ?

@hasecilu
Copy link

hasecilu commented Mar 13, 2025

I remember once Crowdin was asking to translate two times a single string because it was tweak (don't know how) to support single and plural forms.

So I think Qt expects 2 strings but only one is being return1.

I noticed translation works when only 1 update is available (singular form)2

Image

How wee put the second string when is not asked on Crowdin?

Footnotes

  1. https://doc.qt.io/qt-6/i18n-source-translation.html#handle-plural-forms

  2. https://github.com/FreeCAD/FreeCAD/blob/289a9a8dc137200336af60bc68d1ddd29a953154/src/Mod/AddonManager/Widgets/addonmanager_widget_global_buttons.py#L106

@chennes
Copy link
Member

chennes commented Mar 14, 2025

I think the problem actually comes down to the fact that we strip out the English translations. It seems that Qt tries to out-clever us by deciding that if the primary language doesn't support multiple plurals, then neither can any other language. By actively getting rid of any English "translations", we're precluding the possibility of getting the plural stuff to work. I'm not positive this is the case, but we do get warnings about plurals when we build.

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

No branches or pull requests

4 participants