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. Annoying painting problem when the app starts
Forum Updated to NodeBB v4.3 + New Features

Annoying painting problem when the app starts

Scheduled Pinned Locked Moved Mobile and Embedded
3 Posts 2 Posters 1.2k 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.
  • R Offline
    R Offline
    ronen110
    wrote on last edited by
    #1

    Hi,

    I'm using QMainwindow as the main widget and all my layouts are set to auto expand.
    When the app starts android paints it wrong (looks like landscape paint on portrait screen).
    After i rotate the screen its painting it just fine....

    Pictures :
    -The problematic one on start
    https://android-qt.googlegroups.com/attach/4fe791229167a722/problem.png?view=1&part=5
    -The good one after i rotated the screen twice (to get back to portrait)
    https://android-qt.googlegroups.com/attach/4fe791229167a722/ok.png?view=1&part=4

    I tried manually to force a resizeEvent but nothing worked!

    any idea?

    Thanks,
    Ronen

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mvuori
      wrote on last edited by
      #2

      Perhaps you could rotate your window in it's class's constructor, before it gets even created (and painted). (If you don't subclass QMainWindow for your app, this is a reason to do so.)

      1 Reply Last reply
      0
      • R Offline
        R Offline
        ronen110
        wrote on last edited by
        #3

        How can i manually force window rotation?
        I tried to use resize as a work around and it didnt work.

        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