Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

How to? GridLayout 2 by 2 Widgets with vertical Splitter between row 1 and 2?



  • Hello,

    i need a grid layout (2 by 2 widgets) and between both rows a vertical splitter.
    How do i do that? Is that possible?

    Thx


  • Lifetime Qt Champion

    Hi,

    Something like a QSplitter containing two widgets which will have QVBoxLayout and contain your 2 widgets ?



  • Hi,
    W1 and W3 are plots, and W2 and W4 are legends. W2 and W4 can change the width and
    the layout broke.

    W1 W2
    ====== Splitter
    W3 W4

    In that case the upper and lower QVBoxLayout are independent and i need to control the width
    of W1 and W3 by myself.

    I found a similar solution

    W1 W2
    === === (two Splitter)
    W3 W4

    I use two splitter and but the to splitter into a grid (or horis. layout) . In that case W1 is aligned to W3 and W2 to W4.
    This needs a signal/slot connection of both splitters but it is working.

    Stefan


  • Lifetime Qt Champion

    Shouldn't the legend be part of the plot ?


Log in to reply