Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a mobi version of Java Language Specification?

Tags:

java

jls

kindle

I'm not sure if this is the absolute best place to ask, but I think there's highest probability of an answer here (because of the topic).

Has anyone came across a mobi (Amazon Kindle) version of Java Language Specification? I know I can read PDFs on Kindle but it's less of an experience compared to mobi.

http://docs.oracle.com/javase/specs/

like image 632
Mike Minicki Avatar asked Feb 03 '23 05:02

Mike Minicki


1 Answers

The steps i used to get the JLS into my kindle with the pretty good result:

1) Download JLS in the HTML format with the help of some site downloader.

I used HTTrack (settings: initial url is http://docs.oracle.com/javase/specs/jls/se7/html/index.html, default "preferences and mirror options" except for "build"/"local structure type", which i set to "html in web/, images/others in web/").

The result should be something like a directory with 25 html files, 1 css and 1 image file, and the links inside the html files should be properly relativized.

2) Edit the css file to remove some formatting that will not look good on Kindle (absolute layouts, excessive left and right margins). I simply commented out "div.chapter div.toc", "div.chapter", "ol li" and "ul li" sections and left everything else as is.

3) Use Calibre to convert this set of files into mobi.

The resulting mobi flows nicely and so far all internal links work as expected.

like image 58
Oleg Estekhin Avatar answered May 09 '23 23:05

Oleg Estekhin