-
Notifications
You must be signed in to change notification settings - Fork 384
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't pan to full child view height when zoomed in #123
Comments
Nesting scrolling content is usually a not very good idea. In this particular case it seems like ScrollView is scrolled down and you can only see a part of I guess you expect that when Can you please share your use case, why do you need to nest GestureFrameLayout inside ScrollView? |
Sure, I have a large image as a background with text that the user needs to read (not the one in the gif), and there are several I tried removing the Scrollview but then have 2 problems:
|
I think you can assume that GestureFrameLayout is similar to Map view. Placing map view inside ScrollView will not work well, and same for GestureFrameLayout. You may consider to add a separate screen where user will have an option to scale and pan the layout or place it in a fixed location on the screen (e.g. on the bottom). |
Is there any way to pan programmatically GestureFrameLayout? |
Yes, this can be done by manually controlling its state ( |
Thank you! Sorry, one last question, is there any way to smoothly animate from one state to another? A bit like scrollView.smoothScrollTo? |
Ok, I have figured it out, I create a new |
I have a layout structure as such:
When I try to zoom in after moving down the scrollview (let's say to the bottom of the child element of scrollview), then when I try to pan upwards to the top of the image that is the background of my ConstraintLayout (whilst still zoomed in), I am restricted to only going upwards to a fraction of the height.
Here is an image trying to explain the issue:
The text was updated successfully, but these errors were encountered: