Add an option to show errors view from the toolbar#5511
Add an option to show errors view from the toolbar#5511vadi2 merged 7 commits intoMudlet:developmentfrom
Conversation
|
Hey there! Thanks for helping Mudlet improve. 🌟 Test versionsYou can directly test the changes here:
No need to install anything - just unzip and run. |
|
clang-tidy review says "All clean, LGTM! 👍" |
SlySven
left a comment
There was a problem hiding this comment.
As well as a Seg. Fault opportunity (:bomb: ) that needs to be defused, the sub-module updates should be done in one (or more) separate PR(s) I think...
| </property> | ||
| </action> | ||
| <action name="dactionInputLine"> | ||
| <property name="text"> |
There was a problem hiding this comment.
This hunk is just noise (Qt Designer plug-in/utility randomly reordering XML elements) and doesn't really need to be included.
There was a problem hiding this comment.
It is, but it's not worth the time and effort to be re-arranging XML files that'll have no visible effect for the user for me
There was a problem hiding this comment.
Maybe we should use QtDesigner to rearrange them all and forgot about this issue :)
There was a problem hiding this comment.
It is that tool that is the bloody problem. And, no, you can't fix the ordering with it.... 🙄
FTR it isn't even sensitive to correct Qt Versions - it will quite happy insert new *attributes^ that come in the Qt Version that it was built for (there is no "Qt Version(s) to build the .ui file for" option) - which causes the uic from older versions to died screaming about stuff it cannot grok - which is horrible if your project (like, say, Mudlet) tries to be compatible with a range of Qt versions.
We last ran into this nightmare with the addition of a color role for PlaceholderText which clobbered something that Vadi was working on for Mudlet 4.4.0 not only once in c701ab6 but again in 53941a7 a few days later. This element was introduced in Qt 5.12 but since we (still) support building on Qt 5.11 (I'm still using that for system Qt builds on my Devuan 3 "Buster" - comparable to Debian 10 "Bullseye" systems) one must be careful not to tickle Qt Designer to cause it to regenerate colour palettes in a .ui file otherwise it stuffs that bit back in and breaks the Qt 5.11 build for our CI and anyone compiling on a less than bleeding edge distribution...
| } | ||
| host->mpEditorDialog->slot_show_current(); | ||
| host->mpEditorDialog->raise(); | ||
| host->mpEditorDialog->showNormal(); |
There was a problem hiding this comment.
🤔 If a user has the editor window opened full screen/maximised on a second (or higher) monitor than this will undo either of those choices - whilst that might be the case for only a very small set of users doing this might not be the optimum design...
There was a problem hiding this comment.
Instead we just need to clear the Qt::WindowMinimized flag if it is set - to de-iconify the window to whichever of normal, maximised or full-screen was previous set (and not try to set the Qt::WindowActive as that is not something that we should do according to the Qt Documentation):
| host->mpEditorDialog->showNormal(); | |
| host->mpEditorDialog->setWindowState(host->mpEditorDialog->windowState() &~(Qt::WindowMinimized|Qt::WindowActive)); |
Humm, that almost works - except that the editor window does not get shown when this is called upon to create it in the first place.
There was a problem hiding this comment.
That doesn't sound like an improvement, then!
| if (!host) { | ||
| return; | ||
| } | ||
| host->mpEditorDialog->slot_show_current(); |
There was a problem hiding this comment.
Off-topic for this PR but:
I've just checked and dlgTriggerEditor::slot_show_current() is not connect(...)ed up to any signals (this is only one of two usages) so it can loss the slot_ prefix and it's declaration be moved in the header file...
Brief overview of PR changes/additions
Add an option to show errors
Motivation for adding to Mudlet
People miss the 'errors' window very often - possibly because on smaller displays you have to expand the bar in order to see it. This PR adds another point of discoverability.
Other info (issues closed, discussion etc)
Continues on #5293