import QtQuick 2.12 import QtQuick.Window 2.12 Window { visible: true width: 640 height: 480 color: 'black' TextEdit { anchors.centerIn: parent width: 200 height: 20 text: 'Sample text' color: 'red' } }