title: How to add multiple QPushButtons to a QTableView?
body: <p>I have a <code>QTableView</code> to which I want to set a <code>QPushButton</code> for every row. I am doing this as follows within my class derived from <code>QWidget</code> following an example found <a href="https://stackoverflow.com/questions/19411101/pyside-qtableview-example">here</a>:</p>
  
  <pre><code> for index in range(number_rows):
          btn_sell = QPushButton("Edit", self)
          btn_sell.clicked.connect(self.button_edit)
          table_view.setIndexWidget(table_view.model().index(index, 4), btn_sell)
  </code></pre>
  
  <p>If the table is drawn and I click on one of the <code>QPushButton</code> the method <code>self.button_edit</code> is called - but which one? It does not seem that an 'event' of any sort is given to <code>self.button_edit</code>, so how can I find the row-index of the <code>QPushButton</code> that was clicked within the <code>button_edit</code> method?</p>
  
  <p>Maybe there is a different way altogether to add a button to each row of a table?</p>