QGridLayout - Colspan and rowspan

When putting controls in an grid layout you can configure them to span over columns and rows. However editing this int the designer is not that easy.

So its best to edit the *.ui file with your favorite editor and add the attributes there:

  <item row="0" column="5" rowspan="2" colspan="2">
   <widget class="QToolButton" name="toolButton">
    <property name="text">
     <string>...</string>
    </property>
   </widget>
  </item>

After saving the file the change should also be visible in the visual designer.



Datenschutzerklärung | Impressum