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. Bad antialized text shadow
Forum Updated to NodeBB v4.3 + New Features

Bad antialized text shadow

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 280 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.
  • T Offline
    T Offline
    tatraian
    wrote on last edited by
    #1

    Hello,

    I tried to create a white text with shadow on yellow background. On my linux I get ugly text.

    Here is the example qml

    import QtQuick 2.11
    import QtQuick.Window 2.11
    import QtGraphicalEffects 1.0
    
    Window {
        visible: true
        width: 640
        height: 480
        Rectangle {
            id: background
            anchors.fill: parent
            color: "#f7dc16"
    
            Text {
                id: text
                anchors.verticalCenter: background.verticalCenter
                anchors.horizontalCenter: background.horizontalCenter
                color: "white"
                font.bold: true
                font.pixelSize: 22
                text: "Hello World"
                layer.enabled: true
                layer.effect: DropShadow {
                    verticalOffset: 1
                    horizontalOffset: 1
                    radius: 0
                }
            }
        }
    
        title: qsTr("Hello World")
    }
    

    In this case I get "green" lines at the left side of the rendered characters:
    0_1537374425158_Screenshot_20180919_182533.png

    Could you tell me, what I make wrong? Thanks:
    Antal Tatrai

    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