Replies: 1 comment 2 replies
-
Wow, that is an interesting problem:-) What is in that infinite scroll area? "Slint things"? Dynamic "Slint things"? Or maybe custom graphics in some way? I would probably write some custom component with a |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What is the best strategy for implementing a widget that presents a viewport that's a window into a virtual surface that is quasi-infinite on both the x- and y-axis? This is for a diagram. Similar example for web browsers.
Requirements
Base
These widgets and built-in elements come into mind as candidates:
ScrollView
,Flickable
,TouchArea
. I wonder whether this use case is so special thatScrollView
andFlickable
aren't suitable. If possible, I also want to avoid having to reimplement functionality like flick-scrolling on mobile, of course. (Should your framework provide helper functions to interpret events to be able to easily reimplement this?)Excess Elements
When implementing a virtual scroller for the web, one has to render some number of excess elements, because the browser scrolls somewhat (or completely?) independently of the JavaScript code and is quick to show other parts of the scrolling surface, so that you have to pre-render in light of this. Am I right that, with Slint, there wouldn't be a need to render excess elements (at least with a custom
TouchArea
approach)?Combination With Animation
If I wanted to implement animated programmatic scrolling to a distant point (i.e., something like
scrollTo()
, which is an extreme case of animated scrolling on scroll pulses), do you think there's a way to perform the scrolling with a smooth frame sequence, while constantly rerendering the diagram on the virtual surface based on shifted data and correspondingly correcting its position, so that the user can't see the technicalities that're happening? Or would the animation that was started be interrupted by the rerendering stuff etc.?Beta Was this translation helpful? Give feedback.
All reactions