Hi, take a look at the code:

Qt Code:
  1. class vnosTab : public QTabWidget {
  2. public:
  3. vnosTab();
  4.  
  5. private:
  6. QVBoxLayout *m_pTopLayoutVnos;
  7.  
  8. QPushButton *m_pVnosUvoznihCarinskih;
  9. QPushButton *m_pVnosUvoznihNecarinskih;
  10. QPushButton *m_pVnosIzvoznihCarinskih;
  11. QPushButton *m_pVnosIzvoznihNecarinskih;
  12. };
To copy to clipboard, switch view to plain text mode 

Qt Code:
  1. vnosTab::vnosTab() {
  2. m_pTopLayoutVnos = new QVBoxLayout;
  3. Q_CHECK_PTR(m_pTopLayoutVnos);
  4.  
  5. //buttons in tab "Vnos"
  6. m_pVnosUvoznihCarinskih = new QPushButton(trUtf8("uvoznih carinskih pošiljk"));
  7. Q_CHECK_PTR(m_pVnosUvoznihCarinskih);
  8. m_pVnosUvoznihNecarinskih = new QPushButton(trUtf8("uvoznih necarinskih pošiljk"));
  9. Q_CHECK_PTR(m_pVnosUvoznihNecarinskih);
  10. m_pVnosIzvoznihCarinskih = new QPushButton(trUtf8("izvoznih carinskih pošiljk"));
  11. Q_CHECK_PTR(m_pVnosIzvoznihCarinskih);
  12. m_pVnosIzvoznihNecarinskih = new QPushButton(trUtf8("izvoznih necarinskih pošiljk"));
  13. Q_CHECK_PTR(m_pVnosIzvoznihNecarinskih);
  14.  
  15. m_pTopLayoutVnos->addWidget(m_pVnosUvoznihCarinskih);
  16. m_pTopLayoutVnos->addWidget(m_pVnosUvoznihNecarinskih);
  17. m_pTopLayoutVnos->addWidget(m_pVnosIzvoznihCarinskih);
  18. m_pTopLayoutVnos->addWidget(m_pVnosIzvoznihNecarinskih);
  19.  
  20. this->setLayout(m_pTopLayoutVnos);
  21. }
To copy to clipboard, switch view to plain text mode 


here I'm using the previously declared class
Qt Code:
  1. void qKobilica::addToolMenu() {
  2. setWindowTitle("Kobilica:");
  3. m_pTopLayout = new QVBoxLayout();
  4. m_pToolbox = new QToolBox;
  5.  
  6. m_pTabSifrant = new QTabWidget;
  7. m_pTabVnos = new vnosTab();
  8. //m_pTabVnos->setHorizontalPolicy(QSizePolicy::Maximum);
  9. m_pTabNatisni = new QTabWidget;
  10.  
  11. //tabs
  12. m_pToolbox->addItem(m_pTabSifrant,trUtf8("Šifranti"));
  13. m_pToolbox->addItem(m_pTabVnos,trUtf8("Vnos"));
  14. m_pToolbox->addItem(m_pTabNatisni,trUtf8("Tiskanje"));
  15. m_pTopLayout->addWidget(m_pToolbox);
  16. //add the central menu to the application
  17. setCentralWidget(m_pToolbox);
  18.  
  19. }
To copy to clipboard, switch view to plain text mode 
What I want to do is to resize the buttons (there are 4 at the moment) that would fill the whole canvas (now there's some space in between those buttons), I want only buttons to be on the screen.