Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > KOReader

Notices

Reply
 
Thread Tools Search this Thread
Old 10-26-2024, 10:54 AM   #1
spectas
Junior Member
spectas began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Oct 2024
Device: PocketBook Lux 4
Lightbulb Feat. Req. Discussion: Adding Markdown Support to KOReader

Hi everybody,
I would love to be able with KOReader to read markdown language files. Imho there is two different ways to approach: implenting it with a small parser in KOReader source code, creating minimal a minial HTML output and using MuPDF (which KOReader seems to use) to render; or integrating it directly in MuPDF as this project seems to lack the functionality too.
I’ve therefore just submitted a feature request to add markdown file support to KOReader on GitHub, as well as a request for MuPDF, but maybe here is a good place too to have an exchange on that?

Link to feat. req. for KOReader:
https://github.com/koreader/koreader/issues/12683

Link to feat. req. for MuPDF:
https://bugs.ghostscript.com/show_bug.cgi?id=708108

Why Markdown?
Markdown’s simplicity and readability make it ideal for notes, technical documents, and more, especially on e-ink devices where lightweight formats shine. By supporting markdown, KOReader could serve as a go-to app for reading and organizing notes, technical documents, and personal writing on e-readers. Imagine being able to easily read structured text with headers, lists, links, bold, and italics—all while keeping files small and load times fast!

How It Could Work
For a straightforward start, basic markdown formatting support would be perfect—headers, bold, italics, lists, links, and highlighting. I’ve suggested using a lightweight markdown parser like cmark to convert markdown to HTML within KOReader, so it could be rendered with the existing MuPDF-based HTML renderer.

Future Possibilities
Once basic markdown support is in place, it could expand to include features like math formulas, image embedding, and interactive options such as note-taking, annotations, or even editing markdown files.

Happy to hear your thoughts on this! Also, would there be any additional ideas or wanted features on markdown support?
spectas is offline   Reply With Quote
Old 10-27-2024, 07:03 PM   #2
pazos
cosiñeiro
pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.pazos ought to be getting tired of karma fortunes by now.
 
Posts: 1,396
Karma: 2451781
Join Date: Apr 2014
Device: BQ Cervantes 4
Markdown to HTML is already supported. On KO's FM long press on a markdown file -> convert.

It should support almost anything highlighted above and the conversion should be pretty fast for the kind of files I would expect to be in markdown (ie: not long sacred books ).

There's nothing to improve in the parser (unless you spot a bug) other than speed, if that's required. In that case I would suggest https://github.com/mity/md4c. The best project out there, hands down!
pazos is offline   Reply With Quote
Advert
Reply

Tags
koreader, markdown, mupdf, pockebook


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
KOReader Exported JSON to Markdown uroybd KOReader 4 04-21-2022 03:14 PM
Hacks Koreader: does it support adding note? whudwl Amazon Kindle 6 12-05-2017 05:49 AM
Req for Adding H4 section to the hindu receipe vishnumvv Recipes 1 06-24-2017 09:53 PM
Can next version support Markdown function? donnie888 Sigil 8 11-27-2013 02:23 PM
feat req.: Indexing through Calibre ProDigit Calibre 1 11-19-2008 05:41 PM


All times are GMT -4. The time now is 03:26 PM.


MobileRead.com is a privately owned, operated and funded community.