On 6/5/22 5:19 AM, Philip Leishman wrote:
The most puzzling aspect for me is why the bug does not happen with the Ctrl+Z shortcut - this is going through exactly the same code as the toolbar !!
Yeah. My theory is that there is some refresh code in Qt that gets confused when the toolbar button is in play. Maybe an "invalidated area" gets messed up somehow.
The double-update issue might be something like: the first update() clears some flags or invalidated areas, but comes in before the scene has actually changed. The scene is changed. The second update() comes in, notices update() was already called and doesn't do anything.
Better understanding of Qt might lead to some rules to follow to avoid this in the future. E.g. the update() call in MatrixScene::recreateLines() is also not needed. Maybe the rule is: Don't call update() in a QGraphicsScene-derived class.
We really need to review and clean this stuff up. That would be a first step.
Ted. _______________________________________________ Rosegarden-devel mailing list Rosegarden-devel@lists.sourceforge.net - use the link below to unsubscribe https://lists.sourceforge.net/lists/listinfo/rosegarden-devel