Blog Archive

Monday, May 25, 2009

Lightweight CHM viewer?

Most of the books that we find in the web are in the CHM file format, at least it's better to extract the HTML than from PDF files, but when you saw my last post i wrote about another library that do what we want ;), now its time for the CHM file format.

Let's extract what matters.

Well, if you wanna try yourself, get the source here(wow a new update 2 days ago \o/, thanks goes to Hey Jed Wing).

Hey, remember before you do the stuff "configure --prefix=<path>&&make&&make install" check the features that you can enable, so FIRST "configure --help|less", there might be still an option like --enable-examples(im not with the source right now, and i can't compile it because im compiling a lot of things at this moment).

After the job is done, you might see a new application with a name that should be something like extract_chmLib, to use it check the command-line help anyway, but if you is a kid hard to handle, so type "extract_chmLib <mychmfile.chm> <directory to put the results>"

You will see a lot of files, the directory where the relevant files are are usually under a directory that its name contains just numbers, and under it you always see 2 files, "toc.html" and "main.html".

You want organize the resulting files by hand? o.O

Ok, thats hard for you? learn some shell scripting language, like bash.

I known something about bash ;)

Ohh that's ugly, yes it's but, it works.

You might find usefull sed + bash.

Good luck, when you start getting fluent with bash programming plus some stream line editor(sed ;) you will see why we sometimes like the CLI interface.

But, those things we just see if we are able to, like eyes, just those that has can see.But, those developed that skill, but how? I don't known, but our progress might tell us ;)

No comments:

Post a Comment