--- /dev/null
+#include <cpExtensions/QT/QuadSplitter.h>
+
+#include <cpExtensions/Config.h>
+
+#ifdef cpExtensions_Interface_QT4
+
+/**
+ * Inspired by:
+ * https://forum.qt.io/topic/7144/quad-splitter-windows-an-implementation/2
+ */
+
+// -------------------------------------------------------------------------
+cpExtensions::QT::QuadSplitter::
+QuadSplitter( QWidget* parent, Qt::WindowFlags f )
+ : QFrame( parent, f )
+{
+ this->m_Parent.setOrientation(Qt::Vertical);
+ this->m_Parent.addWidget(&this->m_Upper);
+ this->m_Parent.addWidget(&this->m_Bottom);
+
+ QObject::connect(
+ &this->m_Upper, SIGNAL( splitterMoved( int, int ) ),
+ this, SLOT( _SyncBottom( int, int ) )
+ );
+ QObject::connect(
+ &this->m_Bottom, SIGNAL( splitterMoved( int, int ) ),
+ this, SLOT( _SyncUpper( int, int ) )
+ );
+}
+
+// -------------------------------------------------------------------------
+cpExtensions::QT::QuadSplitter::
+~QuadSplitter( )
+{
+}
+
+// -------------------------------------------------------------------------
+void cpExtensions::QT::QuadSplitter::
+show( )
+{
+ this->m_Parent.show( );
+}
+
+// -------------------------------------------------------------------------
+void cpExtensions::QT::QuadSplitter::
+addWidgets( QWidget* a, QWidget* b, QWidget* c, QWidget* d )
+{
+ this->m_Upper.addWidget( a );
+ this->m_Upper.addWidget( b );
+ this->m_Bottom.addWidget( c );
+ this->m_Bottom.addWidget( d );
+}
+
+// -------------------------------------------------------------------------
+void cpExtensions::QT::QuadSplitter::
+_SyncBottom( int a, int b )
+{
+ this->m_Bottom.setSizes( m_Upper.sizes( ) );
+}
+
+// -------------------------------------------------------------------------
+void cpExtensions::QT::QuadSplitter::
+_SyncUpper( int a, int b )
+{
+ this->m_Upper.setSizes( m_Bottom.sizes( ) );
+}
+
+#endif // cpExtensions_Interface_QT4
+
+// eof - $RCSfile$