Beispiel #1
0
int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    TableView w;
    w.initializetablewidget();
    w.show();
//+++++++++++++++++++++this is  main from the hash function
    return a.exec();
}
Beispiel #2
0
/** void QWidget::show()
 * bind/QWidget.h:31
 */
static int TableView_show(lua_State *L) {
  try {
    TableView *self = *((TableView **)dub_checksdata(L, 1, "mimas.TableView"));
    self->show();
    return 0;
  } catch (std::exception &e) {
    lua_pushfstring(L, "show: %s", e.what());
  } catch (...) {
    lua_pushfstring(L, "show: Unknown exception");
  }
  return dub_error(L);
}
Beispiel #3
0
int main(int argc, char *argv[])
{
QApplication a(argc, argv);

QStandardItemModel model;

for ( int col = 0; col < 3; col++ )
{
    QList<QStandardItem*> list;
    for ( int row = 0; row < 5; row++ )
    {
        list.append(new QStandardItem);
    }
    model.appendColumn(list);
}

TableView view;

view.setModel(&model);
view.show();

return a.exec&#40;&#41;;
}