wxwidgets/tests/intl
Vadim Zeitlin 94b1a17aeb Add AddAvailableCatalog() and use it in AddStdCatalog()
The new function only returns true if the catalog could be really
loaded and not if it is considered not to be needed because the message
ID language (which is typically "en-US") happens to be present in the
preferred UI languages list (which seems to always include "en-US" in at
least Western European MSW).

This allows to distinguish, albeit in a rather awkward (but
backwards-compatible) way between having a translation for the given
language and not needed such translation.

It is still not clear if it is really correct to return "en-US" from the
list of preferred languages even if the user has never intentionally
configured the OS to indicate that English is acceptable, but at least
now we can work around this issue and use AddAvailableCatalog() in
AddStdCatalog() to make sure we only skip loading unversioned wxstd.mo
if the versioned wxstd-x.y.mo file is really found instead of never
doing it, as was the case until now (see #23886).

Also add GetBestAvailableTranslation() helper which seems more useful
than the existing GetBestTranslation() one and is similarly related to
it.

See #18227.
2023-10-02 19:21:48 +02:00
..
fr Removed ellipsis from "About..." occurrences. 2012-01-20 16:51:09 +00:00
ja Strip mnemonics from CJK translations of menu items too 2016-06-26 18:36:11 +02:00
intltest.cpp Add AddAvailableCatalog() and use it in AddStdCatalog() 2023-10-02 19:21:48 +02:00