Bug 311791

Summary: [tm markup] Translation memory fill in skips HTML tags
Product: [Applications] lokalize Reporter: Andrej M. <andrej.mernik+bugs>
Component: translation memoryAssignee: Nick Shaforostoff <shafff>
Status: RESOLVED WORKSFORME    
Severity: normal CC: adrian, vit
Priority: NOR Keywords: investigated, triaged
Version First Reported In: 1.5   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Translation memory suggests a word. The missing things are clearly marked.
I press Ctrl+1 and only < and > get pasted in along with the recognized word.

Description Andrej M. 2012-12-16 18:05:45 UTC
Dear mantainer,

when translating, sometimes an string equal to the one in translation memory appears between HTML tags. If you press the key to fill in a TM suggestion, it doesn't copy the tags fully.

Reproducible: Always

Steps to Reproduce:
1. TM: This is an example
2. Press keys to fill in the suggestion
Actual Results:  
How it looks after using TM: <This is an example>

Expected Results:  
How it should look after using TM: <tag>This is an example</tag>
Comment 1 Andrej M. 2013-02-14 18:49:59 UTC
So I updated the version to 1.5 on KDE 4.10 and still the same bug. In case I wasn't clear enough I'm attaching two screenshots of the problem.
Comment 2 Andrej M. 2013-02-14 18:51:15 UTC
Created attachment 77302 [details]
Translation memory suggests a word. The missing things are clearly marked.
Comment 3 Andrej M. 2013-02-14 18:51:59 UTC
Created attachment 77303 [details]
I press Ctrl+1 and only < and > get pasted in along with the recognized word.
Comment 4 Christoph Feck 2015-01-14 23:01:12 UTC
*** Bug 330256 has been marked as a duplicate of this bug. ***
Comment 5 Adrián Chaves (Gallaecio) 2018-06-02 21:23:53 UTC
This is currently working for me. I do recall getting this issue in the past, but it’s been a while since then. Can anyone else confirm that this has been fixed?

I tested creating a simple PO file with two msgids identical, one with surrounding <p> tags and translated, and another one without them and untranslated. I created a Lokalize project on the folder containing the file, opened the project, loaded the file into the translation memory, selected the second translation unit (the one without tags) and choosing the entry with HTML tags from the translation memory just worked as expected, successfully removing those tags.
Comment 6 Andrew Crouthamel 2018-09-19 14:26:47 UTC
This bug has had its resolution changed, but accidentally has been left in NEEDSINFO status. I am thus closing this bug and setting the status as RESOLVED to reflect the resolution change.