Browse Source

Add tooltips, make "amount" entry consistent in Options dialog

0.8
Wladimir J. van der Laan 14 years ago
parent
commit
5e1feddcb6
  1. 20
      gui/forms/addressbookdialog.ui
  2. 12
      gui/forms/editaddressdialog.ui
  3. 20
      gui/forms/sendcoinsdialog.ui
  4. 6
      gui/forms/transactiondescdialog.ui
  5. 18
      gui/src/bitcoingui.cpp
  6. 1
      gui/src/guiutil.cpp
  7. 18
      gui/src/optionsdialog.cpp

20
gui/forms/addressbookdialog.ui

@ -17,9 +17,12 @@
<item> <item>
<widget class="QTabWidget" name="tabWidget"> <widget class="QTabWidget" name="tabWidget">
<property name="currentIndex"> <property name="currentIndex">
<number>1</number> <number>0</number>
</property> </property>
<widget class="QWidget" name="sendTab"> <widget class="QWidget" name="sendTab">
<property name="toolTip">
<string/>
</property>
<attribute name="title"> <attribute name="title">
<string>Sending</string> <string>Sending</string>
</attribute> </attribute>
@ -43,6 +46,9 @@
</layout> </layout>
</widget> </widget>
<widget class="QWidget" name="receiveTab"> <widget class="QWidget" name="receiveTab">
<property name="toolTip">
<string/>
</property>
<attribute name="title"> <attribute name="title">
<string>Receiving</string> <string>Receiving</string>
</attribute> </attribute>
@ -97,6 +103,9 @@
</item> </item>
<item> <item>
<widget class="QPushButton" name="newAddressButton"> <widget class="QPushButton" name="newAddressButton">
<property name="toolTip">
<string>Create a new address</string>
</property>
<property name="text"> <property name="text">
<string>&amp;New Address...</string> <string>&amp;New Address...</string>
</property> </property>
@ -104,6 +113,9 @@
</item> </item>
<item> <item>
<widget class="QPushButton" name="copyToClipboard"> <widget class="QPushButton" name="copyToClipboard">
<property name="toolTip">
<string>Copy the currently selected address to the system clipboard</string>
</property>
<property name="text"> <property name="text">
<string>&amp;Copy to Clipboard</string> <string>&amp;Copy to Clipboard</string>
</property> </property>
@ -111,6 +123,9 @@
</item> </item>
<item> <item>
<widget class="QPushButton" name="editButton"> <widget class="QPushButton" name="editButton">
<property name="toolTip">
<string>Edit the currently selected address</string>
</property>
<property name="text"> <property name="text">
<string>&amp;Edit...</string> <string>&amp;Edit...</string>
</property> </property>
@ -118,6 +133,9 @@
</item> </item>
<item> <item>
<widget class="QPushButton" name="deleteButton"> <widget class="QPushButton" name="deleteButton">
<property name="toolTip">
<string>Delete the currently selected address from the list</string>
</property>
<property name="text"> <property name="text">
<string>&amp;Delete</string> <string>&amp;Delete</string>
</property> </property>

12
gui/forms/editaddressdialog.ui

@ -40,10 +40,18 @@
</widget> </widget>
</item> </item>
<item row="0" column="1"> <item row="0" column="1">
<widget class="QLineEdit" name="labelEdit"/> <widget class="QLineEdit" name="labelEdit">
<property name="toolTip">
<string>The label associated with this address book entry</string>
</property>
</widget>
</item> </item>
<item row="1" column="1"> <item row="1" column="1">
<widget class="QLineEdit" name="addressEdit"/> <widget class="QLineEdit" name="addressEdit">
<property name="toolTip">
<string>The address associated with this address book entry. This can only be modified for sending addresses.</string>
</property>
</widget>
</item> </item>
</layout> </layout>
</item> </item>

20
gui/forms/sendcoinsdialog.ui

@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>736</width> <width>736</width>
<height>140</height> <height>149</height>
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
@ -44,6 +44,9 @@
</item> </item>
<item row="3" column="1"> <item row="3" column="1">
<widget class="QLineEdit" name="payTo"> <widget class="QLineEdit" name="payTo">
<property name="toolTip">
<string>The address to send the payment to (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</string>
</property>
<property name="maxLength"> <property name="maxLength">
<number>34</number> <number>34</number>
</property> </property>
@ -57,6 +60,9 @@
<height>16777215</height> <height>16777215</height>
</size> </size>
</property> </property>
<property name="toolTip">
<string>Amount of bitcoins to send (e.g. 0.05)</string>
</property>
<property name="alignment"> <property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property> </property>
@ -64,6 +70,9 @@
</item> </item>
<item row="3" column="2"> <item row="3" column="2">
<widget class="QPushButton" name="pasteButton"> <widget class="QPushButton" name="pasteButton">
<property name="toolTip">
<string>Paste address from system clipboard</string>
</property>
<property name="text"> <property name="text">
<string>&amp;Paste</string> <string>&amp;Paste</string>
</property> </property>
@ -74,6 +83,9 @@
</item> </item>
<item row="3" column="3"> <item row="3" column="3">
<widget class="QPushButton" name="addressBookButton"> <widget class="QPushButton" name="addressBookButton">
<property name="toolTip">
<string>Look up adress in address book</string>
</property>
<property name="text"> <property name="text">
<string>Address &amp;Book...</string> <string>Address &amp;Book...</string>
</property> </property>
@ -126,6 +138,9 @@
</item> </item>
<item> <item>
<widget class="QPushButton" name="sendButton"> <widget class="QPushButton" name="sendButton">
<property name="toolTip">
<string>Confirm the send action</string>
</property>
<property name="text"> <property name="text">
<string>&amp;Send</string> <string>&amp;Send</string>
</property> </property>
@ -146,6 +161,9 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="toolTip">
<string>Abort the send action</string>
</property>
<property name="standardButtons"> <property name="standardButtons">
<set>QDialogButtonBox::Cancel</set> <set>QDialogButtonBox::Cancel</set>
</property> </property>

6
gui/forms/transactiondescdialog.ui

@ -15,7 +15,11 @@
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout"> <layout class="QVBoxLayout" name="verticalLayout">
<item> <item>
<widget class="QTextEdit" name="detailText"/> <widget class="QTextEdit" name="detailText">
<property name="toolTip">
<string>This pane shows a detailed description of the transaction</string>
</property>
</widget>
</item> </item>
<item> <item>
<widget class="QDialogButtonBox" name="buttonBox"> <widget class="QDialogButtonBox" name="buttonBox">

18
gui/src/bitcoingui.cpp

@ -75,10 +75,13 @@ BitcoinGUI::BitcoinGUI(QWidget *parent):
address = new QLineEdit(); address = new QLineEdit();
address->setReadOnly(true); address->setReadOnly(true);
address->setFont(GUIUtil::bitcoinAddressFont()); address->setFont(GUIUtil::bitcoinAddressFont());
address->setToolTip(tr("Your current default receiving address"));
hbox_address->addWidget(address); hbox_address->addWidget(address);
QPushButton *button_new = new QPushButton(tr("&New...")); QPushButton *button_new = new QPushButton(tr("&New..."));
button_new->setToolTip(tr("Create new receiving address"));
QPushButton *button_clipboard = new QPushButton(tr("&Copy to clipboard")); QPushButton *button_clipboard = new QPushButton(tr("&Copy to clipboard"));
button_clipboard->setToolTip(tr("Copy current receiving address to the system clipboard"));
hbox_address->addWidget(button_new); hbox_address->addWidget(button_new);
hbox_address->addWidget(button_clipboard); hbox_address->addWidget(button_clipboard);
@ -89,6 +92,7 @@ BitcoinGUI::BitcoinGUI(QWidget *parent):
labelBalance = new QLabel(); labelBalance = new QLabel();
labelBalance->setFont(QFont("Monospace")); labelBalance->setFont(QFont("Monospace"));
labelBalance->setToolTip(tr("Your current balance"));
hbox_balance->addWidget(labelBalance); hbox_balance->addWidget(labelBalance);
hbox_balance->addStretch(1); hbox_balance->addStretch(1);
@ -108,15 +112,18 @@ BitcoinGUI::BitcoinGUI(QWidget *parent):
labelConnections = new QLabel(); labelConnections = new QLabel();
labelConnections->setFrameStyle(QFrame::Panel | QFrame::Sunken); labelConnections->setFrameStyle(QFrame::Panel | QFrame::Sunken);
labelConnections->setMinimumWidth(130); labelConnections->setMinimumWidth(130);
labelConnections->setToolTip(tr("Number of connections to other clients"));
labelBlocks = new QLabel(); labelBlocks = new QLabel();
labelBlocks->setFrameStyle(QFrame::Panel | QFrame::Sunken); labelBlocks->setFrameStyle(QFrame::Panel | QFrame::Sunken);
labelBlocks->setMinimumWidth(130); labelBlocks->setMinimumWidth(130);
labelBlocks->setToolTip(tr("Number of blocks in the block chain"));
labelTransactions = new QLabel(); labelTransactions = new QLabel();
labelTransactions->setFrameStyle(QFrame::Panel | QFrame::Sunken); labelTransactions->setFrameStyle(QFrame::Panel | QFrame::Sunken);
labelTransactions->setMinimumWidth(130); labelTransactions->setMinimumWidth(130);
labelTransactions->setToolTip(tr("Number of transactions in your wallet"));
statusBar()->addPermanentWidget(labelConnections); statusBar()->addPermanentWidget(labelConnections);
statusBar()->addPermanentWidget(labelBlocks); statusBar()->addPermanentWidget(labelBlocks);
statusBar()->addPermanentWidget(labelTransactions); statusBar()->addPermanentWidget(labelTransactions);
@ -131,12 +138,19 @@ BitcoinGUI::BitcoinGUI(QWidget *parent):
void BitcoinGUI::createActions() void BitcoinGUI::createActions()
{ {
quit = new QAction(QIcon(":/icons/quit"), tr("&Exit"), this); quit = new QAction(QIcon(":/icons/quit"), tr("&Exit"), this);
quit->setToolTip(tr("Quit application"));
sendcoins = new QAction(QIcon(":/icons/send"), tr("&Send coins"), this); sendcoins = new QAction(QIcon(":/icons/send"), tr("&Send coins"), this);
sendcoins->setToolTip(tr("Send coins to a bitcoin address"));
addressbook = new QAction(QIcon(":/icons/address-book"), tr("&Address Book"), this); addressbook = new QAction(QIcon(":/icons/address-book"), tr("&Address Book"), this);
addressbook->setToolTip(tr("Edit the list of stored addresses and labels"));
about = new QAction(QIcon(":/icons/bitcoin"), tr("&About"), this); about = new QAction(QIcon(":/icons/bitcoin"), tr("&About"), this);
about->setToolTip(tr("Show information about Bitcoin"));
receivingAddresses = new QAction(QIcon(":/icons/receiving-addresses"), tr("Your &Receiving Addresses..."), this); receivingAddresses = new QAction(QIcon(":/icons/receiving-addresses"), tr("Your &Receiving Addresses..."), this);
receivingAddresses->setToolTip(tr("Show the list of receiving addresses and edit their labels"));
options = new QAction(QIcon(":/icons/options"), tr("&Options..."), this); options = new QAction(QIcon(":/icons/options"), tr("&Options..."), this);
options->setToolTip(tr("Modify configuration options for bitcoin"));
openBitcoin = new QAction(QIcon(":/icons/bitcoin"), "Open &Bitcoin", this); openBitcoin = new QAction(QIcon(":/icons/bitcoin"), "Open &Bitcoin", this);
openBitcoin->setToolTip(tr("Show the Bitcoin window"));
connect(quit, SIGNAL(triggered()), qApp, SLOT(quit())); connect(quit, SIGNAL(triggered()), qApp, SLOT(quit()));
connect(sendcoins, SIGNAL(triggered()), this, SLOT(sendcoinsClicked())); connect(sendcoins, SIGNAL(triggered()), this, SLOT(sendcoinsClicked()));

1
gui/src/guiutil.cpp

@ -33,5 +33,6 @@ void GUIUtil::setupAmountWidget(QLineEdit *widget, QWidget *parent)
amountValidator->setDecimals(8); amountValidator->setDecimals(8);
amountValidator->setBottom(0.0); amountValidator->setBottom(0.0);
widget->setValidator(amountValidator); widget->setValidator(amountValidator);
widget->setAlignment(Qt::AlignRight|Qt::AlignVCenter);
} }

18
gui/src/optionsdialog.cpp

@ -1,6 +1,7 @@
#include "optionsdialog.h" #include "optionsdialog.h"
#include "optionsmodel.h" #include "optionsmodel.h"
#include "monitoreddatamapper.h" #include "monitoreddatamapper.h"
#include "guiutil.h"
#include <QHBoxLayout> #include <QHBoxLayout>
#include <QVBoxLayout> #include <QVBoxLayout>
@ -144,18 +145,23 @@ MainOptionsPage::MainOptionsPage(QWidget *parent):
QVBoxLayout *layout = new QVBoxLayout(); QVBoxLayout *layout = new QVBoxLayout();
bitcoin_at_startup = new QCheckBox(tr("&Start Bitcoin on window system startup")); bitcoin_at_startup = new QCheckBox(tr("&Start Bitcoin on window system startup"));
bitcoin_at_startup->setToolTip(tr("Automatically start Bitcoin after the computer is turned on"));
layout->addWidget(bitcoin_at_startup); layout->addWidget(bitcoin_at_startup);
minimize_to_tray = new QCheckBox(tr("&Minimize to the tray instead of the taskbar")); minimize_to_tray = new QCheckBox(tr("&Minimize to the tray instead of the taskbar"));
minimize_to_tray->setToolTip(tr("Show only a tray icon after minimizing the window"));
layout->addWidget(minimize_to_tray); layout->addWidget(minimize_to_tray);
map_port_upnp = new QCheckBox(tr("Map port using &UPnP")); map_port_upnp = new QCheckBox(tr("Map port using &UPnP"));
map_port_upnp->setToolTip(tr("Automatically open the Bitcoin client port on the router. This only works when your router supports UPnP and it is enabled."));
layout->addWidget(map_port_upnp); layout->addWidget(map_port_upnp);
minimize_on_close = new QCheckBox(tr("M&inimize on close")); minimize_on_close = new QCheckBox(tr("M&inimize on close"));
minimize_on_close->setToolTip(tr("Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu."));
layout->addWidget(minimize_on_close); layout->addWidget(minimize_on_close);
connect_socks4 = new QCheckBox(tr("&Connect through socks4 proxy:")); connect_socks4 = new QCheckBox(tr("&Connect through SOCKS4 proxy:"));
connect_socks4->setToolTip(tr("Connect to the Bitcon network through a SOCKS4 proxy (e.g. when connecting through Tor)"));
layout->addWidget(connect_socks4); layout->addWidget(connect_socks4);
QHBoxLayout *proxy_hbox = new QHBoxLayout(); QHBoxLayout *proxy_hbox = new QHBoxLayout();
@ -166,6 +172,7 @@ MainOptionsPage::MainOptionsPage(QWidget *parent):
proxy_ip->setMaximumWidth(140); proxy_ip->setMaximumWidth(140);
proxy_ip->setEnabled(false); proxy_ip->setEnabled(false);
proxy_ip->setValidator(new QRegExpValidator(QRegExp("[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}"), this)); proxy_ip->setValidator(new QRegExpValidator(QRegExp("[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}"), this));
proxy_ip->setToolTip(tr("IP address of the proxy (e.g. 127.0.0.1)"));
proxy_ip_label->setBuddy(proxy_ip); proxy_ip_label->setBuddy(proxy_ip);
proxy_hbox->addWidget(proxy_ip); proxy_hbox->addWidget(proxy_ip);
QLabel *proxy_port_label = new QLabel(tr("&Port: ")); QLabel *proxy_port_label = new QLabel(tr("&Port: "));
@ -174,6 +181,7 @@ MainOptionsPage::MainOptionsPage(QWidget *parent):
proxy_port->setMaximumWidth(55); proxy_port->setMaximumWidth(55);
proxy_port->setValidator(new QIntValidator(0, 65535, this)); proxy_port->setValidator(new QIntValidator(0, 65535, this));
proxy_port->setEnabled(false); proxy_port->setEnabled(false);
proxy_port->setToolTip(tr("Port of the proxy (e.g. 1234)"));
proxy_port_label->setBuddy(proxy_port); proxy_port_label->setBuddy(proxy_port);
proxy_hbox->addWidget(proxy_port); proxy_hbox->addWidget(proxy_port);
proxy_hbox->addStretch(1); proxy_hbox->addStretch(1);
@ -188,12 +196,10 @@ MainOptionsPage::MainOptionsPage(QWidget *parent):
QLabel *fee_label = new QLabel(tr("Pay transaction &fee")); QLabel *fee_label = new QLabel(tr("Pay transaction &fee"));
fee_hbox->addWidget(fee_label); fee_hbox->addWidget(fee_label);
fee_edit = new QLineEdit(); fee_edit = new QLineEdit();
fee_edit->setMaximumWidth(70); fee_edit->setMaximumWidth(100);
fee_edit->setToolTip(tr("Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended."));
QDoubleValidator *amountValidator = new QDoubleValidator(this); GUIUtil::setupAmountWidget(fee_edit, this);
amountValidator->setDecimals(8);
amountValidator->setBottom(0.0);
fee_edit->setValidator(amountValidator);
fee_label->setBuddy(fee_edit); fee_label->setBuddy(fee_edit);
fee_hbox->addWidget(fee_edit); fee_hbox->addWidget(fee_edit);

Loading…
Cancel
Save