Results 1 to 5 of 5

Thread: Read Arabic

  1. #1
    Join Date
    Jan 2016
    Posts
    54
    Thanks
    7
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Read Arabic

    Hi,

    I want to read arabic, for example :
    Qt Code:
    1. }
    2. MouseArea {
    3. anchors.fill: parent
    4. onClicked: {
    5. console.log("السلام عليكم");
    6. }
    7. }
    To copy to clipboard, switch view to plain text mode 

    My console display: ?????? ?????

    Cheers,

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Read Arabic

    There is no reading code in the example.

    Cheers,
    _

  3. #3
    Join Date
    Jan 2016
    Posts
    54
    Thanks
    7
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Read Arabic

    Yeah, I meant show the arabic text in the console out

    Qt Code:
    1. onClicked: {
    2. console.log("Hello " + "السلام عليكم");
    3. }
    To copy to clipboard, switch view to plain text mode 

    console out : Hello ?????? ?????

    Cheers,

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Read Arabic

    I am not sure console.log() can do that, it is a logging facility, not a generic console output facility.

    Or your terminal is not confiigured with a font that can how these glyphs.

    Have you tried using QString::toLocal8Bit() and std::cout in C++?

    Cheers,
    _

  5. #5
    Join Date
    Dec 2015
    Posts
    5
    Thanked 1 Time in 1 Post

    Default Re: Read Arabic

    For me it logs correctly.

Similar Threads

  1. Please help with Arabic text printing and PDF creation
    By ahmedb in forum Qt Programming
    Replies: 8
    Last Post: 11th November 2013, 21:10
  2. Qt demo with Arabic support
    By sabbas in forum Newbie
    Replies: 4
    Last Post: 2nd September 2013, 12:35
  3. html tags + arabic + Qt
    By BlueIceCream in forum Qt Programming
    Replies: 1
    Last Post: 25th December 2012, 00:11
  4. How use unicode in Arabic language?
    By mismael85 in forum Qt Programming
    Replies: 1
    Last Post: 18th November 2010, 13:08
  5. Fonts opensource for chinese and arabic
    By recalcati in forum Qt Programming
    Replies: 0
    Last Post: 30th April 2008, 10:06

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.