void setupAddressWidget(QValidatedLineEdit *widget, QWidget *parent)
{
    parent->setFocusProxy(widget);

    widget->setFont(fixedPitchFont());
    // We don't want translators to use own addresses in translations
    // and this is the only place, where this address is supplied.
    widget->setPlaceholderText(QObject::tr("Enter a Machinecoin address (e.g. %1)").arg(
        QString::fromStdString(DummyAddress(Params()))));
    widget->setValidator(new MachinecoinAddressEntryValidator(parent));
    widget->setCheckValidator(new MachinecoinAddressCheckValidator(parent));
}
Exemple #2
0
void setupAddressWidget(QValidatedLineEdit *widget, QWidget *parent, bool fAllowEmpty)
{
    parent->setFocusProxy(widget);

    widget->setFont(fixedPitchFont());
#if QT_VERSION >= 0x040700
    // We don't want translators to use own addresses in translations
    // and this is the only place, where this address is supplied.
    widget->setPlaceholderText(QObject::tr("Enter a V Core address (e.g. %1)").arg(
        QString::fromStdString(DummyAddress(Params()))));
#endif
    widget->setValidator(new BitcoinAddressEntryValidator(parent, fAllowEmpty));
    widget->setCheckValidator(new BitcoinAddressCheckValidator(parent));
}