Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Qt quick use Label to show Chinese words problems
Qt 6.11 is out! See what's new in the release blog

Qt quick use Label to show Chinese words problems

Scheduled Pinned Locked Moved Mobile and Embedded
1 Posts 1 Posters 739 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    story1225
    wrote on last edited by
    #1

    I created a qt quick application in QtCreater 3.1.2, and I added some Label and Text to show chinese words. Running it on PC is corrected, but running on a real android device with api-10(sdk version 2.3.3) is uncorrected. Test running on higher sdk device such as Samsung was corrected. My code is here:

    import QtQuick 2.2
    import QtQuick.Controls 1.1

    ApplicationWindow {
    visible: true
    width: 480
    height: 640

    Text {
        id: id1
        text: qsTr("你好1")
        anchors.top: parent.top
        anchors.left: parent.left
        anchors.right: parent.right
        height: 100
        font.pixelSize:  55
    }
    
    Label{
        id: id2
        text: qsTr("你好2")
        anchors.top: id1.bottom
        anchors.left: parent.left
        anchors.right: parent.right
        height: 100
        font.pixelSize:  55
    }
    
    Text {
        id: id3
        text: qsTr("你好3")
        anchors.top: id2.bottom
        anchors.left: parent.left
        anchors.right: parent.right
        height: 100
        font.pixelSize:  55
        font.weight: Font.Black;
    }
    

    }

    The result on api-10 was here:
    http://photo.163.com/story2010/#m=1&aid=271112093&p=1

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved