![]() |
#1 |
Member
![]() ![]() Posts: 10
Karma: 194
Join Date: Apr 2022
Location: Dhaka, Bangladesh
Device: Likebook P78, Boox Poke Pro
|
Can anyone develop a companion widget for KOReader for Android?
I would like to have a widget for KOReader which will show the books I've recently interacted with on the Android homepage.
This is very hard to implement in KOReader itself since it is not a native Android app. However, making a widget like this as a companion app is possible. I tried to extract the history from two files (one history file in lua, another is the sqlite) to get the necessary data to render (cover, name, author, and in the order they are in the history. The problem is, that I'm not an Android developer. A seasoned developer in this field will be able to create such an app probably in a day. Is anyone interested in developing this? |
![]() |
![]() |
![]() |
#2 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,742
Karma: 730681
Join Date: Oct 2014
Location: Antwerp
Device: Kobo Aura H2O
|
Not me, sorry.
![]() ![]() |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
cosiñeiro
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,402
Karma: 2451781
Join Date: Apr 2014
Device: BQ Cervantes 4
|
It is unlikely.
A third party app won't be able to open books in place. You would click on the widget, on a book that you already opened, and there're chances you won't get that book open in KOReader. This will be worse when we address https://github.com/koreader/koreader/issues/9787. At that point clicking on that widget will duplicate the book on a cache dir that doesn't inherit previous metadata unless you always started the book from the widget, which won't be possible unless the widget does media management on its own. OTOH, while KO isn't a regular android app, we have access to the entire sdk and android facilities outside MainActivity. So the effort to write a standalone widget or a widget as part of the program is mostly the same. Anyways, not interested. But I wouldn't mind to integrate one on the program if somebody steps in and does the bulk of the job. |
![]() |
![]() |
![]() |
#4 |
Member
![]() ![]() Posts: 10
Karma: 194
Join Date: Apr 2022
Location: Dhaka, Bangladesh
Device: Likebook P78, Boox Poke Pro
|
![]()
I will contribute happily. Some guidance is needed though. Unlike the highlight plugin, this is very much android-specific, so I need some direction and time to get the hang of it.
|
![]() |
![]() |
![]() |
#5 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,742
Karma: 730681
Join Date: Oct 2014
Location: Antwerp
Device: Kobo Aura H2O
|
I've never written an Android widget, but most of it is just https://developer.android.com/develo...ews/appwidgets
|
![]() |
![]() |
Advert | |
|
![]() |
#6 | |
cosiñeiro
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,402
Karma: 2451781
Join Date: Apr 2014
Device: BQ Cervantes 4
|
Quote:
Have a look at the link above. Try to start with a simple app that 1. launchs a file picker that lets you choose a single epub. 2. adds the last n files picked to the widget. extra points if your program is able to do thumbnails on its own. At that point what's left is tweaking the widget itself and port it over https://github.com/koreader/android-luajit-launcher. We can help with the last part ![]() |
|
![]() |
![]() |
![]() |
#7 | |
Member
![]() ![]() Posts: 10
Karma: 194
Join Date: Apr 2022
Location: Dhaka, Bangladesh
Device: Likebook P78, Boox Poke Pro
|
Quote:
We need particularly this (Preferably with a grid widget): https://developer.android.com/develo...ts/collections I tried something similar before in Flutter + Kotlin. So I'm confident I can do that part okay. We have to implement the RemoteViewsFactory (In Kotlin in luajit-luncher?). We can expose some sort of updater to Lua through JNI so that in history changes, KOReader can update the widget. Am I on the right track? |
|
![]() |
![]() |
![]() |
#8 | |
cosiñeiro
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,402
Karma: 2451781
Join Date: Apr 2014
Device: BQ Cervantes 4
|
Quote:
But please make a standalone app first, do not submit a PR against luajit-launcher or care about the integration yet. Integrating the final thing takes less than an hour but reviewing/discussing the wip could take months. Better to give us a pointer to the git repo where you're working on it. |
|
![]() |
![]() |
![]() |
Tags |
android, feature-request |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Develop epub 3.0 reader on Android and iOS | eBooknew | ePub | 13 | 07-18-2021 06:49 PM |
what tools to develop koreader? | pluma | KOReader | 1 | 12-05-2016 09:10 PM |
kols - a koreader companion | ctag | Kindle Developer's Corner | 4 | 09-30-2014 07:16 PM |
[Android App] Best Android reader software for use with Calibre / Calibre Companion | ellett | Devices | 11 | 12-16-2012 04:27 PM |
Kindle Daily Deal Widget for Android | PeteMatthews | Amazon Kindle | 3 | 02-11-2012 12:41 PM |