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. Android - Poor Qml Text fields & emojis alignment

Android - Poor Qml Text fields & emojis alignment

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
1 Posts 1 Posters 267 Views
  • 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.
  • M Offline
    M Offline
    m2dtkast
    wrote on last edited by m2dtkast
    #1

    Given

    import QtQuick 2.12
    import QtQuick.Window 2.12
    
    Window {
        visible: true
        width: 640
        height: 480
        title: qsTr("Hello World")
        Text{
            id:textOnly
            width:parent.widh
            height:40
        }
        TextInput {
            id: descInput
    
            horizontalAlignment: Text.AlignLeft
            cursorVisible: true
            anchors.top: textOnly.bottom
            //renderType: Text.NativeRendering
    
            width:parent.width
            height:200
            anchors.leftMargin: 10
            maximumLength: 8000
            wrapMode: TextEdit.WrapAtWordBoundaryOrAnywhere
            verticalAlignment: Text.AlignLeft
            //font.pixelSize: 16
            font.family: "Segoe UI Emoji"
            text:"\n🙂asdasdasdasdas🙂🙂🙂🙂🙂🙂"
            //font.weight: Font.Medium
            //font.hintingPreference: Font.PreferNoHinting
        }
        Rectangle{
            anchors.top: descInput.bottom
            color:"red"
            height: 200
            width:parent.width
            MouseArea{
                anchors.fill: parent
                onClicked: {
                    textOnly.text = descInput.text
                    console.debug(descInput.text)
                }
            }
        }
    }
    

    On android 9 & 10, with Qt 5.13 I get overlap between the"asdasdasdasdas" and the following emojicons.

    Is there a cludge available for this?

    EDIT : Found it might be related to the emoji font in Android 9 / 10

    https://bugreports.qt.io/browse/QTBUG-70657?focusedCommentId=437950&page=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-437950

    But is this the right solution? If I bind in the older emoji font?

    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