Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-2928

Designer: nested layouts take up space even when margins and spacing set to 0.

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P5: Not important
    • Some future release
    • None
    • Tools: Designer
    • None

    Description

      Using nested layouts in Designer, then even if setting all margins and spacing to 0, the inner layout will take up one pixel on each side so that a widget placed inside the inner layout will report a size smaller that it should have.

      Can be reproduced in Designer by created a widget (200, 200).
      Drag a QGridLayout onto the Form and set all margins and spacing to 0.
      Add a QWidget inside this inner QGridLayout.
      RightClick on the Form (the top level) and choose Lay Out in a Grid.

      The inner widget should now have a size of 182, 182. (The top level size, take away the top level default margin)
      Instead the inner widget has a size of 180, 180. The inner layout with 0 margin/spacing has consumed 1px on all sides.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kleint Friedemann Kleint
            sanonymous Nokia Qt Support (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes