You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current approach of using QScrollArea + specialised child widgets to display the image preview is spectacularly clunky and requires MainWindow to handle more special information about the original image and its transformed version than it really should, as well as manually resize the xImageLabel widgets according to the current zoom level. These will become major hindrances when we eventually move to an MDI model. It also makes it impossible to implement any kind of visual indication for Swipe views that spans beyond the actual image's vertical extents and into the empty vertical space around it in its view container.
Furthermore, KDE Plasma 6's Breeze style has major issues with this approach because we do not handle mouse events in the widgets themselves as we are expected to do, so in order to prevent Breeze from stealing our events, we are forced to disable the style's window dragging for the entire main window rather than just those widgets, unlike with KDE Plasma 5's Breeze — even the way we do this is by setting an undocumented internal attribute.
setProperty("_kde_no_window_grab", true);
Just yucky code all around.
It generally makes more sense to use a custom widget, or potentially QGraphicsView, to avoid issues. I already do have a prototype using a subclass of the latter in a private branch, which I want to resume work on after v0.5.0 is out.
The text was updated successfully, but these errors were encountered:
The current approach of using QScrollArea + specialised child widgets to display the image preview is spectacularly clunky and requires MainWindow to handle more special information about the original image and its transformed version than it really should, as well as manually resize the xImageLabel widgets according to the current zoom level. These will become major hindrances when we eventually move to an MDI model. It also makes it impossible to implement any kind of visual indication for Swipe views that spans beyond the actual image's vertical extents and into the empty vertical space around it in its view container.
Furthermore, KDE Plasma 6's Breeze style has major issues with this approach because we do not handle mouse events in the widgets themselves as we are expected to do, so in order to prevent Breeze from stealing our events, we are forced to disable the style's window dragging for the entire main window rather than just those widgets, unlike with KDE Plasma 5's Breeze — even the way we do this is by setting an undocumented internal attribute.
Just yucky code all around.
It generally makes more sense to use a custom widget, or potentially QGraphicsView, to avoid issues. I already do have a prototype using a subclass of the latter in a private branch, which I want to resume work on after v0.5.0 is out.
The text was updated successfully, but these errors were encountered: