Results 1 to 20 of 60

Thread: label Text is not changing using Qt Linguist

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    Either the font you use doesn't have the glyph or the ts file is saved with a wrong encoding (should be UTF-8 I think). Did you use Linguist to create the translation?

  2. #2
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Default Re: label Text is not changing using Qt Linguist

    Either the font you use doesn't have the glyph
    how it can be beacuse one of qt manual examples are running well so i beleive there is not problem with fonts...
    r the ts file is saved with a wrong encoding (should be UTF-8 I think).
    how it can be done in ts file
    as i add entered the line in ts file
    <?xml version="1.0" encoding="utf-8"?>
    but when again i do it lupdate to modify the file then it automatically deleted in ts file
    Did you use Linguist to create the translation?
    yes i am using linguist
    i am using lupdate for.ts file and lrelease for .qm files

    so tell me how it can be done????

  3. #3
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    Quote Originally Posted by thomasjoy View Post
    how it can be done in ts file
    as i add entered the line in ts file
    <?xml version="1.0" encoding="utf-8"?>
    This doesn't matter. It's just text. You might be saving the file using a completely different encoding regardless of what you put into the header.

    but when again i do it lupdate to modify the file then it automatically deleted in ts file
    I didn't understand this one... What deleted what?

    yes i am using linguist
    i am using lupdate for.ts file and lrelease for .qm files
    If you're not touching the files manually then you shouldn't have any problems. Could you post such example ts/qm files that don't work for you (make it simple please - a single message containing a single character that doesn't work)?

  4. #4
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Question Re: label Text is not changing using Qt Linguist

    Could you post such example ts/qm files that don't work for you (make it simple please - a single message containing a single character that doesn't work)?

    see the attachment and see the translation tag for French
    showing Frenais rather tahn Frençais
    Attached Files Attached Files
    Last edited by thomasjoy; 25th September 2007 at 14:02.

  5. #5
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    The ts file contains the string 'franais' (and why is the message marked as unfinished? You should have confirmed the translation...).

    xml Code:
    1. <message>
    2. <source>French</source>
    3. <translation type="unfinished">Franais</translation>
    4. </message>
    To copy to clipboard, switch view to plain text mode 

    Are you really using Linguist to provide the translation? Maybe you should consider upgrading your Qt installation then...

    Here is how it should look like...
    Attached Files Attached Files

  6. #6
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Question Re: label Text is not changing using Qt Linguist

    as i had given you my ts and qm
    you just use it in qt4.1
    may be it affects...
    see what i am doing

    qmake -project
    adding ts file in .pro with TRANSLATIONS+=

    lupdate unicodetest.pro (create unicodetest_en.ts and unicodetest_fr.ts)
    (and why is the message marked as unfinished?
    its automatically comes with lupdate

    then i manully add translation of French in translation tag (Frençais)

    then lupdate unicodetest.pro (when i open and see the ts file it shows Frenais)

    lrelease unicodetest.pro

    qmake &&make


    all these commands i am running

    now do tell what to do????
    Last edited by thomasjoy; 25th September 2007 at 14:59.

  7. #7
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    Quote Originally Posted by thomasjoy View Post
    then i manully add translation of French in translation tag (Frençais)
    Define "manually". Using what application?

  8. #8
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Question Re: label Text is not changing using Qt Linguist

    manually means by own between the translation tags
    i am using language tools of google to try the unicode application
    i am not getting if in one of my application of trial is working then its not working
    i am getting one difference as what you said in translation tags
    it is automatically changes after 2nd lupdate (which is done for modification)

    i enter "Frençais"
    lupdate covert it "Frenais"
    according to you it should be "Fran?ßais"

    according to you it is the problem of encoding ....do tell me where i have to enter the encoding part

    do tell me how it should be done???

  9. #9
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    Quote Originally Posted by thomasjoy View Post
    manually means by own between the translation tags
    i am using language tools of google to try the unicode application
    So why did you say that you were using Linguist??????? I asked you precisely if you were using Linguist to do the translation and you said yes!

    Use Linguist instead of uncompatible tools and your problem will vanish.

  10. #10
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Default Re: label Text is not changing using Qt Linguist

    i already told my steps to create ts files
    as you are saying
    So why did you say that you were using Linguist??????? I asked you precisely if you were using Linguist to do the translation and you said yes!
    tell me that lupdate and lrelease are not the tools of linguist now again telling you steps

    i had use lupdate to create .ts files

    then whatever is my translation for my source in ts i do enter then between the translation tags of .ts files

    then lupate to modify the .ts file

    at last lrelease for .qm files

    now tell where i am wrong???also tell for some source and translation why this error occurs on time of modification of .ts file (i.e lupdate again) "XML error: Parse error at line 1295, column 14 (tag mismatch)."??

  11. #11
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,018 Times in 4,794 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: label Text is not changing using Qt Linguist

    There are three tools: lupdate, lrelease and linguist. And I mean the last one - one you should use for performing the translation itself. You shouldn't use a text editor nor any other 3rd party tool, because they don't guarantee that you'll be using the correct encoding, etc. So if you want your problem fixed, use Linguist please. Otherwise you'll be just running in circles like we have been for the last two pages of this thread.

    Just to be clear - I mean this tool: http://doc.trolltech.com/latest/ling...anslators.html

  12. #12
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Default Re: label Text is not changing using Qt Linguist

    wysota ,please cool down and read this reply and tell where i am wrong
    from the start of the query i was really hoping the reply by you only for the topic of linguist because i beleive you are the really a "GURU" of this forum...

    yes i already tested that also
    as i had already told you.....

    linguist is giving "!" yes i know even it against to validation rule
    so i want to know how it can be resolved???
    and it gives the error on time of modification of ts file (lupdate 2nd time) not on time of creation...

    due to this error some translations are not working...
    so please dont get angy by using
    like we have been for the last two pages of this thread.
    just tell me the simply solution means why still its giving the error for my query...??

    hope you are not angry...

    thanks in advance

Similar Threads

  1. Replies: 15
    Last Post: 31st January 2020, 18:25
  2. Unhandled exception in qatomic
    By NewGuy in forum Qt Programming
    Replies: 14
    Last Post: 23rd July 2013, 09:49
  3. German text on the label in Linux
    By Krish_ng in forum Qt Programming
    Replies: 2
    Last Post: 13th July 2007, 22:20
  4. Replies: 1
    Last Post: 24th October 2006, 16:40
  5. Changing the text color of a QTreeView leaf.
    By johnny_sparx in forum Qt Programming
    Replies: 3
    Last Post: 22nd March 2006, 23:58

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.