Here’s the xml: Only < message > < source >'s INSIDE the < context > get translated. It’s also another reason why I suggest to users unfamiliar with the code NOT to edit the ts files. Use Linguist instead. If you start mucking with the context names the app will not be able to create and apply the qm files properly.
It’s already in English… and for the most part I have fixed all the incorrect terminology, and / or made some of the terms uniform… such as “Type of lIne”, “Pen style”, and “Line type” are now all “Linetype” in the ui. Gone is the term “Passmark” and replaced with “Notch”. Plus the grammer has been fixed in many places. All of which is why a good percentage of the translations got broken. RT’s idea was "Don’t change the UI - it will break the translations. So nothing ever got fixed. I never cared about that… like you said get the English correct first. But thanks to work by users we should have a good chunk of the app translated in Dutch, German, French, and Spanish soon.
@Goran
BTW… This brings up another point to watch for… this happens to be an arg format string (In this case for the undo string in the AddDraftBlock undo command class.)
So that only the text that needs translating is translated. This style I’m sure is throughout the code. So the point is DO NOT CHANGE OR REMOVE any %[num] placeholders, or the format string will be broken and the arg can’t be replaced. More likely it will throw an error during compliling. If we go and change all the format strings now, they would have to all be translated again… which is why I didn’t bother fixing them.
Hi Goran… Yes it’s Ok. There are instances where the text string is in html format. Again this string happens to be a format string where the %1 will be replaced by the actual point name. Since this text is in a warning message box, where there is only 1 text string available, by using html you can format the text so it’s not all one run on string. Plus you can change the font size and style. Here’s the actual code for that string, where the tr() tells the compiler to add a source text to the ts file, and since tr()'s can take arg’s the 1st arg (%1) is pointName.
const QString msg = tr("<b><big>Can't find intersection point %1 of</big></b><br>"
"<b><big>Circle and Tangent</big></b><br><br>"
"Using origin point as a place holder until pattern is corrected.")
.arg(pointName);
So you only want to translate the text parts between any html tags, and leave any %1, %2, %3…etc. or in this case you just want to translate what’s in the red boxes.
So if Google translate is accurate, the Serbian translation would be something like…
<b><big>Не могу да пронађем тачку раскрснице %1 од
</big></b><br><b><big>Круг и тангента</big></b>
<br><br>Коришћење почетна тачка као држач места
док се образац не исправи.
Another thing to look out for when translating ts files… DO NOT TRANSLATE MATH FUNCTION NAMES. You can translate the comment, but not the name, or it will cause an error in the fx edit dialog.
I read all these posts and am gathering all the intel about translations and working with Qt that I can.
These posts and many others in elsewhere are quite useful and may helpful for new translators.
I am currently recovering from an injured elbow so it’s not that easy to work on keyboard, and even less with a mouse , but I will get to this again soon (I am getting sooo bored right now…)
I know the feeling(s)… first I’ve been bored since march 1st when my business building went up in flames and I more or less retired… and then breaking my hip which I’m still recovering from.
At any rate… get better soon, and when ever you get to it is fine. No rush.
BTW… a few notes regarding the translations.
May be moot for French , but Do not translate any keyboard keys or modifiers - like Ctrl, Shift, Alt, Function… (other than in the ShortcutsDialog and MeShortcutsDialog contexts) these are handled by the qtbase ts file - which I just added to fix the lack of translating things like the standard dialog buttons.
Also do not translate the math functions - like min(), max(), sin(), etc… otherwise it breaks the math parser in the fx dialog. I just had to fix a couple in the French ts and some others.
Wow, this year must have been an f#@!ing ordeal… I don’t know about breaking a hip, but I have quite a good idea about hip misplacement and broken ribs, and this seams quite a nasty mix of both…
And I still feel very strange when I think about all you’ve lost in that fire.
I can only whish youè all the best you can hope for. There are really strange times in life.
I’ve seen on the forum ther is a real need for many translations. I’ll get back to it as soon as I can. I am getting better.
First thing I do is a “goode practice guide” for someone who wants to get into translating Seamly with Qt and pushing things on Github. All of this really feels scary at first (and even after a while, I am still not completely confident with it). A friend is teaching me how to use Github with no fuss, but recently made a “faux pas” and completely lost many hours of work
But I guess this is a whole life’s purpose : doing things and doing them all over again
There’s not a day that goes by that I’m not reminded… like today someone was selling 3 of the Janet Arnold books for $250 on a costume FB page… I had 2 of the books. I lost $1000’s of just my own books, not counting shop books.
If you’re actually working with your own local fork, Git is usually pretty forgiving. In most cases you can undo the last commit to restore to the previous state. I won’t lie… there is learning curve to using git with a repo - varies depending on git client used. If you’re just downloading individual sources files and editing, that’s a different story.