Doxysearch is a small, fast and highly portable search engine that allows you to search for strings or words in the documentation generated by doxygen or in the Qt documentation (see below). Doxysearch must be run as a CGI binary. This implies the following:
In order to be able to search fast and efficient, doxysearch does not search the generated documentation directly. Instead, it uses an index file, that should be generated with doxytag. The index file is extracted from the generated HTML files and contains all words and substrings of words present in the HTML files, in a compact form, together with their frequencies and links. Although I tried to store all information as compactly as possible, the size of the index is still quite large. Usually it is about the same size as the original HTML files.
I have tried to make the search engine highly portable, because it
must run on the target system. As a result doxysearch does not require the
Qt library. All that is required to build doxysearch is a C++ compiler.
If you are using g++
for example, you can build the search engine manually,
by typing:
g++ doxysearch.cpp -o doxysearch
To include a search engine in the documentation generated by doxygen follow these steps:
-g
option, if you haven't done this already.
SEARCHENGINE
tag is set to YES
and that all paths are correct.
CGI_NAME
tag in the configuration file.
The script is a small wrapper that calls doxysearch
with
the correct parameters. Using this script allows multiple
search engines for different projects to be present in one directory.
search.cfg:
this file is a small configuration file
for the search engine. It contains two lines of text. The first line
should be the absolute URL to the documentation. The second line should
be the absolute URL to the CGI script. This information is taken from
the configuration file.
search.gif:
this is the image that is used for the search button.
doxytag -s search.idx
search.idx
.
Currently the index file must be called like this.
Notice: When using a search engine this step is required even if no tag files are used. If tag files are used you must specify the correct options.
Using doxytag
and doxysearch
it is possible to create a search engine for
the Qt documentation, without needing the sources!
This can be done by carefully following these steps:
cd $QTDIR/html
doxytag -s search.idx *.html
search.idx
two other files
will be generated: search.gif
and search.cgi
search.cgi
with a text editor.
Fill in the absolute path to the doxysearch
binary after
the DOXYSEARCH=
tag.
On my system this becomes:
DOXYSEARCH=/usr/local/bin/doxysearch
Fill in the absolute path to the qt documentation after the
DOXYPATH=
tag.
On my system this becomes:
DOXYPATH=/usr/local/qt/html
search.cgi
script to this directory.
If needed you may change the name of the script.
On my system, this becomes:
cp search.cgi /usr/local/lib/httpd/cgi-bin/
search.cfg
.
On the first line, you must put the absolute URL to the Qt
documentation.
Since, I only use the search engine on my own standalone system, I use
the file:
protocol.
On the second line, you must put the absolute URL to the
cgi script.
On my system the resulting file looks like this:
file:///usr/local/qt/html http://blizzard/cgi-bin/search.cgi
<li><a href="http://blizzard/cgi-bin/search.cgi">Search the documentation<a>
index.html
file.