mirror of
https://github.com/koreader/koreader.git
synced 2025-08-10 00:52:38 +00:00
TextBoxWidget: optionally display a list of images
(each one at top right of each page) Such images can be loaded dynamically when the display of a page requires it. Allow alternating between the image and its title with Tap on it. Allow for viewing this image zoomed in ImageViewer with Hold on it. DictQuickLookup: add generic support for result.images, that could optionally be provided in Wikipedia lookup results.
This commit is contained in:
@@ -28,6 +28,7 @@ local ScrollTextWidget = InputContainer:new{
|
||||
scroll_bar_width = Screen:scaleBySize(6),
|
||||
text_scroll_span = Screen:scaleBySize(12),
|
||||
dialog = nil,
|
||||
images = nil,
|
||||
}
|
||||
|
||||
function ScrollTextWidget:init()
|
||||
@@ -38,9 +39,11 @@ function ScrollTextWidget:init()
|
||||
editable = self.editable,
|
||||
justified = self.justified,
|
||||
face = self.face,
|
||||
image_alt_face = self.image_alt_face,
|
||||
fgcolor = self.fgcolor,
|
||||
width = self.width - self.scroll_bar_width - self.text_scroll_span,
|
||||
height = self.height
|
||||
height = self.height,
|
||||
images = self.images,
|
||||
}
|
||||
local visible_line_count = self.text_widget:getVisLineCount()
|
||||
local total_line_count = self.text_widget:getAllLineCount()
|
||||
|
||||
Reference in New Issue
Block a user