int setFont(struct boxFonts *fonts) { if (!setMenuFont(fonts->menuFont)) return 1; if (!setInputFont(fonts->inputFont)) return 1; if (!setButtonFont(fonts->buttonFont)) return 1; if (!setTitleFont(fonts->titleFont)) return 1; if (!setTextFont(fonts->textFont)) return 1; return 0; }
SettingsDialog::SettingsDialog(QWidget *parent) : QDialog(parent) { setupUi(this); qDebug()<< settings.fileName(); loadSettings(); connect (penPB,SIGNAL(clicked()),this, SLOT( setPenColor())); connect (brushPB,SIGNAL(clicked()),this, SLOT( setBrushColor())); ///@todo create own button to change color //connect (sheetPenPB,SIGNAL(clicked()),this, SLOT( setMyColor())); //connect (sheetBrushPB,SIGNAL(clicked()),this, SLOT( setMyColor())); connect (sheetPenPB,SIGNAL(clicked()),this, SLOT( setSheetPenColor())); connect (sheetBrushPB,SIGNAL(clicked()),this, SLOT( setSheetBrushColor())); connect (setTextPB,SIGNAL(clicked()),this, SLOT( setTextFont())); connect (texturePB,SIGNAL(clicked()),this, SLOT( setInner())); connect (okButton,SIGNAL(clicked()),this, SLOT( save())); }
ChangeDialog::ChangeDialog(ServerDialog *parent, ItWindow * win, ItAlignment * a, aligned_doc d, QDomNodeList &changes, bool * mark, bool acceptonly) : QDialog(parent), ui(new Ui::ChangeDialog) { ui->setupUi(this); server = parent; window = win; alignment = a; doc = d; changeList = changes; markState = mark; ui->markCheckBox->setChecked(*mark); setTextFont(window->view->font()); setAttribute(Qt::WA_DeleteOnClose, true); appendButton = new QPushButton(QIcon(":/images/16/list-add.png"), QString()); connect(appendButton, SIGNAL(clicked()), this, SLOT(appendChange())); appendButton->setEnabled(false); ui->buttonBox->addButton(appendButton, QDialogButtonBox::ActionRole); detachButton = new QPushButton(QIcon(":/images/16/list-remove.png"), QString()); connect(detachButton, SIGNAL(clicked()), this, SLOT(detachChange())); detachButton->setEnabled(false); ui->buttonBox->addButton(detachButton, QDialogButtonBox::ActionRole); if (acceptonly) { ui->buttonBox->button(QDialogButtonBox::No)->setVisible(false); } connect(ui->markCheckBox, SIGNAL(stateChanged(int)), this, SLOT(changeMark(int))); connect(ui->buttonBox, SIGNAL(clicked(QAbstractButton*)), this, SLOT(action(QAbstractButton*))); ui->buttonBox->button(QDialogButtonBox::Yes)->setEnabled(false); ui->buttonBox->button(QDialogButtonBox::YesToAll)->setEnabled(false); ui->buttonBox->button(QDialogButtonBox::No)->setEnabled(false); //ui->buttonBox->button(QDialogButtonBox::NoToAll)->setEnabled(false); changenum = 0; nextChangeNum = 0; autoAccept = false; joinConsChanges = -1; nextChange(); }
void Label::initialize(Container *const parent) { m_Parent = parent; setTextFont(m_Parent->getGlobalFont()); }