aseba-community / thymio-vpl2

Next generation VPL for Thymio using Qt Quick from Qt 5.x
GNU Lesser General Public License v3.0
2 stars 5 forks source link

When an event is dropped, lines is resized but the zoom level is unchanged #14

Closed stephanemagnenat closed 7 years ago

stephanemagnenat commented 7 years ago

This leads to the new drop position to be outside view, even when starting from a zoom where everything is visible initially. A way to solve that is to zoom out by the ratio of how much the line was extended, and move the view by the size of the line extension.

marvelous commented 7 years ago

I suggest recentering the view on the dropped block instead of changing the zoom. The new line and the new drop position should be visible. It looks less surprising.

stephanemagnenat commented 7 years ago

I am not sure. In VPL1, the automatic resizing of the zoom to fit and centre the blocks on the x-axis worked well, no-one complained ever about that.

But of course VPL2 is designed for a different type of platforms, and the interaction patterns people might expect are different. I also feel that the constant resize is not very Google Materialish, but neither is the content getting out of screen on both axes. All lists in Material scroll only in one dimension, and arguably VPL2 simple mode is a list.

Reading Material's Responsive UI guidelines on how to adapt elements to different screen sizes (https://material.google.com/layout/responsive-ui.html#responsive-ui-grid), we see that Element width grows as screen size changes is an option. However the guidelines considers a screen size change, while we have a number of elements change.

After thinking, maybe the most Materialish approach would be to actually put all the drop spots for the maximum number of actions, and adapt the zoom level in function of the size of the screen and this maximum (which depends on what actions are shown), and never zoom the UI in simple mode. This would also allow to remove the centre button, and rather we could have a button allowing to see the line with the error, as in VPL1.

What do you think?

marvelous commented 7 years ago

After our discussion I had to implement an automatic zoom-out anyway. Event with a limit in the amount of actions, the window could be resized to limit horizontal space.