Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. [SOLVED] i18n - chinese fonts

[SOLVED] i18n - chinese fonts

Scheduled Pinned Locked Moved QML and Qt Quick
3 Posts 2 Posters 2.2k 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.
  • P Offline
    P Offline
    portoist
    wrote on last edited by
    #1

    Hi guys!
    I am working on app that is going to be translated into chinese. I'v been doing some tests and I have found out that chinese font seems to have diferen height or something, it seems like there is a blank space under font, check the picture:
    "Image":https://www.dropbox.com/s/ba18ee647i9jbwm/chinese.png
    In qml i have just Text element inside Rectangle, my Text have following code:
    @
    Text {
    id: textField
    text: container.text
    color: header ? palette.activeFont : palette.font
    height: container.height
    width: container.width
    font.pixelSize: 18
    font.bold: showBorder
    verticalAlignment: Text.AlignVCenter
    horizontalAlignment: Text.AlignHCenter
    visible: !container.hide
    wrapMode: Text.Wrap
    elide: Text.ElideRight
    }
    @
    Is there any workaround? Or you know some fonts that are working right? Thanks for any advice!

    1 Reply Last reply
    0
    • L Offline
      L Offline
      leafaku
      wrote on last edited by
      #2

      Hi,
      Chinese is my local language.Can you show the fully code so I can compile on my computer.
      BR,
      Leaf

      1 Reply Last reply
      0
      • P Offline
        P Offline
        portoist
        wrote on last edited by
        #3

        Thanks for offer, but in the end i have found out that it was my fault:-)
        I was reading chinese text from DB and I didn't noticed that I have put it in DB with new line char in the end. So after removing new line - problem solved.
        Sorry.

        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