Details
-
Bug
-
Resolution: Fixed
-
Medium
-
4.5.0beta1
-
None
Description
Hi. Found the issue while working in ezscriptmonitor spanish translation.
after running ezlupdate, some of the messages have two location elements, making the file not validate against ts.rng file.
here's some sample of the file
<message> <location filename="list.php" line="22"/> <location filename="view.php" line="27"/> <source>Script monitor</source> <translation>Monitor de scripts</translation> </message>
According to qt linguist definition [1] following line indicates that this kind of message is possible
<!ELEMENT message (location*, source?, oldsource?, comment?, oldcomment?, extracomment?, translatorcomment?, translation?, userdata?, extra-**) >
so i think the problem is in the ts.rng file itself. file has this piece of code
<element name="message"> <optional> <element name="location"> <attribute name="filename"/> <attribute name="line"> <data type="integer"/> </attribute> </element> </optional>
marking location as optional, but not as having more than one. so, i think we should use 'zeroOrMore' for that.
[1] http://doc.qt.nokia.com/4.5/linguist-ts-file-format.html