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. What is Z-order ?
Forum Update on Monday, May 27th 2025

What is Z-order ?

Scheduled Pinned Locked Moved General and Desktop
5 Posts 4 Posters 6.1k Views
  • 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.
  • G Offline
    G Offline
    Ground
    wrote on last edited by
    #1

    I'm trying to understand how to read Qt documentation.
    I'm reading the QWidget section and i don't understand the part when they say : Z-order ...?
    Here is the extract :

    Every widget is rectangular, and they are sorted in a Z-order. A widget is clipped by its parent and by the widgets in front of it.

    Thks in advance, any help would be appreciated!

    1 Reply Last reply
    0
    • T Offline
      T Offline
      trickkx
      wrote on last edited by
      #2

      Widgets can be placed on top of each other.
      See Wikipedia for a definition of "z-order":http://en.wikipedia.org/wiki/Z-order

      1 Reply Last reply
      0
      • Chris KawaC Offline
        Chris KawaC Offline
        Chris Kawa
        Lifetime Qt Champion
        wrote on last edited by
        #3

        Basically it comes from a 3 dimensional axis naming convention. left/right position is the X coordinate, top/bottom is the Y coordinate and depth (closer/farther) is Z coordinate.

        1 Reply Last reply
        0
        • G Offline
          G Offline
          Guigui
          wrote on last edited by
          #4

          As the others said, the Z coordinates represent the position of an object in terms of depth. When two windows are on top of each other, the window with a higher Z value will be placed on top of the other one, thus masking a part of it (or maybe entirely).

          1 Reply Last reply
          0
          • G Offline
            G Offline
            Ground
            wrote on last edited by
            #5

            Great explanations, understand well now, thks all :) .(it reminds me now the z-index in html which is also about how the elements are arranged in terms of depth).

            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