No description provided.
Peers tab hide horizontal scroll bars #324
pull RandyMcMillan wants to merge 1 commits into bitcoin-core:master from RandyMcMillan:peers-tab-hide-scroll-bars changing 1 files +3 −0-
RandyMcMillan commented at 11:21 PM on May 11, 2021: contributor
-
RandyMcMillan commented at 11:29 PM on May 11, 2021: contributor
The horizontal scrollbars block click access to rows in the table view and detail view. The vertical scrollbars are useful. The horz. bars are not very useful (IMO).
Before:

After:

-
in src/qt/rpcconsole.cpp:619 in c868d1bdaf outdated
615 | @@ -616,6 +616,7 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_ 616 | ui->peerWidget->setColumnWidth(PeerTableModel::Subversion, SUBVERSION_COLUMN_WIDTH); 617 | ui->peerWidget->setColumnWidth(PeerTableModel::Ping, PING_COLUMN_WIDTH); 618 | ui->peerWidget->horizontalHeader()->setStretchLastSection(true); 619 | + ui->peerWidget->horizontalScrollBar()->setStyleSheet("QScrollBar {height:0px;}");
promag commented at 12:29 AM on May 12, 2021:Have you tried
ui->peerWidget->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff)?
jarolrod commented at 12:43 AM on May 13, 2021:It's a NACK from me on removing the horizontal scroll bar from the Peers Table. The user can be left in a state where it is inconvenient to scroll right to see the rest of the content. This is a UX downgrade.
Note: if there's consensus for this change (for some reason), you missed disabling the horizontal scroll bar on the banned peers table
promag commented at 12:31 AM on May 12, 2021: contributorI don't see a reason to hide them, especially considering that the default policy is
Qt::ScrollBarAsNeeded.jarolrod commented at 1:13 AM on May 12, 2021: memberI don't think this is an improvement, UX-wise. Under this change, the user does not have visual feedback that there is more data to be seen if they scroll horizontally.
hebasto renamed this:qt: peers-tab hide horizontal scroll bars
Peers tab hide horizontal scroll bars
on May 12, 2021hebasto added the label UI on May 12, 2021in src/qt/rpcconsole.cpp:662 in c868d1bdaf outdated
658 | @@ -658,6 +659,7 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_ 659 | ui->blocksDir->setText(model->blocksDir()); 660 | ui->startupTime->setText(model->formatClientStartupTime()); 661 | ui->networkName->setText(QString::fromStdString(Params().NetworkIDString())); 662 | + ui->scrollArea->horizontalScrollBar()->setStyleSheet("QScrollBar {height:0px;}");
jarolrod commented at 12:48 AM on May 13, 2021:This should be ok to do since #293 was merged. Instead of changing the stylesheet, you should implement this suggestion: https://github.com/bitcoin-core/gui/pull/324/files#r630627901
You should change this line as so:
- ui->scrollArea->horizontalScrollBar()->setStyleSheet("QScrollBar {height:0px;}"); + ui->scrollArea->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);in src/qt/rpcconsole.cpp:619 in c6bd7ff2d6 outdated
615 | @@ -616,6 +616,7 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_ 616 | ui->peerWidget->setColumnWidth(PeerTableModel::Subversion, SUBVERSION_COLUMN_WIDTH); 617 | ui->peerWidget->setColumnWidth(PeerTableModel::Ping, PING_COLUMN_WIDTH); 618 | ui->peerWidget->horizontalHeader()->setStretchLastSection(true); 619 | + ui->scrollArea->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
hebasto commented at 10:43 AM on May 15, 2021:How does this change differ from the one in the line 663?
hebasto commented at 10:45 AM on May 15, 2021: memberAgree with @promag
I don't see a reason to hide them, especially considering that the default policy is
Qt::ScrollBarAsNeeded.and with @jarolrod
It's a NACK from me on removing the horizontal scroll bar from the Peers Table. The user can be left in a state where it is inconvenient to scroll right to see the rest of the content. This is a UX downgrade.
RandyMcMillan marked this as a draft on May 16, 2021RandyMcMillan commented at 8:58 PM on May 19, 2021: contributorHow does/should the user toggle/hide the detail widget when the table data fills the view?

Maybe assigning a key command to hide/toggle the detail view would work? <ESC> key? But I believe it is optimal to allow for a mouse click event as well as a key command event.
qt: peers-tab hide horizontal scroll bars ac288c197aRandyMcMillan closed this on Jun 7, 2021bitcoin-core locked this on Aug 16, 2022ContributorsLabels
This is a metadata mirror of the GitHub repository bitcoin-core/gui. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-27 03:20 UTC
More mirrored repositories can be found on mirror.b10c.me