Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Transparent image on top of QTextEdit

Transparent image on top of QTextEdit

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 867 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.
  • V Offline
    V Offline
    vezprog
    wrote on last edited by
    #1

    I am trying to figure out the best way to accomplish an image overlay in a QTextEdit. I am looking to put a logo of some sort as background on a QTextEdit (possibly tiled at an angle to keep the image aspect ratio, or just a single image that stretches to the size of the text edit). But I am looking to make the actual logo transparent or barely visible so it doesn't interrupt the user from reading the text in the text edit.

    I tried setting a background image in the stylesheet for the text edit, but there there isn't any options for a rotated image / transparency all at once.

    Is there any way to do this without custom painting any overriding the paint method on the text edit?

    Right now, I have simple stylesheet like so:

    @
    #text_status {
    background-color: white;
    background-image: url(:/images/img_logo.png);
    }
    @

    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