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. Z Order of QWidgets
Forum Updated to NodeBB v4.3 + New Features

Z Order of QWidgets

Scheduled Pinned Locked Moved Unsolved General and Desktop
4 Posts 2 Posters 14.6k 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.
  • H Offline
    H Offline
    hjohn
    wrote on last edited by aha_1980
    #1

    How to set Z order of multiple widgets?

    [Edit ~aha_1980: fixed typo in title]

    raven-worxR 1 Reply Last reply
    1
    • H hjohn

      How to set Z order of multiple widgets?

      [Edit ~aha_1980: fixed typo in title]

      raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by
      #2

      @hjohn
      QWidget::lower() / QWidget::raise() / QWidget::stackUnder()

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      H 1 Reply Last reply
      6
      • raven-worxR raven-worx

        @hjohn
        QWidget::lower() / QWidget::raise() / QWidget::stackUnder()

        H Offline
        H Offline
        hjohn
        wrote on last edited by hjohn
        #3

        @raven-worx But If new widget create , how to know which widget is having higher Z oder.
        Is there anything like Z order in qt?

        raven-worxR 1 Reply Last reply
        0
        • H hjohn

          @raven-worx But If new widget create , how to know which widget is having higher Z oder.
          Is there anything like Z order in qt?

          raven-worxR Offline
          raven-worxR Offline
          raven-worx
          Moderators
          wrote on last edited by
          #4

          @hjohn
          the last added widget is the topmost.

          There is no such z-index property.

          But you can check the QObject::children() list and compare the indexes of 2 widgets.
          Lower children are stacked behind (if they are QWidgets).

          --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
          If you have a question please use the forum so others can benefit from the solution in the future

          1 Reply Last reply
          2

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved