mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
RadioMark: down shift (#8771)
This commit is contained in:
@@ -11,6 +11,9 @@ local RadioMark = InputContainer:new{
|
||||
face = Font:getFace("smallinfofont"),
|
||||
baseline = 0,
|
||||
_mirroredUI = BD.mirroredUILayout(),
|
||||
-- round radio mark looks a little bit higher than the button/menu text
|
||||
-- default vertical down shift ratio (to the text height) looks good in touchmenu
|
||||
v_shift_ratio = 0.03,
|
||||
}
|
||||
|
||||
function RadioMark:init()
|
||||
@@ -21,6 +24,7 @@ function RadioMark:init()
|
||||
para_direction_rtl = self._mirroredUI,
|
||||
}
|
||||
self.baseline = widget:getBaseline()
|
||||
widget.forced_baseline = self.baseline + math.floor(widget:getSize().h * self.v_shift_ratio)
|
||||
self[1] = widget
|
||||
self.dimen = widget:getSize()
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user