Slovenian translation

Discussion forum for C++ and script developers who are using the QCAD development platform or who are looking to contribute to QCAD (translations, documentation, etc).

Moderator: andrew

Forum rules

Always indicate your operating system and QCAD version.

Attach drawing files, scripts and screenshots.

Post one question per topic.

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Slovenian translation

Post by miharix » Sat Nov 09, 2013 10:13 pm

Hi,

I would like to teach children in our school how to use QCAD,
but before that I would like to translate QCAD to their mother language.

Now when I look in https://github.com/qcad/qcad/tree/master/ts I already see some files ending with "_sl.qm" that are 6 months old
but those files I can't find under my C:\Program Files (x86)\QCAD\ts
and also when I run QCAD and go to edit->Application Preferences->Language Settings->Language I can't see option Slovenian
I tried to copy the files from github to local ts folder and then I can select Slovenian, but I can't see any change in interface after QCAD restart.

I assume that translation just isn't complete yet.

So who is working on it?
& Can I help ?

User avatar
Husky
Moderator/Drawing Help/Testing
Posts: 4935
Joined: Wed May 11, 2011 9:25 am
Location: USA

Re: Slovenian translation

Post by Husky » Mon Nov 11, 2013 9:26 am

Hi miharix - welcome in the forum,
miharix wrote:I would like to teach children in our school how to use QCAD,
but before that I would like to translate QCAD to their mother language.
Nice idea! :D

miharix wrote:I tried to copy the files from github to local ts folder and then I can select Slovenian, but I can't see any change in interface after QCAD restart.
Me too - I just see a couple buttons which have changed - that's all!
Husky-2013.11.11-01.png
Husky-2013.11.11-01.png (26.26 KiB) Viewed 41330 times
@Andrew
Any news or suggestion on that?

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Mon Nov 11, 2013 4:30 pm

miharix: Many thanks for your offer to help!

The complete QCAD user interface has been translated to English, German, French, Italian, Spanish, Portuguese and Japanese.

I have checked in translation sources for Slovenian today as a start for a Slovenian translation.

Please note that due to the modular design of QCAD, translation sources are located in the 'ts' directory of each individual tool.
For example for the tool to draw lines from two points, translation sources are located in 'scripts/Draw/Line/Line2P/ts':
https://github.com/qcad/qcad/tree/maste ... /Line2P/ts

Those .ts files can be translated with Qt Linguist if you download the .ts files or clone the complete QCAD sources from github.
I've also attached a dictionary file with some known translations which can be loaded with Qt Linguist to provide known translations.

Please let me know if you need any help with the translation process, cloning sources, etc.

If you have a github account, I'm also happy to add you to the contributors list, so you can push translations directly (just let me know what your user name on github is in this case).
Attachments
sl.qph
(203.63 KiB) Downloaded 826 times

User avatar
Husky
Moderator/Drawing Help/Testing
Posts: 4935
Joined: Wed May 11, 2011 9:25 am
Location: USA

Re: Slovenian translation

Post by Husky » Mon Nov 11, 2013 8:37 pm

andrew wrote:Please note that due to the modular design of QCAD, translation sources are located in the 'ts' directory of each individual tool.
:oops: Hihi - I never realized that before - thanks for the enlightenment! :wink:

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Re: Slovenian translation

Post by miharix » Tue Nov 12, 2013 10:46 pm

Hi,

thanks for all the info.
Especially about multiple ts folders. How did I mis that when looking the structure of install dir? :roll: :oops:

Till now I haven't used "Qt Linguist" for translations only "POedit",
so I'll will probably ask some stupid question if I get stuck at configuring.
andrew wrote: Please let me know if you need any help with the translation process, cloning sources, etc.
"cloning" Isn't it just git clone (or download zip) and then copy->paste->rename one existing translation -> Qt Linguist->fix language settings & translate content ? :oops:
andrew wrote: If you have a github account, I'm also happy to add you to the contributors list
Thanks, I'll let you know when there is some progress to show.

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Tue Nov 12, 2013 10:54 pm

miharix wrote:"cloning" Isn't it just git clone (or download zip)
Yes, indeed.
miharix wrote:and then copy->paste->rename one existing translation -> Qt Linguist->fix language settings & translate content ? :oops:
Meanwhile, I've checked in all "*_sl.ts" files, so if you clone or download now, you will already get all the (unfinished) .ts files for the Slovenian translation.
miharix wrote:so I'll will probably ask some stupid question if I get stuck at configuring
Don't hesitate to ask anything anytime :) I appreciate any contributions to QCAD and I am of course happy to help with any problems you might experience!

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Re: Slovenian translation

Post by miharix » Wed Nov 13, 2013 7:30 pm

andrew wrote: I've also attached a dictionary file with some known translations which can be loaded with Qt Linguist to provide known translations.
Was this Phrase book somehow generated from old QCAD version (LibreCAD?) or is it from some public Phrase server?
Because when I tried to open it id Qt Linguist it reported error on line 277.
After checking the file, I saw that all unknown phrases have are missing </target> so simple find and replace had fixed this error.

I'm just asking this to know if at some (later?) time is smart to do a full translation of this file, to help others.

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Wed Nov 13, 2013 8:16 pm

miharix wrote:Was this Phrase book somehow generated from old QCAD version (LibreCAD?) or is it from some public Phrase server?
Yes, that was generated form various sources.
miharix wrote:Because when I tried to open it id Qt Linguist it reported error on line 277.
After checking the file, I saw that all unknown phrases have are missing </target> so simple find and replace had fixed this error.
Thanks for letting me know.
miharix wrote:I'm just asking this to know if at some (later?) time is smart to do a full translation of this file, to help others.
Don't worry about that - I can automatically regenerate that file anytime from QCAD 2 / QCAD 3 sources and any other .ts or .po files.

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Re: Slovenian translation

Post by miharix » Sat Nov 30, 2013 8:29 pm

Hi,

I'm progressing slow, but steady.
For now I only translated the files > 2KB, so now there are only approx 230 files left :lol:

Just for fun I tried, to see how the current translations looks in QCAD,
so I copied all .ts and .qm files from dir "ts" and "scripts" to QCAD install dir.
but QCAD doest seem to grab the new files.

Do I need to perform, some sort of recompiling, to make the translation visible ?

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Sun Dec 01, 2013 11:20 am

Thanks for your work!

To use .ts files with QCAD, you have to convert them into .qm files first (in Qt Linguist File - Release).
These .qm files have to be copied to the appropriate location in your QCAD installation.

For example for the line drawing tool:
./scripts/Draw/Line/Line2P/ts/Line2P_sl.qm

The compiled .qm translations of C++ sources (qcadcore, qcadentity, ...) have to be installed in the 'ts' directory of your QCAD installation.

This process is fully automated here, so only the .ts files are needed to create a release with the Slovenian translation.

If you like you can also send me some files you have already translated so I can test them and make some screenshots.

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Re: Slovenian translation

Post by miharix » Sun Dec 01, 2013 12:17 pm

It's working! :D

Does the "Qt Linguist" have some hidden console switches, or how do you perform the bach release?
I'm asking because, friends over Slovenian RC forum, are wiling to check the correctness of the translation.

I keep translation files in my public dropbox folder ( sh/5p0aetr1llzgw2v/nHpkezNThJ ).

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Sun Dec 01, 2013 12:29 pm

miharix wrote:It's working! :D
Cool :)
miharix wrote:Does the "Qt Linguist" have some hidden console switches, or how do you perform the bach release?
Qt comes with a command line utility to do releases: lrelease

My release script does something like this (Bash):
find src -name "*.pro" | xargs lrelease
find scripts -name "*.pro" | xargs lrelease

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Re: Slovenian translation

Post by miharix » Sun Dec 01, 2013 1:50 pm

8)
Great tip!

For other potential QCAD translators, that may stumble over this thread. This is the windows batch version:

Code: Select all

FOR /R "<dir path>\qcad-master" %%F IN (*_sl.ts) DO ( "C:\Qt\Qt5.1.1\5.1.1\msvc2012_64\bin\lrelease.exe" "%%F" )

User avatar
miharix
Junior Member
Posts: 11
Joined: Sat Nov 09, 2013 9:33 pm

Almost done

Post by miharix » Sun Dec 08, 2013 12:44 am

Hi!

I'm almost done, but I stuck on 8 files that are crashing Qt Linguist.
In all I see there is missing a part of the "<xml>" structure.
I also looked in other translations but other files are also "broken"

The files are:
  • \scripts\Widgets\OptionsToolBar\ts\OptionsToolBar_sl.ts
  • \scripts\ImportExport\SvgImporter\ts\SvgImporter_sl.ts
  • \scripts\Widgets\AutoZoomView\ts\AutoZoomView_sl.ts
  • \scripts\Widgets\MouseDisplay\ts\MouseDisplay_sl.ts
  • \scripts\Widgets\ProgressBar\ts\ProgressBar_sl.ts
  • \scripts\View\ViewToolBars\ts\ViewToolBars_sl.ts
  • \scripts\Misc\MiscDraw\ts\MiscDraw_sl.ts
  • \scripts\Widgets\TabBar\ts\TabBar_sl.ts

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: Slovenian translation

Post by andrew » Sun Dec 08, 2013 11:32 am

Thanks for the report.

These files are empty (there is nothing to translate there).

I wasn't aware that Qt Linguist might crash because of those, so I will remove those ts folders entirely.

Post Reply

Return to “QCAD Programming, Script Programming and Contributing”