Enable wordWrap for Services#293
Enable wordWrap for Services#293hebasto merged 1 commit intobitcoin-core:masterfrom RandyMcMillan:enable-wordwrap-services
Conversation
|
Concept ACK, this seems very useful. I think either the current " & " or a ", " separator would be good. Will test. |
jonatack
left a comment
There was a problem hiding this comment.
ACK 84612fa
Here or in a follow-up, it may be a good idea to use either a non-breaking space before the ampersand or a comma-space to avoid the separator splitting to a line by itself. Otherwise this is a great screen space-saver. Thanks!
|
I experimented with different ways to try to control where it breaks. I will take another look. |
|
@RandyMcMillan you have two tested ACKs here and it's a nice compact self-contained diff that adds value, so if you find something for that I think you could propose it separately. |
|
Concept ACK. Thanks for working on this! It has been in my TODO list for a long time :) What if to add another tiny change: --- a/src/qt/guiutil.cpp
+++ b/src/qt/guiutil.cpp
@@ -708,7 +708,7 @@ QString formatServicesStr(quint64 mask)
}
if (strList.size())
- return strList.join(" & ");
+ return strList.join("\n");
else
return QObject::tr("None");
}? Btw, @jonatack's alternative suggestions
also could be implemented in the same line :) |
|
@RandyMcMillan For nice commit history do you mind changing the prefix in the commit message s/ See: https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md#creating-the-pull-request |
|
Now it will always use multiple lines even when there is enough horizontal space to only use one? |
Right. Is it bad? |
It just trades one dimension for the other. The flexibility of optimizing the available space was what appealed to me. |
You're right, and I agree with you, ceteris paribus. But in this case no other row requires wider space. Therefore, making the column wider is not an optimal way to use the available area. |
|
If the user prefers a wider space to a higher one, the flexible version allows the user to do it with no downside. Edit: I'd suggest the comma-space separator as it requires fewer characters and is a well-understood separator. |
It only adds vertical size to reduce the horizontal size, I don't see why it's better than the flexibility of the original version to allow the user to optimize the space. :shrugging: |
The downside of such approach is that some services, that are not placed in the beginning of the line, could just miss user's attention. Of course, it's a minor one. |
|
I lean toward a UI that avoids horizontal scroll bars. |
|
I agree with @jonatack, flexible approach would be better IMO, i.e. without "forced" newlines. |
|
fb5e880 -- looking at the diff lines count I see +7/-3. If drop unrelated changes, it could be +4/-1. |
|
tACK a0f7978 on same environment as previously. |
a0f7978 qt: enable wordWrap for peers-tab detail services (randymcmillan) Pull request description: Enable wordWrap for peers-tab detailView Services ACKs for top commit: Talkless: tACK a0f7978 on same environment as previously. hebasto: ACK a0f7978, tested on Linux Mint 20.1 (Qt 5.12.8): kristapsk: re-ACK a0f7978. Tested under Gentoo Linux with Xfce4 (Qt 5.15.2). Tree-SHA512: 872e511d2ecfa72fea0fd3284a958b45ee8aee138469ce7f9cd853cd9098b9583917909934b0a5c96f9b81ea1567bcea6a037558829bb79f2a3f413a83df06e6
a0f7978 qt: enable wordWrap for peers-tab detail services (randymcmillan) Pull request description: Enable wordWrap for peers-tab detailView Services ACKs for top commit: Talkless: tACK a0f7978 on same environment as previously. hebasto: ACK a0f7978, tested on Linux Mint 20.1 (Qt 5.12.8): kristapsk: re-ACK a0f7978. Tested under Gentoo Linux with Xfce4 (Qt 5.15.2). Tree-SHA512: 872e511d2ecfa72fea0fd3284a958b45ee8aee138469ce7f9cd853cd9098b9583917909934b0a5c96f9b81ea1567bcea6a037558829bb79f2a3f413a83df06e6
a0f7978 qt: enable wordWrap for peers-tab detail services (randymcmillan) Pull request description: Enable wordWrap for peers-tab detailView Services ACKs for top commit: Talkless: tACK a0f7978 on same environment as previously. hebasto: ACK a0f7978, tested on Linux Mint 20.1 (Qt 5.12.8): kristapsk: re-ACK a0f7978. Tested under Gentoo Linux with Xfce4 (Qt 5.15.2). Tree-SHA512: 872e511d2ecfa72fea0fd3284a958b45ee8aee138469ce7f9cd853cd9098b9583917909934b0a5c96f9b81ea1567bcea6a037558829bb79f2a3f413a83df06e6
a0f7978 qt: enable wordWrap for peers-tab detail services (randymcmillan) Pull request description: Enable wordWrap for peers-tab detailView Services ACKs for top commit: Talkless: tACK a0f7978 on same environment as previously. hebasto: ACK a0f7978, tested on Linux Mint 20.1 (Qt 5.12.8): kristapsk: re-ACK a0f7978. Tested under Gentoo Linux with Xfce4 (Qt 5.15.2). Tree-SHA512: 872e511d2ecfa72fea0fd3284a958b45ee8aee138469ce7f9cd853cd9098b9583917909934b0a5c96f9b81ea1567bcea6a037558829bb79f2a3f413a83df06e6










Enable wordWrap for peers-tab detailView Services