Hi, this is my code now:

Qt Code:
  1. m_pToolbox = new QToolBox();
  2. Q_CHECK_PTR(m_pToolbox);
  3.  
  4.  
  5. m_pTabSifrant = new QTabWidget();
  6. Q_CHECK_PTR(m_pTabSifrant);
  7. m_pTabVnos = new QTabWidget();
  8. Q_CHECK_PTR(m_pTabVnos);
  9. m_pTabIsci = new QTabWidget();
  10. Q_CHECK_PTR(m_pTabIsci);
  11. m_pTabNatisni = new QTabWidget();
  12. Q_CHECK_PTR(m_pTabNatisni);
  13.  
  14. //tabs
  15. m_pToolbox->addItem(m_pTabSifrant,trUtf8("Šifranti"));
  16. m_pToolbox->addItem(m_pTabVnos,trUtf8("Vnos"));
  17. m_pToolbox->addItem(m_pTabIsci,trUtf8("Iskanje"));
  18. m_pToolbox->addItem(m_pTabNatisni,trUtf8("Tiskanje"));
  19.  
  20. //add QToolBox to the main widget
  21. m_pMainLayout->addWidget(m_pToolbox);
  22. //set stretch factor to 1
  23. m_pMainLayout->setStretchFactor(m_pToolbox,1);
  24.  
  25. //add blank widget to main widget --> we'll have to change that to insert a widget we'll use. This is just for testing purposes
  26. QWidget *test = new QWidget();
  27. m_pMainLayout->addWidget(test);
  28. m_pMainLayout->setStretchFactor(test,3);
To copy to clipboard, switch view to plain text mode 


Now I want a way to resize and hide the QToolBox, like in kpdf program. There's a little sidebar (where the slides are in minimal form) and you can resize it and hide it. When it's hidden you can also drag it on the right again to show it..


How can I do that.