Improved PDF vertical reader zoom and orientation handling (#98)

- Implemented `fitZoom` calculation to properly center and scale pages, especially in landscape orientation.
- Updated `clampValues` and animation bounds to ensure content is correctly centered when zoomed out.
- Refined double-tap-to-zoom logic to toggle between `fitZoom`, 1x, and 2.5x scales.
- Replaced manual frame-based zooming with `Animatable.animateTo` for smoother transitions.
- Added `configChanges` to `MainActivity` in `AndroidManifest.xml` to handle orientation and screen size changes manually.
- Reduced delays and improved reliability of initial page snapping in `PdfViewerScreen`.
This commit is contained in:
Aryan 2026-03-20 11:11:48 +05:30 committed by GitHub
parent c9dc3ce8c2
commit a9c791120d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 136 additions and 107 deletions

View file

@ -47,6 +47,7 @@
android:name=".MainActivity"
android:exported="true"
android:theme="@style/Theme.Reader"
android:configChanges="orientation|screenSize|screenLayout|keyboardHidden"
android:launchMode="singleTask">
<intent-filter>
<action android:name="android.intent.action.MAIN" />