mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
font menu for readerui
This commit is contained in:
@@ -107,3 +107,12 @@ function ReaderView:onRotationUpdate(rotation)
|
||||
self:recalculate()
|
||||
end
|
||||
|
||||
function ReaderView:onFontChange(font_face)
|
||||
msg = InfoMessage:new{ text = "Redrawing with "..font_face}
|
||||
UIManager:show(msg)
|
||||
self.ui.document:setFont(font_face)
|
||||
-- signal readerrolling to update pos in new height
|
||||
self.ui:handleEvent(Event:new("UpdatePos"))
|
||||
UIManager:close(msg)
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user