Beispiel #1
0
/** init()
 */
void Kontrahenci::init() {
    allNames = dataLayer->kontrahenciGetFirmList();

    nipEdit->setInputMask(sett().value("ticMask", "999-999-99-99; ").toString());
    accountEdit->setInputMask(sett().value("accountMask", "99-9999-9999-9999-9999-9999-9999; ").toString());

    // connects
    connect(okButton, SIGNAL(clicked()), this, SLOT(okClick()));
}
Beispiel #2
0
/** Init
 */
void Towary::init() {
	selectData("", 0);

	jednCombo->addItems(sett().value("jednostki").toString().split("|"));
	cbVat->addItems(sett().value("stawki").toString().split("|"));

	connect(okButton, SIGNAL(clicked()), this, SLOT(okClick()));
	connect(cancelButton, SIGNAL(clicked()), this, SLOT(close()));
	connect(nettoEdit, SIGNAL(valueChanged(double)), this, SLOT(nettoChanged(double)));
	connect(spinBox2, SIGNAL(valueChanged(int)), this, SLOT(spinChanged(int)));
	connect(pkwiuBtn, SIGNAL(clicked()), this, SLOT(pkwiuGet()));
}
Beispiel #3
0
//界面
void FramelessWin2::InitTop()
{
    QWidget  *topSkin = new QWidget(this);
    topSkin->setMinimumHeight(160);
    //IconButton *setb = new IconButton(this,":/UI/btn_set_normal.png",":/UI/btn_set_hover.png",":/UI/btn_set_press.png");
    //IconButton *minb = new IconButton(this,":/UI/btn_mini_normal.png",":/UI/btn_mini_highlight.png",":/UI/btn_mini_down.png");
    IconButton2 *closeb = new IconButton2(this,":/UI/btn_close_normal.png",":/UI/btn_close_highlight.png",":/UI/btn_close_down.png");
    topSkin->setStyleSheet("border-image: url(:/UI/background.png);");

    connect(closeb,SIGNAL(clicked()),this,SLOT(close()));
    QHBoxLayout *topLay = new QHBoxLayout();
    topLay->setMargin(0);
    topLay->addStretch();
    //topLay->addWidget(setb,0,Qt::AlignRight | Qt::AlignTop);
    //topLay->addWidget(minb,0,Qt::AlignRight | Qt::AlignTop);
    topLay->addWidget(closeb,0,Qt::AlignRight | Qt::AlignTop);
    topSkin ->setLayout(topLay);

    QLabel *lb = new QLabel(this);
    QLabel *title = new QLabel(this);
    title->setText(LOCAL("应用程序登录确认"));
    lb->setText(m_info);
    lb->setStyleSheet("font: 75 11pt 'Times New Roman';");
    title->setStyleSheet("font: 75 11pt 'Times New Roman';");

    IconButton2 *okButton = new IconButton2(this,":/UI/button_login_normal.png",":/UI/button_login_hover.png",
                                             ":/UI/button_login_down.png");

    connect(okButton,SIGNAL(clicked()),this,SLOT(okClick()));
    okButton->AddTxtLabel();
    okButton->SetButtonText(QString::fromLocal8Bit("授权登录"));

    QVBoxLayout *mainLay = new QVBoxLayout(this);
    mainLay->addWidget(topSkin);
    mainLay->addWidget(title,0,Qt::AlignHCenter);
    mainLay->addStretch();
    mainLay->addWidget(lb,0,Qt::AlignHCenter);
    mainLay->addWidget(okButton,0,Qt::AlignHCenter);
    mainLay->addStretch();

}
ApplicationPreferencesDialog::ApplicationPreferencesDialog(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::ApplicationPreferencesDialog)
{
    ui->setupUi(this);
    ui->ui_functionNamesToolButton->hide();
    ui->ui_functionNamesLabel->hide();
    QPushButton const* okButton = ui->ui_buttonBox->button(QDialogButtonBox::Ok);
    QPushButton const* restoreButton = ui->ui_buttonBox->button(QDialogButtonBox::RestoreDefaults);
    connect(okButton, SIGNAL(clicked()), this, SLOT(okClick()));
    connect(restoreButton, SIGNAL(clicked()), this, SLOT(restoreDefaultsClick()));

    connect(ui->ui_unconnectedRailsToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_connectedRailsToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_functionNamesToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_functionCallsToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_systemFunctionToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_stringsToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_variablesToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));
    connect(ui->ui_grabbedTextToolButton, SIGNAL(clicked()), this, SLOT(colorToolButtonClicked()));

    init();
}