Important: Please read the Qt Code of Conduct -

How to set alway show indicator in TextArea scrollbar?

  • Hello,
    In Quick Control 2, how to set scrollbar indicator alway on in TextArea which attaches to a Flickable.

    Flickable {
        id: flickable
        anchors.fill: parent
        TextArea.flickable: TextArea {
            text: "TextArea\n...\n...\n...\n...\n...\n...\n"
            wrapMode: TextArea.Wrap
        ScrollBar.vertical: ScrollBar { }

  • Please file in a suggestion. Here's a little trick as a temporary workaround :)

        ScrollBar.vertical: ScrollBar {
            active: flickable.moving || pressed || hovered || true

  • Thanks jpnurmi, that's awesome trick :)

Log in to reply