Added ink screen adaptation option / 为框架增加了墨水屏适配选项 #754
+1,443
−578
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
墨水屏是不少漫画阅读者的主力设备,但是由于刷新和分辨率的限制(不同于手机的LCD和OLED,墨水屏是控制屏幕下的实体墨水运动进行显示的),传统的Android直接安装效果很差,我为框架增加了简易的对墨水屏适配模式
disableAnimation配置项来管理全局的动画开关disableInertialScrolling设置项来控制滚动,大量复用了SmoothScrollProvider和SmoothCustomScrollView增加滑动的可配置性(如漫画源配置界面)inkScrollPageFraction设置项(范围0.1-1.0),让用户自行决定每次跳转多远inkImageFilterQuality设置项(none/low/medium/high),开启双线性滤波能缓解墨水屏因低刷新率和物理显示特性带来的画面锯齿、毛刺问题enablePageAnimation对画廊模式手势滑动翻页的控制(唯一不更改墨水屏配置对原框架的改动)[Bug]: 关闭页面动画后,滑动翻页仍然存在动画 #745我使用我的汉王clear6 turbo(4 + 64GB, Android 14)做了部分演示,以动态照片的形式放在了小红书的帖子上http://xhslink.com/o/5xWiyMgC8oQ
lib/pages/settings/ink_screen.dart, accessible via the settings pagedisableAnimationsetting to globally control animation switchesdisableInertialScrollingsetting to control scrolling behavior. This reusesSmoothScrollProviderandSmoothCustomScrollViewextensively to enhance scroll configurability (e.g., in manga source configuration pages)inkScrollPageFractionsetting (range: 0.1–1.0)inkImageFilterQualityoption (none/low/medium/high). Enabling bilinear filtering can alleviate issues like jagged edges and artifacts on e-ink screens due to low refresh rates and physical display characteristicslib/pages/settings/reader.dartand addedenablePageAnimationto control gesture-based page-turning in gallery mode (the only modification to the original framework that does not alter e-ink screen configurations)