Qt multi language app deploying on target board

118 views
Skip to first unread message

u2bpavankumar

unread,
Mar 30, 2015, 9:56:51 AM3/30/15
to andro...@googlegroups.com
Hi,

I am trying to create a multi language in qt with language options as Chinese, Korean. I have followed the example from the below link

http://qt-project.org/faq/answer/how_can_i_dynamically_switch_between_languages_in_my_application_using_e.g_

I have changed the language options in above example from t1_fr, tf_sp to t1_zh (simpiified chinese) and t1_ko (korean) respectively

I have added the t1_zh.ts, t1_zh.qm, t1_ko.ts, t1_ko.qm files as resource files on to my application

Added the below line in my .pro file
TRANSLATIONS += t1_ko.ts\
                t1_zh.ts

Run the linguist and lrelease on the ts file to apply the translations.

I am able to compile it & run it on my host pc (Ubuntu 14.04) and can see appropriate language when selected from the combo box.

Now I am trying to compile and deploy the same onto my target board (imx6q based board wandboard-quad). I have cross compiled it successfully and copied to target.

When I started the app on wandboard, I can see english language absolutely perfect.  But when selected "zh" (i.e. chinese) from combo box, I can't see anything on the screen. when selected "ko" (i.e. korean) from combo box, I can see some boxes on the screen but not the appropriate font.

Since I have included the qm files as resources in my app, I think there is no need to copy them onto target board.

I am missing something else to get the multi language app running on target board. Can some one please let me know what else needs to be done


Regards,
Pavan


zoltan...@gmail.com

unread,
Mar 30, 2015, 10:55:21 AM3/30/15
to andro...@googlegroups.com

Hi,


Are appropriate fonts installed on target device?


Br,


Zoltan


u2bpavankumar írta ekkor: 2015.03.30. 15:56

--
You received this message because you are subscribed to the Google Groups "android-qt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-qt+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

u2bpavankumar

unread,
Mar 31, 2015, 1:54:43 AM3/31/15
to andro...@googlegroups.com
Hi Zoltan,

I do have installed fonts on target device.

I have compiled Qt4.7 and generated makeqpf tool by following the tutorial at

http://www.programmershare.com/3296975/

As per above link, I have used the makeqpf to generate fonts in qpf2 format and copied onto target at /usr/lib/fonts.

Let me know is there anything else to be done

Regards,
Pavan

u2bpavankumar

unread,
Mar 31, 2015, 6:31:06 AM3/31/15
to andro...@googlegroups.com
Hi,

I have made some progress in this aspect. After deploying the my application onto wandboard, initially I could see only english.

I made use of makeqpf tool and converted the UnDotum.ttf font (korean font) to qpf format and copied them (both UnDotum.ttf and qpf files) on to target at fonts location (on my board it was /usr/lib/fonts). By doing so, when I select ko from combo box I can see the text translated to korean on my GUI screen and it works fine.

I have tried the same for chinese font also. I have converted wqy-zenhei.ttf font (chinese font) to qpf format and copied them (both wqy-zenhei.ttf and its qpf format) on to target at fonts location. But when I select zh, text simply disappears on the screen and nothing is displayed.

Is there any additional step to be done to display chinese font on the GUI screen.

Please let me know

Thanks in advance

Regards,
Pavan
Reply all
Reply to author
Forward
0 new messages