QTfrontend/pages.h
changeset 728 033971bbe639
parent 718 f93a38d2c982
child 788 00720357601f
equal deleted inserted replaced
727:da975a75af09 728:033971bbe639
    57   AbstractPage(QWidget* parent = 0) {
    57   AbstractPage(QWidget* parent = 0) {
    58     font14 = new QFont("MS Shell Dlg", 14);
    58     font14 = new QFont("MS Shell Dlg", 14);
    59   }
    59   }
    60   virtual ~AbstractPage() {};
    60   virtual ~AbstractPage() {};
    61 
    61 
    62   QPushButton* addButton(const char* btname, QGridLayout* grid, int wy, int wx) {
    62   QPushButton* addButton(QString btname, QGridLayout* grid, int wy, int wx) {
    63     QPushButton* butt = new QPushButton(this);
    63     QPushButton* butt = new QPushButton(this);
    64     butt->setFont(*font14);
    64     butt->setFont(*font14);
    65     butt->setText(QPushButton::tr(btname));
    65     butt->setText(btname);
    66     grid->addWidget(butt, wy, wx);
    66     grid->addWidget(butt, wy, wx);
    67     return butt;
    67     return butt;
    68   };
    68   };
    69 
    69 
    70   QPushButton* addButton(const char* btname, QGridLayout* grid, int wy, int wx, int rowSpan, int columnSpan) {
    70   QPushButton* addButton(QString btname, QGridLayout* grid, int wy, int wx, int rowSpan, int columnSpan) {
    71     QPushButton* butt = new QPushButton(this);
    71     QPushButton* butt = new QPushButton(this);
    72     butt->setFont(*font14);
    72     butt->setFont(*font14);
    73     butt->setText(QPushButton::tr(btname));
    73     butt->setText(btname);
    74     grid->addWidget(butt, wy, wx, rowSpan, columnSpan);
    74     grid->addWidget(butt, wy, wx, rowSpan, columnSpan);
    75     return butt;
    75     return butt;
    76   };
    76   };
    77 
    77 
    78   QPushButton* addButton(const char* btname, QBoxLayout* box, int where) {
    78   QPushButton* addButton(QString btname, QBoxLayout* box, int where) {
    79     QPushButton* butt = new QPushButton(this);
    79     QPushButton* butt = new QPushButton(this);
    80     butt->setFont(*font14);
    80     butt->setFont(*font14);
    81     butt->setText(QPushButton::tr(btname));
    81     butt->setText(btname);
    82     box->addWidget(butt, where);
    82     box->addWidget(butt, where);
    83     return butt;
    83     return butt;
    84   };
    84   };
    85 
    85 
    86   QFont * font14;
    86   QFont * font14;