Saturday, August 11, 2007

HTML CHM help file viewer install howto

Saturday.

I was curious downloading some ebooks in a publicly available FTP site convinced me to download an old RedHat/Fedora ebook. After downloading the file successfully,I suddenly realized that I mistakenly downloaded the ebook in a MS compiled help file format instead of the usual Adobe Reader file format. How unfortunate as I left my seat infront of the screen for a 6 minute download and suddenly realized I have downloaded a CHM ebook file.

MS compiled help file (CHM) are indexed html file with a file extension of .chm . Viewing this type of files are somewhat similar to viewing HTML pages. However, the context format are properly organized and indexed as if you are reading a book with quick indexed links and menus available in a dropdown tree-like indexed links located at the leftmost side of the viewing pane.

Ofcourse, an attempt to open it inside my fedora box failed as the viewer is not yet installed.

Here is quick simple solution on how I manage to open this CHM file ebook.

Here's how to install CHM file viewer in Fedora and CentOS linux.

KchmViewer - CHM file viewer
----------------------------
KchmViewer is a chm (MS HTML help file format) viewer, written in C++. Unlike most existing CHM viewers for Unix, it uses Trolltech Qt widget library. It is compiled with full KDE support, including KDE widgets and KIO/KHTML.

Since the binary starts with K, it is part and designed for KDE, but it would work with Gnome with resolved dependencies.

Here is the full list of kchmviewer features taken from the site.

* Standalone viewer, depends on Qt only. Does not require KDE, but can use it for extra functionality if configured with --with-kde. Does not require or use Gnome, gtk or wxWindows libraries.
* When compiled with KDE support uses a KIO slave, KHTML, KDE widgets and DCOP support.
* Safe and harmless. In Qt mode ignores JavaScript, and warns you before opening an external web page, or switching to another help file. While using KHTML, executing Javascript is an option.
* Supports tab browsing.
* Correctly detects and shows encoding of any valid chm file.
* Correctly shows non-English chm files, including Cyrillic, Chinese, Japanese and others.
* Correctly searches in non-English chm files even using chm built-in search index (but does even better with its own search engine).
* Correctly shows tables of content and indexes even in broken CHM files.
* Shows an appropriate image for every TOC entry.
* Has complete chm index support, including multiple index entries, cross-links and parent/child entries in index.
* Persistent bookmarks support. Allows to store bookmarks even if "Favorites" window was not enabled for this chm file. Stores not only the page, but also the screen position for every bookmark. You can edit/delete bookmarks.
* For any opened chm file stores the last opened window, window size, search and bookmark history, font size and other settings, so when you open this file again, everything is always on the place.
* Has easy and powerful search-in-page support.
* Allows to increase or decrease the font size, so handicapped people can read texts easily.
* Has standard Back/Forward/Home navigation.
* Has next-in-content-table and prev-in-content-table navigation.
* Can print the opened pages on a standard printer (usually via CUPS).
* Can show HTML source of CHM pages either using internal viewer, or external, specified by user.
* Correct ms-its link support: can switch CHM files by clicking links in different CHMs.
* Supports full-screen, and turning off content window.
* Has advanced built-in search engine, which:
o does not require the search index to be present in chm file.
o indexes all the characters, including symbols, which allows you to search for code like "$q = new SWFAction()"
o supports all the languages chm file could be written in, including those using Cyrillic, European or multi-byte chatsets.
o supports phrase search.
* KDE version supports automation through DCOP interface.

How to install kchmviewer?

# yum -y install kchmviewer

Launch: Ctrl+F2, kchmviewer

which downloads around 300K of rpm installer and dependencies!

0 comments:

Sign up for PayPal and start accepting credit card payments instantly.
ILoveTux - howtos and news | About | Contact | TOS | Policy