mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
Fix partial HW dithered refreshes sometimes appearing to shift refreshed content (#6267)
* Fix HW dithered partial refreshes sometimes behaving as if the refreshed content had moved a few pixels to the side... Probably a kernel issue with the alignment fixup in the EPDC? * Get rid of the legacy coordinates fixup It shouldn't be necessary anymore. And I'd rather fix the root cause, anyway. * Bump base (https://github.com/koreader/koreader-base/pull/1116) * Missed a few DIVs in #6224
This commit is contained in:
@@ -112,7 +112,7 @@ function ReaderCropping:onPageCrop(mode)
|
||||
self.ui:handleEvent(Event:new("SetZoomMode", "page", "cropping"))
|
||||
end
|
||||
self.ui:handleEvent(Event:new("SetDimensions",
|
||||
Geom:new{w = Screen:getWidth(), h = Screen:getHeight()*11/12})
|
||||
Geom:new{w = Screen:getWidth(), h = math.floor(Screen:getHeight()*11/12)})
|
||||
)
|
||||
self.bbox_widget = BBoxWidget:new{
|
||||
crop = self,
|
||||
|
||||
@@ -154,7 +154,7 @@ function ReaderFont:onShowFontMenu()
|
||||
title = self.font_menu_title,
|
||||
item_table = self.face_table,
|
||||
width = Screen:getWidth() - 100,
|
||||
height = Screen:getHeight() / 2,
|
||||
height = math.floor(Screen:getHeight() * 0.5),
|
||||
single_line = true,
|
||||
perpage_custom = 8,
|
||||
}
|
||||
|
||||
@@ -707,7 +707,7 @@ function ReaderHighlight:onHoldPan(_, ges)
|
||||
-- Also, we are not able to move hold_pos.x out of screen,
|
||||
-- so if we started on the right page, ignore top left corner,
|
||||
-- and if we started on the left page, ignore bottom right corner.
|
||||
local screen_half_width = math.floor(Screen:getWidth() * 1/2)
|
||||
local screen_half_width = math.floor(Screen:getWidth() * 0.5)
|
||||
if self.hold_pos.x >= screen_half_width and is_in_prev_page_corner then
|
||||
return true
|
||||
elseif self.hold_pos.x <= screen_half_width and is_in_next_page_corner then
|
||||
|
||||
@@ -634,7 +634,7 @@ function ReaderRolling:onGotoXPointer(xp, marker_xp)
|
||||
if BD.mirroredUILayout() then
|
||||
-- In the middle margin, on the right of text
|
||||
-- Same trick as below, assuming page2_x is equal to page 1 right x
|
||||
screen_x = Screen:getWidth() / 2
|
||||
screen_x = math.floor(Screen:getWidth() * 0.5)
|
||||
local page2_x = self.ui.document:getPageOffsetX(self.ui.document:getCurrentPage()+1)
|
||||
marker_w = page2_x + marker_w - screen_x
|
||||
screen_x = screen_x - marker_w
|
||||
@@ -648,7 +648,7 @@ function ReaderRolling:onGotoXPointer(xp, marker_xp)
|
||||
-- In the middle margin, on the left of text
|
||||
-- This is a bit tricky with how the middle margin is sized
|
||||
-- by crengine (see LVDocView::updateLayout() in lvdocview.cpp)
|
||||
screen_x = Screen:getWidth() / 2
|
||||
screen_x = math.floor(Screen:getWidth() * 0.5)
|
||||
local page2_x = self.ui.document:getPageOffsetX(self.ui.document:getCurrentPage()+1)
|
||||
marker_w = page2_x + marker_w - screen_x
|
||||
end
|
||||
@@ -1086,7 +1086,7 @@ function ReaderRolling:showEngineProgress(percent)
|
||||
-- so it does not override the footer or a bookmark dogear
|
||||
local x = 0
|
||||
local y = Size.margin.small
|
||||
local w = Screen:getWidth() / 3
|
||||
local w = math.floor(Screen:getWidth() / 3)
|
||||
local h = Size.line.progress
|
||||
if self.engine_progress_widget then
|
||||
self.engine_progress_widget:setPercentage(percent)
|
||||
|
||||
@@ -32,7 +32,7 @@ local TweakInfoWidget = InputContainer:new{
|
||||
is_global_default = nil,
|
||||
toggle_global_default_callback = function() end,
|
||||
modal = true,
|
||||
width = Screen:getWidth()*3/4,
|
||||
width = math.floor(Screen:getWidth() * 0.75),
|
||||
}
|
||||
|
||||
function TweakInfoWidget:init()
|
||||
|
||||
@@ -231,7 +231,7 @@ When the book's language tag is not among our presets, no specific features will
|
||||
title = _("Language tags (and hyphenation dictionaries) used since start up"),
|
||||
text = status_text,
|
||||
text_face = Font:getFace("smallinfont"),
|
||||
height = Screen:getHeight() * 4/5,
|
||||
height = math.floor(Screen:getHeight() * 0.8),
|
||||
})
|
||||
end,
|
||||
keep_menu_open = true,
|
||||
|
||||
Reference in New Issue
Block a user