-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ENH] Widget status bar #2464
[ENH] Widget status bar #2464
Conversation
98c6523
to
a7e9a78
Compare
Codecov Report
@@ Coverage Diff @@
## master #2464 +/- ##
==========================================
+ Coverage 74.68% 75.07% +0.39%
==========================================
Files 320 323 +3
Lines 56444 56838 +394
==========================================
+ Hits 42157 42673 +516
+ Misses 14287 14165 -122 |
1a70dbe
to
7861908
Compare
Orange/widgets/utils/messages.py
Outdated
if messages: | ||
self.message_bar.setMessages( | ||
(m, msg(m)) for i, m in enumerate(messages) | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why enumerate
and i
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Leftovers from intermediate implementation
device.close() | ||
data = bytes(device.data()) | ||
payload = base64.b64encode(data).decode("ascii") | ||
return "data:image/png;base64," + payload |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could be also useful elsewhere. Do we have a suitable place for such functions? (If not, ignore.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know. Orange.widgets.utils
??
|
||
def standard_pixmap(severity): | ||
# type: (Severity) -> QStyle.StandardPixmap | ||
maping = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
mapping?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes
I'm eager to merge it, except for one (maybe two) small things. Before, the "summary" in the message bar showed the text up to the first line break, and the entire message was shown in the tooltip. Now, it shows the entire message. I'd prefer if the text in the bar was limited to a single line. You may not need to fix this: as I understand, the message can now include a short text, a more detailed text ... This is certainly better than splitting by \n --- except that the The other thing - also visible in these screenshots - is the width of the tooltip, which used to resize to content. |
d07775c
to
60404e7
Compare
I restored the previous line splitting behavior, and tooltip wrapping. |
14d0b73
to
27eec1c
Compare
27eec1c
to
eec6fc9
Compare
535dd57
to
d845e2c
Compare
f699cec
to
d2670fd
Compare
Move the message area to the bottom into a status bar.
Move the status bar out of the widget's layout and in to its content margins.
See QRect.{bottom,right}
3df1f8d
to
8b87b4f
Compare
Restore old behaviour.
Better styling w.r.t enabled/active state.
Make the overlay positioning independent of global screen coordinates when the overlay and the target widget are contained within the same window. When the window is resized (on OSX 10.11) PyQt4 only reports resize events, even when the actual window position (top left corner of the window) changes (e.g. by dragging the top window border).
8b87b4f
to
2b31e82
Compare
Issue
The OWWidget's 'message_bar' is placed in an inappropriate position above the rest of the GUI causing frequent re-layouts which both flicker the GUI and change the position of controls under the mouse from the unsuspecting user.
Description of changes
progressBarValue
state.Includes