Results 1 to 10 of 10

Thread: Write Qt program to a language with special symbols

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Write Qt program to a language with special symbols

    Try to use your special letters direct. You just have to make sure that your *.cpp file is encoded in utf8. So you will save time for escaping them.
    Qt Code:
    1. ui->nextButton->setText(trUtf8("Déplacer à l'image &suivante"));
    To copy to clipboard, switch view to plain text mode 

  2. #2
    Join Date
    Aug 2010
    Posts
    107
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Talking Re: Write Qt program to a language with special symbols

    Nice info, thak you all for this post

  3. #3
    Join Date
    Jul 2010
    Location
    /home/hakermania/
    Posts
    233
    Thanks
    129
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: Write Qt program to a language with special symbols

    No, i've tried this. I need to place these strange symbols....
    When you 're trying to help somebody in the newbie section, don't forget that he is a newbie. Be specific and give examples.

  4. #4
    Join Date
    Jun 2010
    Posts
    142
    Thanks
    11
    Thanked 4 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: Write Qt program to a language with special symbols

    Aren't the contents of tr() supposed to be English?

  5. #5
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Write Qt program to a language with special symbols

    Quote Originally Posted by MTK358 View Post
    Aren't the contents of tr() supposed to be English?
    No, you can also perfectly write latin in tr(). The language just should fit in ASCII in normal case.

  6. #6
    Join Date
    Jan 2006
    Location
    Germany
    Posts
    4,380
    Thanks
    19
    Thanked 1,005 Times in 913 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows Symbian S60
    Wiki edits
    5

    Default Re: Write Qt program to a language with special symbols

    Try the attached project without changing the file encoding and see if it works.
    test_trutf8.zip

Similar Threads

  1. Replies: 7
    Last Post: 13th September 2011, 13:15
  2. /usr/bin/ld: Undefined symbols:
    By ataffard in forum Qt Programming
    Replies: 0
    Last Post: 2nd May 2008, 01:24
  3. math symbols
    By genick bar-meir in forum Qt Programming
    Replies: 3
    Last Post: 17th August 2007, 07:29
  4. greek symbols
    By genick bar-meir in forum Qt Programming
    Replies: 2
    Last Post: 17th July 2007, 22:44
  5. Display special symbols
    By ShaChris23 in forum Newbie
    Replies: 1
    Last Post: 30th April 2007, 23:51

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.