dash/src/qt
pasta 6d615243e8
Merge #6264: backport: Merge bitcoin#23142, (partial) bitcoin-core/gui#409, 23333, 23755, (partial) 22981
71689fe6dc (partial) Merge bitcoin/bitcoin#22981: doc: Fix incorrect C++ named args (fanquake)
2b71a9b030 Merge bitcoin/bitcoin#23755: rpc: Quote user supplied strings in error messages (MarcoFalke)
5a441b38de (partial) Merge bitcoin-core/gui#409: Fix window title of wallet loading window (Hennadii Stepanov)
49c87e93a6 Merge bitcoin/bitcoin#23142: Return false on corrupt tx rather than asserting (W. J. van der Laan)

Pull request description:

  backports from bitcoin

ACKs for top commit:
  UdjinM6:
    utACK 71689fe6dc
  knst:
    utACK 71689fe6dc

Tree-SHA512: c68e2a1be5669f4fd8b02001ea81310b41fcac2cc5cc660e67b5140b334669c9a071a4bd5b33232580215607f323af5f87218a3465493675a633e112984296eb
2024-09-24 08:59:35 -05:00
..
android
forms Merge bitcoin-core/gui#176: Fix TxViewDelegate layout 2024-07-23 13:08:39 +07:00
locale 60%+: bg, ro, vi 2024-07-18 13:35:16 +03:00
res fix: removed maximum width of transaction list on overview page 2024-07-23 13:08:39 +07:00
test (partial) Merge bitcoin/bitcoin#22981: doc: Fix incorrect C++ named args 2024-09-12 18:57:30 +05:30
addressbookpage.cpp Merge bitcoin-core/gui#362: Add keyboard shortcuts to context menus 2024-08-15 10:45:42 +07:00
addressbookpage.h Merge bitcoin-core/gui#263: Revamp context menus 2024-08-05 17:51:09 +07:00
addresstablemodel.cpp merge bitcoin-core/gui#166: Use enum type as switch argument in *TableModel 2024-06-09 17:33:59 +00:00
addresstablemodel.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
appearancewidget.cpp
appearancewidget.h
askpassphrasedialog.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
askpassphrasedialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
bantablemodel.cpp merge bitcoin-core/gui#166: Use enum type as switch argument in *TableModel 2024-06-09 17:33:59 +00:00
bantablemodel.h merge bitcoin#22915: Remove confusing CAddrDB 2024-06-04 13:31:31 +00:00
bitcoin.cpp merge bitcoin#22653: Rename JoinErrors and re-use it 2024-09-08 15:35:22 +00:00
bitcoin.h Merge bitcoin-core/gui#260: Handle exceptions instead of crash 2024-04-11 02:26:03 +07:00
bitcoinaddressvalidator.cpp
bitcoinaddressvalidator.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
bitcoinamountfield.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
bitcoinamountfield.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
bitcoingui.cpp fix: missing changes from bitcoin#14123 2024-08-28 01:09:45 +07:00
bitcoingui.h Merge bitcoin-core/gui#115: Replace "Hide tray icon" option with positive "Show tray icon" one 2024-04-10 03:19:40 +07:00
bitcoinunits.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
bitcoinunits.h
clientmodel.cpp merge bitcoin#25619: avoid overriding non-virtual ToString() in CService and use better naming 2024-09-11 16:18:46 +00:00
clientmodel.h Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
coincontroldialog.cpp Merge bitcoin-core/gui#362: Add keyboard shortcuts to context menus 2024-08-15 10:45:42 +07:00
coincontroldialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
coincontroltreewidget.cpp
coincontroltreewidget.h
createwalletdialog.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
createwalletdialog.h
csvmodelwriter.cpp
csvmodelwriter.h
dash_locale.qrc
dash.qrc partial bitcoin-core/gui#79: Embed monospaced font 2024-06-09 17:33:59 +00:00
dashstrings.cpp dashstrings 2024-07-18 12:45:48 +03:00
editaddressdialog.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
editaddressdialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
governancelist.cpp refactor: use new QAction style for governance list and masternode list 2024-08-05 17:51:09 +07:00
governancelist.h
guiconstants.h
guiutil.cpp Merge #6168: backport: bitcoin-core#gui18, #121, #257, #263, #281, #335, #362, #828, bitcoin#21912, #21942, #21988 2024-08-21 09:11:32 -05:00
guiutil.h Merge bitcoin-core/gui#281: set shortcuts for console's resize buttons 2024-08-05 17:51:09 +07:00
intro.cpp Merge #6168: backport: bitcoin-core#gui18, #121, #257, #263, #281, #335, #362, #828, bitcoin#21912, #21942, #21988 2024-08-21 09:11:32 -05:00
intro.h merge bitcoin#21850: Remove GetDataDir(net_specific) function 2024-07-23 17:45:24 +00:00
macdockiconhandler.h
macdockiconhandler.mm
macnotificationhandler.h
macnotificationhandler.mm
macos_appnap.h
macos_appnap.mm
main.cpp
masternodelist.cpp fmt: apply clang-format-diff.py suggestions, satisfy linter 2024-09-12 06:36:44 +00:00
masternodelist.h
modaloverlay.cpp scripted-diff: Merge #21836: Replace three dots with ellipsis in the UI string 2024-05-19 11:16:42 -05:00
modaloverlay.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
networkstyle.cpp
networkstyle.h
notificator.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
notificator.h
openuridialog.cpp
openuridialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
optionsdialog.cpp merge bitcoin#26261: cleanup LookupIntern, Lookup and LookupHost 2024-09-11 18:34:06 +00:00
optionsdialog.h Merge bitcoin-core/gui#115: Replace "Hide tray icon" option with positive "Show tray icon" one 2024-04-10 03:19:40 +07:00
optionsmodel.cpp chore: remove ancient setting migration logic 2024-09-20 12:29:02 +00:00
optionsmodel.h Merge bitcoin-core/gui#115: Replace "Hide tray icon" option with positive "Show tray icon" one 2024-04-10 03:19:40 +07:00
overviewpage.cpp Merge bitcoin-core/gui#176: Fix TxViewDelegate layout 2024-07-23 13:08:39 +07:00
overviewpage.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
paymentserver.cpp Merge #6111: backport: bitcoin-core/gui#154, #176, #221, #248, #251 - qt improvements and related fixes 2024-07-23 14:17:33 -05:00
paymentserver.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
peertablemodel.cpp Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
peertablemodel.h Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
peertablesortproxy.cpp Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
peertablesortproxy.h Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
psbtoperationsdialog.cpp Merge bitcoin/bitcoin#22337: wallet: Use bilingual_str for errors 2024-08-27 20:08:25 +05:30
psbtoperationsdialog.h
qrdialog.cpp
qrdialog.h
qrimagewidget.cpp Merge bitcoin-core/gui#362: Add keyboard shortcuts to context menus 2024-08-15 10:45:42 +07:00
qrimagewidget.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
qvalidatedlineedit.cpp
qvalidatedlineedit.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
qvaluecombobox.cpp Merge bitcoin-core/gui#257: refactor: Use template function qOverload in signal-slot connections 2024-08-05 17:51:09 +07:00
qvaluecombobox.h
README.md Merge bitcoin-core/gui#139: doc: Improve gui/src/qt README.md 2024-04-10 03:19:39 +07:00
receivecoinsdialog.cpp Merge bitcoin-core/gui#362: Add keyboard shortcuts to context menus 2024-08-15 10:45:42 +07:00
receivecoinsdialog.h merge bitcoin-core/gui#214: Disable requests context menu actions when appropriate 2024-06-09 17:33:59 +00:00
receiverequestdialog.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
receiverequestdialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
recentrequeststablemodel.cpp Merge bitcoin/bitcoin#21353: interfaces: Stop exposing wallet destdata to gui 2024-04-23 09:15:20 -05:00
recentrequeststablemodel.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
rpcconsole.cpp merge bitcoin#25962: Add CNodeOptions and increase constness 2024-09-12 14:42:57 +00:00
rpcconsole.h Merge bitcoin-core/gui#18: Add peertablesortproxy module 2024-08-05 17:51:09 +07:00
sendcoinsdialog.cpp Merge #6168: backport: bitcoin-core#gui18, #121, #257, #263, #281, #335, #362, #828, bitcoin#21912, #21942, #21988 2024-08-21 09:11:32 -05:00
sendcoinsdialog.h Merge bitcoin-core/gui#284: refactor: Simplify SendCoinsDialog::updateCoinControlState 2024-04-23 22:41:08 +07:00
sendcoinsentry.cpp
sendcoinsentry.h
sendcoinsrecipient.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
signverifymessagedialog.cpp
signverifymessagedialog.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
splashscreen.cpp
splashscreen.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
trafficgraphdata.cpp
trafficgraphdata.h
trafficgraphwidget.cpp Merge bitcoin-core/gui#248: Fix: For values of "Bytes transferred" and "Bytes/s" with 1000-based prefix names use 1000-based divisor instead of 1024-based 2024-07-23 13:08:39 +07:00
trafficgraphwidget.h qt: drop leftover boost::function usage in Qt, drop header from list 2024-04-23 15:34:48 +00:00
transactiondesc.cpp feat: make a support of Qt app to show Platform Transfer transaction as a new type of transaction 2024-08-07 08:27:32 +07:00
transactiondesc.h
transactiondescdialog.cpp Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
transactiondescdialog.h
transactionfilterproxy.cpp
transactionfilterproxy.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
transactionoverviewwidget.h Merge bitcoin-core/gui#176: Fix TxViewDelegate layout 2024-07-23 13:08:39 +07:00
transactionrecord.cpp feat: make a support of Qt app to show Platform Transfer transaction as a new type of transaction 2024-08-07 08:27:32 +07:00
transactionrecord.h feat: make a support of Qt app to show Platform Transfer transaction as a new type of transaction 2024-08-07 08:27:32 +07:00
transactiontablemodel.cpp Merge #6168: backport: bitcoin-core#gui18, #121, #257, #263, #281, #335, #362, #828, bitcoin#21912, #21942, #21988 2024-08-21 09:11:32 -05:00
transactiontablemodel.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
transactionview.cpp Merge #6168: backport: bitcoin-core#gui18, #121, #257, #263, #281, #335, #362, #828, bitcoin#21912, #21942, #21988 2024-08-21 09:11:32 -05:00
transactionview.h Merge #20813: scripted-diff: Bump copyright headers 2024-04-10 03:19:34 +07:00
utilitydialog.cpp scripted-diff: Merge #21836: Replace three dots with ellipsis in the UI string 2024-05-19 11:16:42 -05:00
utilitydialog.h
walletcontroller.cpp (partial) Merge bitcoin-core/gui#409: Fix window title of wallet loading window 2024-09-12 18:57:20 +05:30
walletcontroller.h (partial) Merge bitcoin-core/gui#409: Fix window title of wallet loading window 2024-09-12 18:57:20 +05:30
walletframe.cpp merge bitcoin#20744: Use std::filesystem. Remove Boost Filesystem & System 2024-08-06 18:00:39 +00:00
walletframe.h merge bitcoin-core/gui#399: Fix "Load PSBT" functionality when no wallet loaded 2024-07-23 17:45:24 +00:00
walletmodel.cpp Merge bitcoin/bitcoin#21353: interfaces: Stop exposing wallet destdata to gui 2024-04-23 09:15:20 -05:00
walletmodel.h Merge bitcoin/bitcoin#21353: interfaces: Stop exposing wallet destdata to gui 2024-04-23 09:15:20 -05:00
walletmodeltransaction.cpp
walletmodeltransaction.h
walletview.cpp Merge bitcoin-core/gui#257: refactor: Use template function qOverload in signal-slot connections 2024-08-05 17:51:09 +07:00
walletview.h merge bitcoin-core/gui#399: Fix "Load PSBT" functionality when no wallet loaded 2024-07-23 17:45:24 +00:00
winshutdownmonitor.cpp
winshutdownmonitor.h

This directory contains the source code for the Dash Core graphical user interface (GUI). It uses the Qt cross-platform framework.

The current precise version for Qt 5 is specified in qt.mk. Qt 4 is not supported.

Compile and run

See build instructions: Unix, macOS, Windows, FreeBSD, NetBSD, OpenBSD

When following your systems build instructions, make sure to install the Qt dependencies.

To run:

./src/qt/dash-qt

Files and Directories

forms/

  • A directory that contains Designer UI files. These files specify the characteristics of form elements in XML. Qt UI files can be edited with Qt Creator or using any text editor.

locale/

  • Contains translations. They are periodically updated and an effort is made to support as many languages as possible. The process of contributing translations is described in doc/translation_process.md.

res/

  • Contains graphical resources used to enhance the UI experience.

test/

  • Functional tests used to ensure proper functionality of the GUI. Significant changes to the GUI code normally require new or updated tests.

bitcoingui.(h/cpp)

  • Represents the main window of the Dash UI.

*model.(h/cpp)

  • The model. When it has a corresponding controller, it generally inherits from QAbstractTableModel. Models that are used by controllers as helpers inherit from other Qt classes like QValidator.
  • ClientModel is used by the main application dashgui and several models like peertablemodel.

*page.(h/cpp)

  • A controller. :NAMEpage.cpp generally includes :NAMEmodel.h and forms/:NAME.page.ui with a similar :NAME.

*dialog.(h/cpp)

  • Various dialogs, e.g. to open a URL. Inherit from QDialog.

paymentserver.(h/cpp)

  • (Deprecated) Used to process BIP21 payment URI requests. Also handles URI-based application switching (e.g. when following a dash:... link from a browser).

Used to process BIP21 payment URI requests. Also handles URI based application switching (e.g. when following a dash:... link from a browser).

walletview.(h/cpp)

  • Represents the view to a single wallet.

Other .h/cpp files

  • UI elements like BitcoinAmountField, which inherit from QWidget.
  • bitcoinstrings.cpp: automatically generated
  • bitcoinunits.(h/cpp): BTC / mBTC / etc. handling
  • callback.h
  • guiconstants.h: UI colors, app name, etc.
  • guiutil.h: several helper functions
  • macdockiconhandler.(h/mm): macOS dock icon handler
  • macnotificationhandler.(h/mm): display notifications in macOS

Contribute

See CONTRIBUTING.md for general guidelines.

Note: Do not change local/dash_en.ts. It is updated automatically.

Using Qt Creator as an IDE

Qt Creator is a powerful tool which packages a UI designer tool (Qt Designer) and a C++ IDE into one application. This is especially useful if you want to change the UI layout.

Download Qt Creator

On Unix and macOS, Qt Creator can be installed through your package manager. Alternatively, you can download a binary from the Qt Website.

Note: If installing from a binary grabbed from the Qt Website: During the installation process, uncheck everything except for Qt Creator.

macOS
brew install qt-creator
Ubuntu & Debian
sudo apt-get install qtcreator

Setup Qt Creator

  1. Make sure you've installed all dependencies specified in your systems build instructions
  2. Follow the compile instructions for your system, run ./configure with the --enable-debug flag
  3. Start Qt Creator. At the start page, do: New -> Import Project -> Import Existing Project
  4. Enter dash-qt as the Project Name and enter the absolute path to src/qt as Location
  5. Check over the file selection, you may need to select the forms directory (necessary if you intend to edit *.ui files)
  6. Confirm the Summary page
  7. In the Projects tab, select Manage Kits...

macOS

  • Under Kits: select the default "Desktop" kit
  • Under Compilers: select "Clang (x86 64bit in /usr/bin)"
  • Under Debuggers: select "LLDB" as debugger (you might need to set the path to your LLDB installation)

Ubuntu & Debian

Note: Some of these options may already be set

  • Under Kits: select the default "Desktop" kit
  • Under Compilers: select "GCC (x86 64bit in /usr/bin)"
  • Under Debuggers: select "GDB" as debugger
  1. While in the Projects tab, ensure that you have the dash-qt executable specified under Run
  • If the executable is not specified: click "Choose...", navigate to src/qt, and select dash-qt
  1. You're all set! Start developing, building, and debugging the Dash Core GUI