Bug 281498

Summary: Some messages not translated
Product: [Applications] kalzium Reporter: stefan.asserhall
Component: generalAssignee: Kalzium Developers <kalzium>
Status: RESOLVED FIXED    
Severity: normal CC: aspotashev, lueck
Priority: NOR    
Version: 2.3.90   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Git patch to update the XML file

Description stefan.asserhall 2011-09-06 20:30:26 UTC
Created attachment 63453 [details]
Git patch to update the XML file

Version:           2.3.90 (using Devel) 
OS:                Linux

Some messages in "kalzium/data/knowledge.xml" are not translated in Kalzium, because certain characters are represented with XML Unicode entities (e.g. &#177; for ±). When read by the program, these are changed to the actual character, so the messages extracted by extractrc do not match the string anymore, which prevents translation.
A simple fix is to change the XML file to use the actual Unicode character, which should work fine, since the file encoding is UTF-8. The attached git patch does that.
Another option is of course to change the code, but I have not looked into that.

The version reported by "About Kalzium" is 2.4.00.

Reproducible: Didn't try

Steps to Reproduce:
Open Tools -> Glossary, and look at the explanation of Electron or another message with an entity, using any other language than English, for example Swedish. The explanation is not translated.

Actual Results:  
Message in English.

Expected Results:  
Message in other language (for example Swedish)
Comment 1 Burkhard Lück 2011-09-07 05:16:59 UTC
Reproducable in master as well
Comment 2 Burkhard Lück 2013-01-21 21:39:05 UTC
Git commit fd1a1ea07a332e77c26526fc162cb27a4c90d11f by Burkhard Lück.
Committed on 21/01/2013 at 22:38.
Pushed by lueck into branch 'KDE/4.10'.

Make glossar messages with XML Unicode entities (e.g. &#177; ) translatable
patch by Stefan Asserhall
REVIEW:108531

M  +6    -6    data/knowledge.xml

http://commits.kde.org/kalzium/fd1a1ea07a332e77c26526fc162cb27a4c90d11f
Comment 3 Burkhard Lück 2013-01-21 21:42:41 UTC
Git commit 412632e603ab177c0c0fd5accabda7041638158f by Burkhard Lück.
Committed on 21/01/2013 at 22:38.
Pushed by lueck into branch 'master'.

Make glossar messages with XML Unicode entities (e.g. &#177; ) translatable
patch by Stefan Asserhall
REVIEW:108531
(cherry picked from commit fd1a1ea07a332e77c26526fc162cb27a4c90d11f)

M  +6    -6    data/knowledge.xml

http://commits.kde.org/kalzium/412632e603ab177c0c0fd5accabda7041638158f
Comment 4 stefan.asserhall 2013-01-22 19:56:13 UTC
Thanks for patching! It's interesting that a bug report with a patch ready to apply should take 1½ years to resolve ...